<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Work Space wrong type Error 000301 in Python Questions</title>
    <link>https://community.esri.com/t5/python-questions/work-space-wrong-type-error-000301/m-p/353193#M27710</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;#Post and Reconcile script:&lt;/P&gt;&lt;P&gt;#My perpetual Error: "Work Space wrong type Error 000301" is frustrating and I need some help. Thank You&amp;nbsp;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;import arcpy&lt;BR /&gt;import time, datetime&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;# Current Day&lt;BR /&gt;Day = time.strftime("%m-%d-%Y", time.localtime())&lt;BR /&gt;# Current Time&lt;BR /&gt;Time = time.strftime("%I:%M:%S %p", time.localtime())&lt;/P&gt;&lt;P&gt;&lt;BR /&gt;editDB = "Database Connections\\Arden_Admin.sde"&lt;BR /&gt;Post_Reconcile_Log1_txt = "&lt;A&gt;\\\\Client\\R$\\Engineering&lt;/A&gt; and Planning\\GIS\\813 - Post_Reconcile Log\\Post_Reconcile_Log1.txt"&lt;/P&gt;&lt;P&gt;&lt;BR /&gt;# Set workspace&lt;BR /&gt;workspace = editDB&lt;/P&gt;&lt;P&gt;# Set the workspace environment&lt;BR /&gt;arcpy.env.workspace = workspace&lt;BR /&gt;arcpy.env.overwriteOutput = True&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;BR /&gt;# Start Time&lt;BR /&gt;print 'Process Started at ' + str(Day) + " " + str(Time)&lt;/P&gt;&lt;P&gt;# block new connections to the working and prod database.&lt;BR /&gt;print "Blocking Connections..."&lt;BR /&gt;arcpy.AcceptConnections(editDB, False)&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;# disconnect all users from the working and prod database.&lt;BR /&gt;print "Disconnecting Users..."&lt;BR /&gt;arcpy.DisconnectUser(editDB, "ALL")&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;#Get a list of all versions besides QAQC and DEFAULT to pass into the ReconcileVersions tool.&lt;BR /&gt;ver1List = [ver1.name for ver1 in arcpy.da.ListVersions(editDB) if ver1.name != 'GSWC_SDE.Quality Control' and ver1.name != 'sde.DEFAULT']&lt;BR /&gt;print ver1List&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;arcpy.ReconcileVersions_management(editDB, "ALL_VERSIONS", "GSWC_SDE_Quality Control", ver1List, "LOCK_ACQUIRED", "ABORT_CONFLICTS", "BY_OBJECT", "FAVOR_EDIT_VERSION", "POST", "KEEP_VERSION", Post_Reconcile_Log1_txt)&lt;/P&gt;&lt;P&gt;&lt;BR /&gt;# Extract QAQC version from the list of versions to pass to ReconcileVersions tool.&lt;BR /&gt;ver2List = [ver2.name for ver2 in arcpy.da.ListVersions(editDB) if ver2.name == 'GSWC_SDE.Quality Control']&lt;BR /&gt;print ver2List&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;arcpy.ReconcileVersions_management(editDB, "ALL_VERSIONS", "sde.DEFAULT", ver2List, "LOCK_ACQUIRED", "ABORT_CONFLICTS", "BY_OBJECT", "FAVOR_EDIT_VERSION", "POST", "KEEP_VERSION", Post_Reconcile_Log1_txt)&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;#Allow the database to begin accepting connections again&lt;BR /&gt;print "Set databases to allow connections..."&lt;BR /&gt;arcpy.AcceptConnections(editDB, True)&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;#My Error message is below:&lt;BR /&gt;#Runtime error&amp;nbsp; Traceback (most recent call last):&amp;nbsp;&amp;nbsp; File "&amp;lt;string&amp;gt;", line 41, in &amp;lt;module&amp;gt;&amp;nbsp;&amp;nbsp; File "d:\program files (x86)\arcgis\desktop10.3\arcpy\arcpy\management.py", line 16193,&lt;BR /&gt;#in ReconcileVersions&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; raise e ExecuteError: ERROR 000301: The workspace is of the wrong type Failed to execute (ReconcileVersions).&amp;nbsp;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Thu, 20 Jul 2017 15:39:33 GMT</pubDate>
    <dc:creator>LarryAdgate</dc:creator>
    <dc:date>2017-07-20T15:39:33Z</dc:date>
    <item>
      <title>Work Space wrong type Error 000301</title>
      <link>https://community.esri.com/t5/python-questions/work-space-wrong-type-error-000301/m-p/353193#M27710</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;#Post and Reconcile script:&lt;/P&gt;&lt;P&gt;#My perpetual Error: "Work Space wrong type Error 000301" is frustrating and I need some help. Thank You&amp;nbsp;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;import arcpy&lt;BR /&gt;import time, datetime&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;# Current Day&lt;BR /&gt;Day = time.strftime("%m-%d-%Y", time.localtime())&lt;BR /&gt;# Current Time&lt;BR /&gt;Time = time.strftime("%I:%M:%S %p", time.localtime())&lt;/P&gt;&lt;P&gt;&lt;BR /&gt;editDB = "Database Connections\\Arden_Admin.sde"&lt;BR /&gt;Post_Reconcile_Log1_txt = "&lt;A&gt;\\\\Client\\R$\\Engineering&lt;/A&gt; and Planning\\GIS\\813 - Post_Reconcile Log\\Post_Reconcile_Log1.txt"&lt;/P&gt;&lt;P&gt;&lt;BR /&gt;# Set workspace&lt;BR /&gt;workspace = editDB&lt;/P&gt;&lt;P&gt;# Set the workspace environment&lt;BR /&gt;arcpy.env.workspace = workspace&lt;BR /&gt;arcpy.env.overwriteOutput = True&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;BR /&gt;# Start Time&lt;BR /&gt;print 'Process Started at ' + str(Day) + " " + str(Time)&lt;/P&gt;&lt;P&gt;# block new connections to the working and prod database.&lt;BR /&gt;print "Blocking Connections..."&lt;BR /&gt;arcpy.AcceptConnections(editDB, False)&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;# disconnect all users from the working and prod database.&lt;BR /&gt;print "Disconnecting Users..."&lt;BR /&gt;arcpy.DisconnectUser(editDB, "ALL")&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;#Get a list of all versions besides QAQC and DEFAULT to pass into the ReconcileVersions tool.&lt;BR /&gt;ver1List = [ver1.name for ver1 in arcpy.da.ListVersions(editDB) if ver1.name != 'GSWC_SDE.Quality Control' and ver1.name != 'sde.DEFAULT']&lt;BR /&gt;print ver1List&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;arcpy.ReconcileVersions_management(editDB, "ALL_VERSIONS", "GSWC_SDE_Quality Control", ver1List, "LOCK_ACQUIRED", "ABORT_CONFLICTS", "BY_OBJECT", "FAVOR_EDIT_VERSION", "POST", "KEEP_VERSION", Post_Reconcile_Log1_txt)&lt;/P&gt;&lt;P&gt;&lt;BR /&gt;# Extract QAQC version from the list of versions to pass to ReconcileVersions tool.&lt;BR /&gt;ver2List = [ver2.name for ver2 in arcpy.da.ListVersions(editDB) if ver2.name == 'GSWC_SDE.Quality Control']&lt;BR /&gt;print ver2List&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;arcpy.ReconcileVersions_management(editDB, "ALL_VERSIONS", "sde.DEFAULT", ver2List, "LOCK_ACQUIRED", "ABORT_CONFLICTS", "BY_OBJECT", "FAVOR_EDIT_VERSION", "POST", "KEEP_VERSION", Post_Reconcile_Log1_txt)&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;#Allow the database to begin accepting connections again&lt;BR /&gt;print "Set databases to allow connections..."&lt;BR /&gt;arcpy.AcceptConnections(editDB, True)&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;#My Error message is below:&lt;BR /&gt;#Runtime error&amp;nbsp; Traceback (most recent call last):&amp;nbsp;&amp;nbsp; File "&amp;lt;string&amp;gt;", line 41, in &amp;lt;module&amp;gt;&amp;nbsp;&amp;nbsp; File "d:\program files (x86)\arcgis\desktop10.3\arcpy\arcpy\management.py", line 16193,&lt;BR /&gt;#in ReconcileVersions&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; raise e ExecuteError: ERROR 000301: The workspace is of the wrong type Failed to execute (ReconcileVersions).&amp;nbsp;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 20 Jul 2017 15:39:33 GMT</pubDate>
      <guid>https://community.esri.com/t5/python-questions/work-space-wrong-type-error-000301/m-p/353193#M27710</guid>
      <dc:creator>LarryAdgate</dc:creator>
      <dc:date>2017-07-20T15:39:33Z</dc:date>
    </item>
    <item>
      <title>Re: Work Space wrong type Error 000301</title>
      <link>https://community.esri.com/t5/python-questions/work-space-wrong-type-error-000301/m-p/353194#M27711</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;similar thread&amp;nbsp;&lt;A href="https://gis.stackexchange.com/questions/248182/workspace-error-type-000301-for-reconcile-version"&gt;https://gis.stackexchange.com/questions/248182/workspace-error-type-000301-for-reconcile-version&lt;/A&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 20 Jul 2017 16:25:16 GMT</pubDate>
      <guid>https://community.esri.com/t5/python-questions/work-space-wrong-type-error-000301/m-p/353194#M27711</guid>
      <dc:creator>DanPatterson_Retired</dc:creator>
      <dc:date>2017-07-20T16:25:16Z</dc:date>
    </item>
    <item>
      <title>Re: Work Space wrong type Error 000301</title>
      <link>https://community.esri.com/t5/python-questions/work-space-wrong-type-error-000301/m-p/353195#M27712</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Thanks Dan for your response on this:&lt;/P&gt;&lt;P&gt;I reviewed the reference material you suggested and believe it does not apply because I was the Administrator that created the versions.&amp;nbsp;But for argument sake, I did make the changes as specified in the reference material and I was still&amp;nbsp;hit with the same error.&amp;nbsp;Below is a snippet of my changes&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;arcpy.ReconcileVersions_management(editDB, "ALL_VERSIONS", ' "domain\laadgate".Quality Control',&lt;/P&gt;&lt;P&gt;' "domain\laadgate".ver1List', "LOCK_ACQUIRED", "ABORT_CONFLICTS", "BY_OBJECT", "FAVOR_EDIT_VERSION", "POST", "KEEP_VERSION", Post_Reconcile_Log1_txt)&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 20 Jul 2017 21:07:35 GMT</pubDate>
      <guid>https://community.esri.com/t5/python-questions/work-space-wrong-type-error-000301/m-p/353195#M27712</guid>
      <dc:creator>LarryAdgate</dc:creator>
      <dc:date>2017-07-20T21:07:35Z</dc:date>
    </item>
    <item>
      <title>Re: Work Space wrong type Error 000301</title>
      <link>https://community.esri.com/t5/python-questions/work-space-wrong-type-error-000301/m-p/353196#M27713</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Larry... I think this and your other thread have hit a wall and tech support could probably resolve it since the obvious and less obvious doesn't seem to apply in your case.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 20 Jul 2017 21:13:09 GMT</pubDate>
      <guid>https://community.esri.com/t5/python-questions/work-space-wrong-type-error-000301/m-p/353196#M27713</guid>
      <dc:creator>DanPatterson_Retired</dc:creator>
      <dc:date>2017-07-20T21:13:09Z</dc:date>
    </item>
  </channel>
</rss>

