Importing Custom Libraries

Technical questions about Editra, post them here

Importing Custom Libraries

Postby gopar » Sun Aug 11, 2013 1:09 am

Hello, I am trying to add custom libraries to python and when I try to import them in the PyShell (Editra) it gives me a no module found error. I have tried importing the library from the IDLE that comes when you install Python and it works without error. Is there a way that I can add them to PyShell? Also I have installed PIL (Python Image Library) and that also does not work. The only other library that was installed separately was WxPython and that works fine. Any answers would be appreciated.

Thank You,
Daniel G.
gopar
Limited User
 
Posts: 3
Joined: Thu Aug 08, 2013 5:56 am

Re: Importing Custom Libraries

Postby cody » Mon Aug 12, 2013 5:58 pm

Are you using a binary version of Editra (editra.exe) or running Editra on your local python installation?
User avatar
cody
Site Admin
 
Posts: 1315
Joined: Mon Oct 09, 2006 2:49 am
Location: United States

Re: Importing Custom Libraries

Postby gopar » Tue Aug 13, 2013 6:01 am

I used the .exe to install Editra. The custom importing of libraries only fails when importing in PyShell. Other than that, Editra is able to run my scripts that include my custom libraries without any trouble.
gopar
Limited User
 
Posts: 3
Joined: Thu Aug 08, 2013 5:56 am

Re: Importing Custom Libraries

Postby cody » Tue Aug 13, 2013 5:38 pm

Ok that is probably the issue then. Editra.exe uses its own internal python and not your system one. IDLE runs on your system python so that is why the completion for the imports work. SInce Editra.exe is using its own internal python it is only able to provide completions for libraries that are bundled into Editra.

If your working on Python code mostly I would suggest installing editra as a python module either the .egg or 'python setup.py install' with the source bundle and running it with your system python. You will then be able to get autocompletion and PyShell support for any modules installed on that version of Python's lib folder.
User avatar
cody
Site Admin
 
Posts: 1315
Joined: Mon Oct 09, 2006 2:49 am
Location: United States

Re: Importing Custom Libraries

Postby gopar » Mon Dec 02, 2013 7:34 am

Thank you, that solve all my problems
gopar
Limited User
 
Posts: 3
Joined: Thu Aug 08, 2013 5:56 am


Return to Technical Discussion

Who is online

Users browsing this forum: No registered users and 2 guests

cron