summaryrefslogtreecommitdiffstats
path: root/Lib/idlelib/idle_test/test_run.py
Commit message (Collapse)AuthorAgeFilesLines
* [3.11] gh-93883: elide traceback indicators when possible (GH-93994) (GH-94740)John Belmonte2022-07-111-9/+4
| | | | | | | | | | | | | | | | | | | | | | | | | | | | Elide traceback column indicators when the entire line of the frame is implicated. This reduces traceback length and draws more attention to the remaining (very relevant) indicators. Example: ``` Traceback (most recent call last): File "query.py", line 99, in <module> bar() File "query.py", line 66, in bar foo() File "query.py", line 37, in foo magic_arithmetic('foo') File "query.py", line 18, in magic_arithmetic return add_counts(x) / 25 ^^^^^^^^^^^^^ File "query.py", line 24, in add_counts return 25 + query_user(user1) + query_user(user2) ^^^^^^^^^^^^^^^^^ File "query.py", line 32, in query_user return 1 + query_count(db, response['a']['b']['c']['user'], retry=True) ~~~~~~~~~~~~~~~~~~^^^^^ TypeError: 'NoneType' object is not subscriptable ``` Automerge-Triggered-By: GH:pablogsal
* bpo-43950: Add option to opt-out of PEP-657 (GH-27023)Ammar Askar2021-07-071-4/+9
| | | | | Co-authored-by: Pablo Galindo <Pablogsal@gmail.com> Co-authored-by: Batuhan Taskaya <batuhanosmantaskaya@gmail.com> Co-authored-by: Ammar Askar <ammar@ammaraskar.com>
* bpo-43950: Print columns in tracebacks (PEP 657) (GH-26958)Ammar Askar2021-07-041-3/+3
| | | | | | | | The traceback.c and traceback.py mechanisms now utilize the newly added code.co_positions and PyCode_Addr2Location to print carets on the specific expressions involved in a traceback. Co-authored-by: Pablo Galindo <Pablogsal@gmail.com> Co-authored-by: Ammar Askar <ammar@ammaraskar.com> Co-authored-by: Batuhan Taskaya <batuhanosmantaskaya@gmail.com>
* bpo-44026: Idle - display interpreter's 'did you mean' hints (GH-25912)E-Paine2021-05-071-4/+43
| | | | | | | A C function accessible by the default exception handler, but not by python code, finds the existing name closest to the name causing a name or attribute error. For such errors, call the default handler after capturing stderr and retrieve its message line. Co-authored-by: Terry Jan Reedy <tjreedy@udel.edu>
* bpo-43008: Make IDLE respect sys.excepthook (GH-24302)Ken2021-01-261-4/+39
| | | Co-authored-by: Terry Jan Reedy <tjreedy@udel.edu>
* bpo-41514: Fix buggy IDLE test (GH-21808)Terry Jan Reedy2020-08-101-5/+5
| | | | | | test_run method test_fatal_error failed when run twice, as with python -m test -m test_fatal_error test_idle test_idle because func.called was not reinitialized to 0. This bug caused a failure on a refleak buildbot.
* bpo-41468: Improve and test IDLE run error exit (GH-21798)Terry Jan Reedy2020-08-091-2/+30
| | | A message box pops up when an unexpected error stops the run process. Tell users it is likely a random glitch, but report it if not.
* Improve renamed test_run.RecursionLimitTest (GH-21794)Terry Jan Reedy2020-08-091-3/+5
| | | PEP 8 style and new comments.
* bpo-36698: IDLE no longer fails when write non-encodable characters to ↵Serhiy Storchaka2019-10-081-20/+40
| | | | | | | stderr. (GH-16583) It now escapes them with a backslash, as the regular Python interpreter. Added the "errors" field to the standard streams.
* bpo-26806: IDLE should run without docstrings (#14657)Terry Jan Reedy2019-07-091-0/+8
| | | After fcf1d00, IDLE startup failed with python compiled without docstrings.
* bpo-26806: add 30 to the recursion limit in IDLE's shell (GH-13944)Tal Einat2019-07-061-0/+33
| | | | | | | | This is done to compensate for the extra stack frames added by IDLE itself, which cause problems when setting the recursion limit to low values. This wraps sys.setrecursionlimit() and sys.getrecursionlimit() as invisibly as possible.
* bpo-33855: More edits and new minimal tests for IDLE (GH-7761)Terry Jan Reedy2018-06-181-4/+233
| | | | Part 2 of 3. Continues PR #7689, changeset ee5ef30. Edit and add tests for 18 modules, help_about to replace and run.
* bpo-28603: Fix formatting tracebacks for unhashable exceptions (#4014)Zane Bitter2017-10-171-0/+35