[IPython-user] startup home or working directory question on WinXP
dbrown2 at yahoo.com
Thu May 5 17:28:26 CDT 2005
It works fine now for this case if I set a 'HOME' user
enviroment variable to something like 'C:\Documents and
Settings\username\', where username is the users login
name. This is currently for a Win2000 system actually, not
Under recent vintage Windows at least it seems it might be
reasonable to have a case added that just uses this path as
a backup (or uses python2x/share instead of trying too hard
after initial failure). That way ipython at least uses some
likely valid location. Currently for my situation it seems
to give up and then the later runs of ipython still can't
find startup files. Apparently the ipython built-in
(non-file-based) default settings are a little different
from the default file-based settings.
Another possible improvement might be to add to the error
message text that setting a user HOME enviroment varialble
may be needed.
In any case thanks for the clarification on ipython
behavior. I'm still a bit confused over what the Winxx
conventions are. I do recall that home path names have
changed in different OS versions. A topic for future study
--- Fernando Perez <Fernando.Perez at colorado.edu> wrote:
> D Brown wrote:
> > I have had problems on differnt Win machines with
> > instalation complaining about it's home directory.
> > Can anyone explain what ipython might be doing here and
> > there is a way to explicitly set the startup path?
> > do ipython init files normally go? Any general hints on
> > what Windows is doing would also be helpful. I realize
> > this is an issue with my local setup but others might
> > across this occasionally.
> Yes, IPython tries hard to figure out what 'home' means
> for a user, via the
> following in IPython.genutils:
> def get_home_dir():
> """Return the closest possible equivalent to a
> 'home' directory.
> We first try $HOME. Absent that, on NT it's
> Currently only Posix and NT are implemented, a
> HomeDirError exception is
> raised for all other OSes. """ #'
> Since the very first thing it tries is to look for a HOME
> variable, you may just define that to something sensible
> (and not
> network-dependent), and IPython will reliably return that
> I hope this helps,
Find restaurants, movies, travel and more fun for the weekend. Check it out!
More information about the IPython-user