Terry J. Reedy added the comment:
It seems like a logic error to try to remove something that is not there. But
it is not obvious from the traceback that your problem has anything to do with
*opening* a file. Unbinding should only happen when *closing* a file. So I
suspect this is a different
Roger Serwy added the comment:
Patrick, see Issue8900. It described your problem.
--
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue10365
___
___
Patrick added the comment:
Thanks for the pointer to the other issue. It looks spot on.
--
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue10365
___
Patrick added the comment:
Forgive me if I'm not following the correct process. But I believe I have seen
this issue again in 3.3. Not sure I captured exactly what is needed from the
command line. The file being openeed is from the Python Hands On Class Examples
Roundup Robot devn...@psf.upfronthosting.co.za added the comment:
New changeset 5b267381eea0 by Terry Jan Reedy in branch '2.7':
Issue 10365: Add and replace comments; condense defaulted attribute access.
http://hg.python.org/cpython/rev/5b267381eea0
New changeset 4f3d4ce8ac9f by Terry Jan
Changes by Terry J. Reedy tjre...@udel.edu:
--
resolution: - fixed
stage: needs patch - committed/rejected
status: open - closed
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue10365
___
Roger Serwy roger.se...@gmail.com added the comment:
(I need to write an extension to auto-apply strip-trailing-whitespace on save.)
Terry, I agree that the comment needs improvement. The self.editwin reference
to the window needs to be available so that .get_saved() doesn't fail. In
Terry J. Reedy tjre...@udel.edu added the comment:
The only substantive change I see is replacing the four lines setting 'interp'
with a defaulted getattr call. You seem to have missed my point that
'Otherwise, open a new window' is false. It must be that flist.open(filename)
first checks to
Roger Serwy roger.se...@gmail.com added the comment:
You're right. I missed your point about flist.open shifting focus to the
already opened file. FileList.py contains the open method.
--
___
Python tracker rep...@bugs.python.org
Changes by Terry J. Reedy tjre...@udel.edu:
--
assignee: - terry.reedy
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue10365
___
___
Roundup Robot devn...@psf.upfronthosting.co.za added the comment:
New changeset a2877fbabf95 by Terry Jan Reedy in branch '3.2':
Issue #10365: File open dialog now works instead of crashing
http://hg.python.org/cpython/rev/a2877fbabf95
New changeset 21862628a013 by Terry Jan Reedy in branch
Terry J. Reedy tjre...@udel.edu added the comment:
I verified problem in 3.3 and when opening dialog from shell.
Patch fixes problem, including open idle, open dialog, close shell, select
file, and now file is opened. Thanks Roger. I went ahead and applied fix. (But
note: your patch had a
Changes by Terry J. Reedy tjre...@udel.edu:
--
versions: +Python 2.7, Python 3.3
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue10365
___
___
Roger Serwy roger.se...@gmail.com added the comment:
William's explanation in msg123203 for the cause of the error and the solution
for keeping a reference to flist is good. IDLE has only one instance of
FileList while running anyways.
Attached is a patch that behaves like William's
Alexander Belopolsky belopol...@users.sourceforge.net added the comment:
Unexpected exception is not a crash. Changing the type to behavior.
--
nosy: +belopolsky
type: crash - behavior
___
Python tracker rep...@bugs.python.org
William Barr webmaster...@gmail.com added the comment:
Ok, attached is a patch that should make IDLE silently ignore this happening;
upon looking into this, it was a rather trivial fix. The open function was
waiting on the return input from the askopenfile call, during which the calling
Terry J. Reedy tjre...@udel.edu added the comment:
The indentation of the patch 'looks' wrong. That appears to be because you used
tabs instead of spaces (as in the lines removed and I presume elsewhere in the
file -- and because FireFox interprets tabs as 8 spaces. Please redo with
spaces. I
Terry J. Reedy tjre...@udel.edu added the comment:
That suggests that the last statement needs to be guarded somehow.
I re-versioned to 3.2 because 3.1.final will be out very soon.
I expect 3.2 and 2.7 should have same problem.
--
nosy: +terry.reedy
versions: +Python 3.2 -Python 3.1
William Barr webmaster...@gmail.com added the comment:
Ok. I'll see if I can get some protection around that then.
I did test the issue with 2.7, and I didn't find it. The window didn't open,
but it didn't generate an exception that would kill the IDLE process.
--
New submission from William Barr webmaster...@gmail.com:
Steps for reproduction:
1. Open IDLE (Python 3.1.2)
2. Open a .py file
3. With the code window (not the shell window) in focus, Ctrl + O to bring up
the open file dialog. Do not select a file or press open.
4. Close the code
Amaury Forgeot d'Arc amaur...@gmail.com added the comment:
Reproduced in a console window:
C:\c:\python31\python.exe -m idlelib.idle
Exception in Tkinter callback
Traceback (most recent call last):
File c:\python31\lib\tkinter\__init__.py, line 1399, in __call__
return self.func(*args)
21 matches
Mail list logo