473,320 Members | 1,829 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,320 software developers and data experts.

cannot create python packages

Hi,
i have the following files:
current_dir/level1/Called.py
current_dir/Caller.py
Called.py:
-----------
class Called:
def exec1(self):
print "Hello"
Caller.py:
----------
from level1.Called import *

c=Called()
c.exec1()

However it is impossible for Caller.py to find
Called.py. I even tried to place the level1 structure
inside /usr/lib/pythonX.Y/, whithout success however.
Any ideas?

Thnx
__________________________________________________ _________
Want ideas for reducing your carbon footprint? Visit Yahoo! For Good http://uk.promotions.yahoo.com/forgood/environment.html
Oct 10 '07 #1
1 1049
On 10 Ott, 15:01, Konstantinos Pachopoulos <kostaspa...@yahoo.gr>
wrote:
Hi,
i have the following files:
current_dir/level1/Called.py
current_dir/Caller.py

Called.py:
-----------
class Called:
def exec1(self):
print "Hello"

Caller.py:
----------
from level1.Called import *

c=Called()
c.exec1()

However it is impossible for Caller.py to find
Called.py. I even tried to place the level1 structure
inside /usr/lib/pythonX.Y/, whithout success however.
Any ideas?

Thnx

__________________________________________________ _________
Want ideas for reducing your carbon footprint? Visit Yahoo! For Good http://uk.promotions.yahoo.com/forgood/environment.html
I think you need a __init__.py file in level1 directory

Oct 10 '07 #2

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

1
by: Jeremy C. Reed | last post by:
Configuring gramps (genealogy software) says: checking Python bindings for gtk... ok checking Python bindings for GNOME... ok checking Python bindings for gconf... Traceback (most recent call...
1
by: Tim Bradshaw | last post by:
I'd like to be able to install python with stow, and then to install various modules which use distutils, also with stow. This currently pretty much won't work, because Python chases symlinks to...
3
by: Tim Gahnstrom | last post by:
rdiff-backup is aperently written in Python and when I run it in a special way I get some funy Python errors. Does anyone know if linux python have some issues with working with fat32 or usb...
2
by: penglish1 | last post by:
This question applies specifically to RHEL 3.0 (actually Whitebox), but also generally to Redhat and probably pretty much every distribution that uses python for distribution-related tasks...
7
by: Edward Diener | last post by:
I can install Python 2.4 on the Fedora 3 Linux system, but after I do a number of Linux utilities and commands, like yum, stop working because they were dependent on the Python 2.3 installation....
2
by: diffuser78 | last post by:
I have two python 2.4s on my Ubuntu Linux box. One is Python 2.4.2 and other is Python 2.4.3. I use SPE as an IDE for coding. I have written a small app in wxPython. If I run it from SPE it just...
2
by: Chris Miles | last post by:
On a standard Solaris 10 installation with Sun-supplied open-source packages installed (like SFWrline for readline libs) I cannot seem to force Python configure/setup.py to build with readline...
5
by: Marc Oldenhof | last post by:
Hello all, I'm pretty new to Python, but use it a lot lately. I'm getting a crazy error trying to do operations on a string list after importing numpy. Minimal example: Python 2.5.1...
2
by: Gabriel Rossetti | last post by:
Hello everyone, I'm trying to use python's freeze utility but I'm running into problems. I called it like this : python /usr/share/doc/python2.5/examples/Tools/freeze/freeze.py...
1
by: Martin Rubey | last post by:
Dear all, I'm trying to call from common lisp functions written for Sage (www.sagemath.org), which in turn is written in python. To do so, I tried...
0
by: ryjfgjl | last post by:
ExcelToDatabase: batch import excel into database automatically...
1
isladogs
by: isladogs | last post by:
The next Access Europe meeting will be on Wednesday 6 Mar 2024 starting at 18:00 UK time (6PM UTC) and finishing at about 19:15 (7.15PM). In this month's session, we are pleased to welcome back...
0
by: Vimpel783 | last post by:
Hello! Guys, I found this code on the Internet, but I need to modify it a little. It works well, the problem is this: Data is sent from only one cell, in this case B5, but it is necessary that data...
0
by: jfyes | last post by:
As a hardware engineer, after seeing that CEIWEI recently released a new tool for Modbus RTU Over TCP/UDP filtering and monitoring, I actively went to its official website to take a look. It turned...
0
by: ArrayDB | last post by:
The error message I've encountered is; ERROR:root:Error generating model response: exception: access violation writing 0x0000000000005140, which seems to be indicative of an access violation...
1
by: PapaRatzi | last post by:
Hello, I am teaching myself MS Access forms design and Visual Basic. I've created a table to capture a list of Top 30 singles and forms to capture new entries. The final step is a form (unbound)...
0
by: Defcon1945 | last post by:
I'm trying to learn Python using Pycharm but import shutil doesn't work
1
by: Shællîpôpï 09 | last post by:
If u are using a keypad phone, how do u turn on JavaScript, to access features like WhatsApp, Facebook, Instagram....
0
by: Faith0G | last post by:
I am starting a new it consulting business and it's been a while since I setup a new website. Is wordpress still the best web based software for hosting a 5 page website? The webpages will be...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.