Skip to content

GitLab

  • Menu
Projects Groups Snippets
  • Help
    • Help
    • Support
    • Community forum
    • Submit feedback
    • Contribute to GitLab
  • Sign in / Register
  • pypy pypy
  • Project information
    • Project information
    • Activity
    • Labels
    • Members
  • Repository
    • Repository
    • Files
    • Commits
    • Branches
    • Tags
    • Contributors
    • Graph
    • Compare
  • Issues 668
    • Issues 668
    • List
    • Boards
    • Service Desk
    • Milestones
  • Merge requests 14
    • Merge requests 14
  • CI/CD
    • CI/CD
    • Pipelines
    • Jobs
    • Schedules
  • Deployments
    • Deployments
    • Environments
    • Releases
  • Monitor
    • Monitor
    • Incidents
  • Packages & Registries
    • Packages & Registries
    • Container Registry
  • Analytics
    • Analytics
    • Value stream
    • CI/CD
    • Repository
  • Wiki
    • Wiki
  • Snippets
    • Snippets
  • Activity
  • Graph
  • Create a new issue
  • Jobs
  • Commits
  • Issue Boards
Collapse sidebar
  • PyPy
  • pypypypy
  • Issues
  • #1929

Closed
Open
Created Nov 20, 2014 by Bitbucket Importer@bitbucket_importerMaintainer

tkinter broken for threaded Python on both pypy2 and pypy3

Created originally on Bitbucket by christopherthemagnificent (Christopher Johnson)

I have a very large multi-threaded Python 3 and Tkinter project that I want to move to PyPy 3.

While moving my code over, I discovered that PyPy is broken in supporting threads.

So I made a small test program that demonstrates the bug. Here is the output displayed when running the program:

$ pypy3 tkintertest.py Exception in thread secondary: Traceback (most recent call last): File "/Users/christopher/bin/pypy3-2.4.0-osx64/lib-python/3/threading.py", line 740, in _bootstrap_inner self.run() File "/Users/christopher/bin/pypy3-2.4.0-osx64/lib-python/3/threading.py", line 693, in run self._target(*self._args, **self._kwargs) File "tkintertest.py", line 11, in secondary canvas.create_text(100, 50, text="Secondary thread") File "/Users/christopher/bin/pypy3-2.4.0-osx64/lib-python/3/tkinter/init.py", line 2256, in create_text return self._create('text', args, kw) File "/Users/christopher/bin/pypy3-2.4.0-osx64/lib-python/3/tkinter/init.py", line 2232, in _create *(args + self._options(cnf, kw)))) File "/Users/christopher/bin/pypy3-2.4.0-osx64/lib_pypy/_tkinter/app.py", line 286, in call raise NotImplementedError("Call from another thread") NotImplementedError: Call from another thread

I cannot run my project on PyPy unless this gets fixed, and I cannot code around it, so I wish you all luck in working on this issue!

By the way, I tried running my test on PyPy 2 (with the Tkinter module name changed to capital T) and it failed with the same identical output. So PyPy 2 also need to be fixed.

I am running this on OS X 10.9.5 Mavericks. With the following displayed when I run PyPy interactively: Python 3.2.5 (b2091e973da6, Oct 19 2014, 18:30:58) [PyPy 2.4.0 with GCC 4.2.1 Compatible Apple LLVM 6.0 (clang-600.0.51)] on darwin

--Christopher

Attachments: tkintertest.py

To upload designs, you'll need to enable LFS and have an admin enable hashed storage. More information
Assignee
Assign to
Time tracking