There was an error while loading. Please reload this page.
turtle.TurtleGraphicsError
1 parent d3369c2 commit 31f9070Copy full SHA for 31f9070
1 file changed
Doc/library/turtle.rst
@@ -2570,6 +2570,25 @@ Public classes
2570
* ``a.rotate(angle)`` rotation
2571
2572
2573
+Exceptions
2574
+==========
2575
+
2576
+The :mod:`!turtle` module defines the following exception:
2577
2578
+.. exception:: TurtleGraphicsError
2579
2580
+ Raised for invalid arguments or operations.
2581
+ For example, a malformed color string:
2582
2583
+ .. doctest::
2584
+ :skipif: _tkinter is None
2585
2586
+ >>> turtle.color("blau")
2587
+ Traceback (most recent call last):
2588
+ ...
2589
+ turtle.TurtleGraphicsError: bad color string: blau
2590
2591
2592
.. _turtle-explanation:
2593
2594
Explanation
0 commit comments