I'm trying to publish a geoprocessing service (10.2.1) that will be used to generate a PDF from a webmap using an MXD layout as a template.

The problem is that if I try to import any module besides arcpy, the publishing just runs forever until I kill it.

For example, I tried to import os, and it just hangs while it's publishing. When I remove import os, it publishes just fine. Same thing happens with any other module I try to import.

Any idea what's wrong here?

I found this thread that has the exact same problem, but there wasn't really a solution:


I tried @KHibma's suggestion, and created a "script" with only import os, and no parameters at all. Of course it runs with no errors, but the same thing happens when I try to publish the geoprocessing tool. It just hangs until I decide to kill it.

I also did the same thing, but with only import arcpy, and it publishes fine.

  • If you use the "Analyze" button to analyze your service does it show any errors or warnings related to the modules? – landocalrissian Jun 4 '15 at 17:37
  • Nope, it just hangs and does the Not Responding, but right when I remove the other imports and try again it works fine. – ianbroad Jun 4 '15 at 17:38
  • you're absolutely positive its the import doing it? ie. you have NOTHING in a script beside import os and you've tried to do it. I am aware of a couple issue that were fixed at some point in time, but dont recall just a simple import of system installed modules causing an issue. – KHibma Jun 4 '15 at 17:56
  • @KHibma good suggestion. I updated my answer with the results. – ianbroad Jun 4 '15 at 18:03
  • I can't find a known issue on that (and cant reproduce it in a more recent setup). Not sure what else to suggestion :( – KHibma Jun 4 '15 at 18:19

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.