On 1 Mar, 20:17, Steve Holden [EMAIL PROTECTED] wrote:
Jeremy Nicoll - news posts wrote:
Jeremy Nicoll - news posts [EMAIL PROTECTED] wrote:
If I understand correctly, when I import something under Windows, Python
searches the directory that the executing script was loaded from, then
On 3 Mar, 17:12, [EMAIL PROTECTED] wrote:
(unless of course I _did_ miss something and my guess is completely
wrong; I should have done some experiment
before posting, but I'm too lazy for that).
Ciao
---
FB- Nascondi testo tra virgolette -
- Mostra testo tra virgolette -
Oops... I
En Mon, 03 Mar 2008 14:39:20 -0200, [EMAIL PROTECTED] escribió:
On 3 Mar, 17:12, [EMAIL PROTECTED] wrote:
Oops... I tried removing python25.zip from sys.path, and I can still
import packages from zip files ...
Yes, python25.zip is in sys.path by default, not to enable zipimport
(which is
Jeremy Nicoll - news posts [EMAIL PROTECTED] wrote:
Does every Windows user have: 2 C:\WINDOWS\system32\python25.zip
in their sys.path? What's the point of having a zip in the path?
Starting with Python 2.4, Python is able to import modules directly from a
zip, as if it were a directory. It's
If I understand correctly, when I import something under Windows, Python
searches the directory that the executing script was loaded from, then other
directories as specified in sys.path.
I assume there are standard locations inside my installed Python - in my
case inside: C:\Program
Jeremy Nicoll - news posts wrote:
If I understand correctly, when I import something under Windows, Python
searches the directory that the executing script was loaded from, then other
directories as specified in sys.path.
Technically, I believe it just puts the script's directory at the start
Jeremy Nicoll - news posts [EMAIL PROTECTED] wrote:
If I understand correctly, when I import something under Windows, Python
searches the directory that the executing script was loaded from, then
other directories as specified in sys.path.
Sorry to followup my own question, but I ran
for
Jeremy Nicoll - news posts wrote:
Jeremy Nicoll - news posts [EMAIL PROTECTED] wrote:
If I understand correctly, when I import something under Windows, Python
searches the directory that the executing script was loaded from, then
other directories as specified in sys.path.
Sorry to
also se topic named
'problem(s) with import from parent dir: from ../brave.py import
sir_robin '
I use this every day now:
sys.path.append(../../py_scripts)
best wishes,
Per
--
http://mail.python.org/mailman/listinfo/python-list
PROTECTED]
[mailto:[EMAIL PROTECTED] Behalf
Of per9000
Sent: Thursday, May 25, 2006 4:07 AM
To: python-list@python.org
Subject: Re: how to change sys.path?
also se topic named
'problem(s) with import from parent dir: from ../brave.py import
sir_robin '
I use this every day now:
sys.path.append
Michael Yanowitz wrote:
Is there something like a .pythoninitrc which can run whenever we start
Python
that can load a file with many sys.path.append(), etc?
If not is there some way to modify the Python shell constructor and
destructor?
Thanks in advance:
Michael yanowitz
Yes, there is
Dennis Lee Bieber wrote:
On Wed, 24 May 2006 17:24:08 GMT, John Salerno
[EMAIL PROTECTED] declaimed the following in comp.lang.python:
Dennis Lee Bieber wrote:
I may have gotten slightly confused
That's my job. :)
Okay:
You have gotten me slightly confused G
Ju Hui wrote:
yes, we can change PYTHONPATH to add some path to sys.path value, but
how to remove item from sys.path?
That would be
del sys.path[3]
for example. Of course you may need to search sys.path to determine the
exact element you need to delete, but sys.path is just like any other
Dennis Lee Bieber wrote:
On Tue, 23 May 2006 20:21:10 GMT, John Salerno
[EMAIL PROTECTED] declaimed the following in comp.lang.python:
I meant actually adding the PYTHONPATH variable to the environment
variables list.
You're looking at editing the Windows registry for that...
I
Dennis Lee Bieber wrote:
On Wed, 24 May 2006 14:45:55 GMT, John Salerno
[EMAIL PROTECTED] declaimed the following in comp.lang.python:
I just right-clicked on My Computer -- Properties -- Advanced --
Environment Variables, and added a new one called PYTHONPATH. I don't
know if that edits
Dennis Lee Bieber wrote:
I may have gotten slightly confused
That's my job. :)
--
http://mail.python.org/mailman/listinfo/python-list
yes, we can add path to PYTHONPATH,but how to remove some items?
my sys.path:
import sys
for x in sys.path:
... print x
...
D:\usr\local\lib\site-packages\setuptools-0.6a11-py2.4.egg
D:\usr\local\lib\site-packages\clientcookie-1.3.0-py2.4.egg
c:\temp
C:\WINDOWS\system32\python24.zip
sys.append(write path of the module u r importing)
Bye.
--
http://mail.python.org/mailman/listinfo/python-list
sys.path.append(path containing module to be imported)
eg. sys.path.append(/home/webdoc)
--
http://mail.python.org/mailman/listinfo/python-list
is python search module by paths in sys.path?
how to change it manuallly?
--
http://mail.python.org/mailman/listinfo/python-list
Ju Hui wrote:
is python search module by paths in sys.path?
sys.path is the list of path where the Python interpreter will search
modules, yes.
how to change it manuallly?
manually ?-)
You mean dynamically, by code ? If yes, it's just a list. You can
modify it like you'd do for any other
yes, I mean I want change the sys.path value and save it for next
using.
I can change the value of sys.path, but I can't save it permanently.
There is no python_path environment on my pc, what the relationship
between it and the sys.path?
--
http://mail.python.org/mailman/listinfo/python-list
Ju Hui wrote:
yes, I mean I want change the sys.path value and save it for next
using.
I can change the value of sys.path, but I can't save it permanently.
There is no python_path environment on my pc, what the relationship
between it and the sys.path?
In Windows, at least, you can create
John Salerno napisał(a):
yes, I mean I want change the sys.path value and save it for next
using.
I can change the value of sys.path, but I can't save it permanently.
There is no python_path environment on my pc, what the relationship
between it and the sys.path?
In Windows, at least, you
Jarek Zgoda wrote:
John Salerno napisał(a):
yes, I mean I want change the sys.path value and save it for next
using.
I can change the value of sys.path, but I can't save it permanently.
There is no python_path environment on my pc, what the relationship
between it and the sys.path?
In
Ju Hui a écrit :
yes, I mean I want change the sys.path value and save it for next
using.
I can change the value of sys.path, but I can't save it permanently.
No.
There is no python_path environment on my pc,
sorry, I meant PYTHONPATH (all caps, no underscore). Like all
environnement
Bruno Desthuilliers [EMAIL PROTECTED] writes:
Ju Hui a écrit :
what the relationship between it and the sys.path?
Don't you guess ?
He's following sound Python philosophy :-)
--
\Hercules Grytpype-Thynne: Well, Neddie, I'm going to be |
`\ frank. Ned Seagoon: Right,
yes, we can change PYTHONPATH to add some path to sys.path value, but
how to remove item from sys.path?
--
http://mail.python.org/mailman/listinfo/python-list
[Please provide some context when you respond in an existing
discussion, by quoting the original message and removing any parts
irrelevant to your reply.]
Ju Hui [EMAIL PROTECTED] writes:
yes, we can change PYTHONPATH to add some path to sys.path value, but
how to remove item from sys.path?
29 matches
Mail list logo