Davin Potts added the comment:
Unable to reproduce on Ubuntu 12.04.5 with Python 2.7.8 and current libtk8.5
and libtcl8.5 releases using the attached hanger.py example.
Key findings to-date:
1. Posts to this issue have concluded that there exists a problem with thread-
and process-safety in
Richard Oudkerk added the comment:
So hopefully the bug should disappear entirely in future releases of tcl,
but for now you can work around it by building tcl without threads,
calling exec in between the fork and any use of tkinter in the child
process, or not importing tkinter until
James Sanders added the comment:
I did a bit more digging and I think I've worked out what is going on. The
particular bit of tcl initialization code that triggers the problem if it is
run before the fork is Tcl_InitNotifier in tclUnixNotify.c. It turns out there
is a known problem with
Changes by Antoine Pitrou pit...@free.fr:
--
nosy: +sbt
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue5527
___
___
Python-bugs-list mailing list
James Sanders added the comment:
I recently got hit by this bug on 64-bit ubuntu 13.04, with python 3.3.1 and
tcl/tk 8.5.13 installed from the Ubuntu repositories. However, I tried
building the same versions of tcl, tk, and python locally, and couldn't
reproduce the bug. I also built python
Changes by Andrew Svetlov andrew.svet...@gmail.com:
--
nosy: +asvetlov
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue5527
___
___
Python-bugs-list
Philip Winston pwins...@gmail.com added the comment:
We ran into this. Forking before importing Tkinter worked for us. We did the
following which seems pretty clean:
main.py
import stdlib only
if __name__ == 'main':
fork via multiprocessing.Process
from application import App
App()
Changes by Brian Curtin cur...@acm.org:
--
priority: - normal
stage: - needs patch
type: crash - behavior
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue5527
___
Aki akin...@users.sourceforge.net added the comment:
Hello Jani Hakala,
Thank you very much for working on the case I created.
And, sorry for not getting back to you.
I have confirmed observation that the problem is fixed under Linux if
Tkinter is imported after fork().
However, this remains
Jani Hakala jahak...@iki.fi added the comment:
You can do something like
import gui
gui.start()
in your Panel.draw() and 'from Tkinter import *' in the gui module which
should contain your GUI-related code.
Or you could just do 'from Tkconstants import *' in your tk_test.py
--
Aki akin...@users.sourceforge.net added the comment:
Hello Jani Hakala,
Thank you for your suggestions.
Yes, from Tkconstants import * would ease the pain.
The second suggestion, importing gui in another file didn't work well
with my code as I'm using a class to host both gui process and
Jani Hakala jahak...@iki.fi added the comment:
The script tk_test.py produces the window with one button after one
removes the line 'from Tkinter import *' and adds line 'from Tkinter
import Tk, Button' inside Panel.draw() as a first line.
So importing Tkinter after the fork seems to solve the
New submission from Aki akin...@users.sourceforge.net:
Hello,
The attached test case, which uses multiprocessing module to run Tkinter
GUI process, runs flawlessly under Solaris but hung under Linux (CentOS5).
The test case is a trimmed version of much larger program but it still
exhibits the
13 matches
Mail list logo