[Python-Dev] Why does the Windows installer use the shortname form of the install directory? (original) (raw)

Tim Peters tim.one@comcast.net
Fri, 11 Oct 2002 11:47:30 -0400


[Moore, Paul]

I just installed Python 2.2.2b1 (replacing ActiveState Python) and I notice that the installer uses the shortname form of the Python install directory. This appears in sys.path, in file associations (and hence in sys.argv[0]), and in lots of other places in the registry, not all of which I follow the reasons for.

My Python install directory was C:\Applications\Python - not the default, but also not containing spaces (which I guess could be a problem for some scripts). So the short form should not be necessary. I've fixed the problem manually by hacking the registry, but it's not something I feel comfortable with...

I must have missed what "the problem" is. What is the problem? Path components generally have two distinct names on Windows. That's how the OS works -- we didn't invent this madness .

Would it be possible for the installer to use the long filename form

Yes, but I won't make that change, because we used to do it that way and it confused newbies endlessly, mostly because of embedded spaces. By default, the installer suggests an 8.3 name so that nobody can get confused. Pick a non-8.3 name instead, and two distinct names are a fact of Windows Life you have to live with.

(at least in cases where the install path does not contain spaces)?

I don't know that the WISE scripting language is capable of making this distinction, and in the absence of an actual problem I'm not going to spend time digging into it. It's certainly too late to make this kind of change in the 2.2 line, so if a volunteer appears who cares enough to address it, it would have to wait for 2.3.