[New-bugs-announce] [issue26571] turtle regression in 3.5

Ellison Marks report at bugs.python.org
Wed Mar 16 00:59:15 EDT 2016

New submission from Ellison Marks:

I noticed some odd behaviour when running some turtle code I wrote using python 3.5. A simplified example:

>>> from turtle import Turtle
>>> t = Turtle()
>>> t.getscreen().bye() # or manually close the turtle window
>>> t2 = Turtle()
Traceback (most recent call last):
  File "<stdin>", line 1, in <module>
  File "/usr/lib64/python3.5/turtle.py", line 3816, in __init__
  File "/usr/lib64/python3.5/turtle.py", line 2557, in __init__
  File "/usr/lib64/python3.5/turtle.py", line 2660, in _update
  File "/usr/lib64/python3.5/turtle.py", line 2646, in _update_data
  File "/usr/lib64/python3.5/turtle.py", line 1292, in _incrementudc
    raise Terminator

This code works under 3.4, opening a new turtle window the second time Turtle() is called. Under 3.5, a blank white window opens.

This seems to be related to https://hg.python.org/cpython/rev/1628484c9408, as the only point that raises Terminator is guarded by a check for `if not TurtleScreen._RUNNING:`

components: Library (Lib)
messages: 261840
nosy: Ellison Marks
priority: normal
severity: normal
status: open
title: turtle regression in 3.5
type: behavior
versions: Python 3.5

Python tracker <report at bugs.python.org>

More information about the New-bugs-announce mailing list