Re: problem(s) with import from parent dir: from ../brave.py import sir_robin

2006-02-27 Thread Magnus Lycka
per9000 wrote: ...and there was much rejoicing... Even better, thanks - you guys are the best. import string, time, sys sys.path.append(../../py_scripts) Works just nice, and yes, I removed the env.variable before I tried it :-D The *right* thing to do might be to install the python

problem(s) with import from parent dir: from ../brave.py import sir_robin

2006-02-24 Thread per9000
Dear Black Knight, I have no quarrel with you sir Knight, but I must import your parents. SHORT VERSION: I tried three variants of from ../brave.py import sir_robin, one works. I want to use it in a py-file to execute command-line-style and that does not work. Can someone please give me, not

Re: problem(s) with import from parent dir: from ../brave.py import sir_robin

2006-02-24 Thread Kent Johnson
per9000 wrote: from raw2nice_def import raw2nice -- When I tried putting this into a program to execute command-line-style: from raw2nice_def.py import raw2nice output: C:\another_bridge\python\python.exe rawhtml2nicehtml_template.py ['raw2nice_def.py', 'raw2nice_def.pyc',

Re: problem(s) with import from parent dir: from ../brave.py import sir_robin

2006-02-24 Thread Tim Williams (gmail)
On 24 Feb 2006 05:10:37 -0800, per9000 [EMAIL PROTECTED] wrote: SHORT VERSION:I tried three variants of from ../brave.py import sir_robin, oneworks. I want to use it in a py-file to execute command-line-style andthat does not work.Can someone please give me, not a bucket with the desert(s) on top,

Re: problem(s) with import from parent dir: from ../brave.py import sir_robin

2006-02-24 Thread per9000
Thanks, I added an environment variable PYTHONPATH and added the holy folder with my script in. Works just perfectly. But still: is there a way around this? (It is a lot easier to add ../../ in my code than make everyone else add this variable). /per9000 --

Re: problem(s) with import from parent dir: from ../brave.py import sir_robin

2006-02-24 Thread plahey
You don't _need_ to go the PYTHONPATH route (although that works). Re-read Carsten's post (particularly step 1, see section 6.1.1). You can use: sys.path.append('..') from brave import sir_robin -- http://mail.python.org/mailman/listinfo/python-list

Re: problem(s) with import from parent dir: from ../brave.py import sir_robin

2006-02-24 Thread Carsten Haese
On Fri, 2006-02-24 at 09:10, per9000 wrote: Thanks, I added an environment variable PYTHONPATH and added the holy folder with my script in. Works just perfectly. But still: is there a way around this? (It is a lot easier to add ../../ in my code than make everyone else add this variable).

Re: problem(s) with import from parent dir: from ../brave.py import sir_robin

2006-02-24 Thread per9000
...and there was much rejoicing... Even better, thanks - you guys are the best. import string, time, sys sys.path.append(../../py_scripts) Works just nice, and yes, I removed the env.variable before I tried it :-D /Per9000 -- http://mail.python.org/mailman/listinfo/python-list