Velocity Reviews - Computer Hardware Reviews

Velocity Reviews > Newsgroups > Programming > Python > strange problem using modules from my own package.

Thread Tools

strange problem using modules from my own package.

krishnakant Mane
Posts: n/a
hello all,
I found a very strange kind of behaviour in python with my own package.
I created a package in which there were 4 modules and one file
I created the entire project in eclipse (pydev).
it works fine there with the ide.
but now when I try running the code without eclipse, that is when I
run the individual .py file from a command promt it gives me error.
for example I have,, and of course in my package
the app is in wxpython which is not important in the context of this problem.
never the less I go in the directory called pbcf which is the name of
my package
there I have all the above mentioned files and the file
is the one I run for testing all the menus.
but here the moment I run the file, it starts giving me an error
saying pbcf is not a module.
I find that the same code runs without any problem in eclipse.
in I have from pbcf import * and in I have
of course included MySQLdb and wx
and in I have a connection object called CONCSS.
now when I have all the imports in mainwindow, it does work in eclipse
but does not on a normal command prompt.
why is this?
Reply With Quote

Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off

Similar Threads
Thread Thread Starter Forum Replies Last Post
Using own classloader inside J2EE to load and unload own classes. Stefan Siegl Java 1 07-02-2013 05:05 AM
Disabling modules using Modules/Setup Ben Weintraub Python 0 09-09-2006 12:04 AM
Problem installing modules on redhat 9 - strange connection problem championsleeper Perl Misc 0 01-26-2005 12:19 PM
imputils - import problem modules from sys.modules Remy Cool Python 1 08-27-2003 02:25 PM