XSLTransform_conversion works on Windows 7 PC but not on Windows 2008 Server

602
3
10-03-2013 10:57 AM
DanielMcAlister
New Contributor II
I use a small python script to export metadata to xml. It works fine if I run it on a Windows 7 64 bit PC but it will not run on a Windows 2008 Server. We had this issue in 10 and 10.1 and it was defined as a bug/limitation by Esri. It's still an issue in 10.2. Has anyone else come across this? Code is below, error is:

Traceback (most recent call last): File "D:\Scripts\exportmetadatawin201.py", line 11, in <module> arcpy.XSLTransform_conversion(Source_Metadata, ExportMetadata_xslt, Output_XML,"") File "D:\Program Files (x86)\ArcGIS\Desktop10.2\arcpy\arcpy\conversion.py", line 1366, in XSLTransform raise e arcgisscripting.ExecuteError: ERROR 000582: Error occurred during execution.

import arcpy, sys


Output_XML = sys.argv[1]

Source_Metadata = "Database Connections/sde to server.sde/" + sys.argv[2]


ExportMetadata_xslt = "d:/Scripts/ExportMetadata.xslt"

arcpy.XSLTransform_conversion(Source_Metadata, ExportMetadata_xslt, Output_XML,"")
Tags (2)
0 Kudos
3 Replies
LucasDanzinger
Esri Frequent Contributor
If you type import sys, then print sys.version below that, are you running in 64-bit? If so, your issue might be that the tools in the metadata toolset do not run in 64-bit.
0 Kudos
DanielMcAlister
New Contributor II
Lucas, thanks for replying to the thread. I should have made it clear in the original post. The Windows 7 PC is 64 bit and the code runs fine. Python on both machines is 32 bit.
0 Kudos
MichelleBoivin
Occasional Contributor

Although this is an older post, I ran into this issue with ArcGIS 10.5.1, Python 2.7, Server 2016, and Windows 7. My script to update a data catalog ran fine on my Windows 7 machine, which also had .Net 3.5 installed. When I went to run it on the Server 2016 box, it continued to fail with a 000582 error similar to above. I thought it may have been because .Net 3.5 was not installed, so I installed it, rebooted, and still nothing. Then I realized I had some custom stylesheets that weren't copied over from the Desktop to the Server. Once I had copied those over, the script worked like a charm.