[issue1743] IDLE fails to launch
Martin v. Löwis
report at bugs.python.org
Tue Jan 22 23:43:59 CET 2008
Martin v. Löwis added the comment:
As a follow-up, it appears that Windows didn't allow truncating hidden
or system files since Windows 2000. If you change the flags on .idlerc
to hidden in (say) W2k3, IDLE will also fail to start - so it's not a
Vista issue.
The question is why the folder "sudenly" became hidden - Python has no
API to make it so.
In any case, the proper solution is to delete the file rather than
overwriting it, perhaps like so
def save_overwrite_open(fname):
try:
return open(fname,"w")
except IOError:
os.unlink(fname)
return open(fname,"w")
__________________________________
Tracker <report at bugs.python.org>
<http://bugs.python.org/issue1743>
__________________________________
More information about the Python-bugs-list
mailing list