Created on 2001-11-16 16:54 by afayolle, last changed 2011-04-23 15:37 by eric.araujo. This issue is now closed.
|msg53337 - (view)||Author: Alexandre Fayolle (afayolle)||Date: 2001-11-16 16:54|
On installation on Windows platforms, the python directory is not added to the PATH, which makes it difficult to launch python through batch files for instance. Alexandre Fayolle
|msg53338 - (view)||Author: Tim Peters (tim_one) *||Date: 2001-11-24 02:10|
Logged In: YES user_id=31435 I changed this to a feature request: it's not "a bug" because we don't try to set PATH. My experience with an earlier Tcl/Tk installer that did try to set PATH convinces me I'm not going to try to do it at all: it requires too many gimmicks across Windows flavors, can fail in dangerous ways on Win9x boxes, and if you're writing .bat files for Windows you know how to set it yourself anyway (but by hand, where you have a fighting chance of detecting and recovering from failure modes).
|msg53339 - (view)||Author: Alexandre Fayolle (afayolle)||Date: 2001-11-26 08:20|
Logged In: YES user_id=116727 Thanks for the quick answer. I agree that it's not a "bug". Let's make it a feature request then. However, the need is real, not for people writing their own batch file, but rather for people writing and distributing cross platform Python applications. On unix, we have the #! /usr/bin/env python trick, but there's nothing similar on windows. Having the Python directory on the PATH could help. I've tried to do it for an application I maintain, and I agree that it's a pain (I too got bitten by the space in "Program Files"), but I think it's more a Python's job to ensure that the executable is in the PATH. Cheers, Alexandre
|msg53340 - (view)||Author: Tim Peters (tim_one) *||Date: 2001-12-02 22:40|
Logged In: YES user_id=31435 I'm not clear on what problem you're trying to solve. Fiddling PATH is highly anti-social on Windows, so I'm opposed to it even if it were easy (embedded spaces are easy; there are many ways to screw up a Win9x box by failures in editing autoexec.bat, from line-length limitations to failing to handle multiple PATH lines correctly). You can find the location of Python's install directory via the registry. You can also use "start xxx.py" (or os.startfile() from within Python) to use the registered executable for .py and .pyw files. That's how Windows is supposed to be used. In any case, PythonLabs doesn't have the bandwidth to fiddle with this even if I <wink> wanted to; any change here would have to be implemented by a community volunteer; or if it's important enough to pay for it, ActiveState may be willing to implement it in their installer. BTW, if I were distributing a serious Windows app using Python, I'd ship the version of Python I used and install it along with my app, into a subdirectory of my app's directory. That's how, e.g., PythonWare distributes their apps. Then you have total control over it.
|msg59250 - (view)||Author: Christian Heimes (christian.heimes) *||Date: 2008-01-04 19:40|
This bug is about 6 years old. Please discuss the matter on the python dev mailing list if you are still interested in the problem.
|2011-04-23 15:37:13||eric.araujo||set||superseder: Windows installer should add Python and Scripts directories to the PATH environment variable|
|2008-01-04 19:40:56||christian.heimes||set||status: open -> closed|
nosy: + christian.heimes
resolution: wont fix
messages: + msg59250