The Artima Developer Community
Sponsored Link

Python Answers Forum
Python executable problem

1 reply on 1 page. Most recent reply: Aug 14, 2009 8:39 PM by Walter Goedecke

Welcome Guest
  Sign In

Go back to the topic listing  Back to Topic List Click to reply to this topic  Reply to this Topic Click to search messages in this forum  Search Forum Click for a threaded view of the topic  Threaded View   
Previous Topic   Next Topic
Flat View: This topic has 1 reply on 1 page
Walter Goedecke

Posts: 2
Nickname: traubekind
Registered: Aug, 2009

Python executable problem Posted: Aug 11, 2009 2:08 PM
Reply to this message Reply
Advertisement
I've am trying to create an executable program from a Python script, which I am importing "os" in the module. However, when I compile, via "python setup.py py2exe," I receive an error, "ImportError: No module named os"

I also receive an error: "ImportError: No module named linecache," which I didn't call.

How would I include these modules, if they are required?

Thanks,
Walter


Walter Goedecke

Posts: 2
Nickname: traubekind
Registered: Aug, 2009

Re: Python executable problem Posted: Aug 14, 2009 8:39 PM
Reply to this message Reply
I fixed the problem by creating an environment variable, "PYTHONPATH," with C:\Python25\lib. This allowed my code to link to the modules when building.

Flat View: This topic has 1 reply on 1 page
Topic: O'Reilly Passing off 2.5 as latest on iTunes Previous Topic   Next Topic Topic: string to variable name

Sponsored Links



Google
  Web Artima.com   

Copyright © 1996-2019 Artima, Inc. All Rights Reserved. - Privacy Policy - Terms of Use