Velocity Reviews - Computer Hardware Reviews

Velocity Reviews > Newsgroups > Programming > Python > IDLE 1.0 on Windows

Reply
Thread Tools

IDLE 1.0 on Windows

 
 
Andrew Gregory
Guest
Posts: n/a
 
      10-15-2003
IDLE puts its configuration info. in a directory called .idlerc
On running it looks for this directory on a path given by the HOME
environment variable.

On Windows HOME would only exist if the user has created it. If it is
not there, IDLE defaults to the highest-lettered hard drive. This
often will be a network drive and is not a good choice. If the drive
is read only (which is quite possible) IDLE fails.

Here are a few extra lines to go in configHandler.h function
GetUserCfgDir to solve this. This allows an IDLERC environment
variable to be used.

def GetUserCfgDir(self):
"""
Creates (if required) and returns a filesystem directory for
storing
user config files.
"""
cfgDir='.idlerc'
if string.find(os.environ['os'].upper(),'WIN')>-1:
userDir=os.getenv('IDLERC')
if userDir==None: userDir=os.getenv('HOME') # may omit,
given later
if userDir==None: userDir="C:\\Python23"
if not os.path.exists(userDir): useDir=os.getcwd()
else:
userDir=os.path.expanduser('~') # unix

[snip]

Andrew.
 
Reply With Quote
 
 
 
 
Gerrit Muller
Guest
Posts: n/a
 
      10-16-2003
Andrew Gregory wrote:

> IDLE puts its configuration info. in a directory called .idlerc
> On running it looks for this directory on a path given by the HOME
> environment variable.


How unfortunate. My windows 98 machine crashes in a horrible way, when
directory or file names start with a dot. I think that I even submitted
a bug report for idle 0.9.2a. Any directory or file name is OK, as long
as it does _not_ contain a .(dot).

I will file a bug report (I thought that I did, but I don't see it at
Sourceforge).

regards Gerrit


--
Gaudi systems architecting:
http://www.extra.research.philips.com/natlab/sysarch/

 
Reply With Quote
 
 
 
Reply

Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
IDLE not working under windows..... Fuzzyman Python 0 01-06-2004 12:28 PM
IDLE Problems - Subprocesses Under Windows Fuzzyman Python 0 12-22-2003 10:14 AM
C STDOUT -> IDLE? (Windows) Rolf Wester Python 2 11-06-2003 07:12 PM
Tk windows in w2k IDLE don't close Matthew Wilson Python 1 10-10-2003 05:04 AM
Windows Python 2.3b2 bug? Edit with IDLE Bartolomé Sintes Marco Python 0 07-10-2003 09:38 AM



Advertisments