Commit Graph

2369 Commits

Author SHA1 Message Date
Miss Islington (bot) fbb0151e5e
[3.11] IDLE: Condense run.main threading.Thread start. (GH-106125) (#106153)
IDLE: Condense run.main threading.Thread start. (GH-106125)

Use daemon argument added in 3.3 and directly call .start.
Remove now unused 'sockthread' name.
(cherry picked from commit eaa1eae55e)

Co-authored-by: Terry Jan Reedy <tjreedy@udel.edu>
2023-06-27 17:37:20 +00:00
Miss Islington (bot) c2df09fb4d
[3.11] gh-102832: IDLE - remove use of deprecated sys.last_xyzs for stackviewer (GH-103339) (#105527)
gh-102832: IDLE - remove use of deprecated sys.last_xyzs for stackviewer (GH-103339)
(cherry picked from commit 3ee921d84f)

Co-authored-by: Irit Katriel <1055913+iritkatriel@users.noreply.github.com>
2023-06-08 20:48:10 +00:00
Miss Islington (bot) 22618a86f4
[3.11] gh-104719: IDLE - test existence of all tokenize references. (GH-104767) (#104845)
gh-104719: IDLE - test existence of all tokenize references. (GH-104767)

Class editor.IndentSearcher contains all editor references to tokenize module.
Module io tokenize reference cover those other modules.

(cherry picked from commit e561c09975)

Co-authored-by: Terry Jan Reedy <tjreedy@udel.edu>
Co-authored-by: Jelle Zijlstra <jelle.zijlstra@gmail.com>
2023-05-24 08:46:33 -04:00
Miss Islington (bot) e033edab12
[3.11] gh-104719: IDLE - delete useless monkeypatch of tokenize (GH-104726) (#104727)
gh-104719: IDLE - delete useless monkeypatch of tokenize (GH-104726)
(cherry picked from commit 0c5e79bcdf)

Co-authored-by: Terry Jan Reedy <tjreedy@udel.edu>
2023-05-21 19:16:12 +00:00
Miss Islington (bot) 99a162a9a9
[3.11] gh-104499: Fix typo. (GH-104598) (#104599)
gh-104499: Fix typo. (GH-104598)
(cherry picked from commit c5b670efd1)

Co-authored-by: Terry Jan Reedy <tjreedy@udel.edu>
2023-05-18 13:54:45 -04:00
Miss Islington (bot) e96fb399c1
[3.11] gh-104499: IDLE - fix completions for tk aqua 8.7 (GH-104591) (#104596)
gh-104499: IDLE - fix completions for tk aqua 8.7 (GH-104591)
(cherry picked from commit 678bf57ed0)

Co-authored-by: Terry Jan Reedy <tjreedy@udel.edu>
2023-05-18 02:02:53 +00:00
Miss Islington (bot) 0560fd3f98
[3.11] gh-104496: IDLE - fix About for mixed tcl/tk versions (GH-104585) (#104587)
gh-104496: IDLE - fix About for mixed tcl/tk versions (GH-104585)

Print both if they are different, as may happen in the future.
(cherry picked from commit aed643baa9)

Co-authored-by: Terry Jan Reedy <tjreedy@udel.edu>
2023-05-17 20:31:22 +00:00
Miss Islington (bot) 03f0d75f1d
[3.11] GH-71383: IDLE - Document testing subsets of modules (GH-104463) (#104464)
GH-71383: IDLE - Document testing subsets of modules (GH-104463)
(cherry picked from commit 080a596152)

Co-authored-by: Terry Jan Reedy <tjreedy@udel.edu>
2023-05-14 04:18:30 +00:00
Miss Islington (bot) b87ccc38fe
[3.11] gh-75710: IDLE - add docstrings and comments to editor module (GH-104446) (#104450)
gh-75710: IDLE - add docstrings and comments to editor module (GH-104446)

Commit extracted from PR GH-3669.  Will edit more later.

(cherry picked from commit 46f1c78eeb)

Co-authored-by: Terry Jan Reedy <tjreedy@udel.edu>
Co-authored-by: Cheryl Sabella <cheryl.sabella@gmail.com>
2023-05-13 16:04:37 +00:00
Terry Jan Reedy 328b5dd829
[3.11] gh-99836: IDLE - update news.txt for 3.11+ (#104445)
* gh-99836: IDLE 3.11 News.txt

* gh-99836: IDLE - update news.txt for 3.11+
2023-05-13 04:47:21 +00:00
Miss Islington (bot) 9f191a1a77
[3.11] gh-88496: IDLE - fix another test on macOS (GH-104075) (#104076)
gh-88496: IDLE - fix another test on macOS (GH-104075)

Needed for Catalina: test_sidebar add 'idletasks' and skip assert.
(cherry picked from commit 690df4c16c)

Co-authored-by: Terry Jan Reedy <tjreedy@udel.edu>
2023-05-02 03:22:57 +00:00
Miss Islington (bot) 2e5f1a1259
[3.11] gh-88496: Fix IDLE test hang on macOS (GH-104025) (#104027)
gh-88496: Fix IDLE test hang on macOS (GH-104025)

Replace widget.update() with widget.update_idletasks in two places.
(cherry picked from commit 4b27972f5f)

Co-authored-by: Terry Jan Reedy <tjreedy@udel.edu>
2023-05-01 00:36:21 -04:00
Miss Islington (bot) 34df9e740d
[3.11] Change 'dependant' to 'dependent' (GH-103745) (#103754)
Co-authored-by: Christopher Chavez <chrischavez@gmx.us>
2023-04-24 08:22:24 -06:00
Miss Islington (bot) 5054459678
[3.11] gh-103668: Run pyugrade on idlelib (GH-103671) (#103730)
---------
(cherry picked from commit bd2dca035a)
Co-authored-by: Nikita Sobolev <mail@sobolevn.me>
Co-authored-by: Terry Jan Reedy tjreedy@udel.edu
2023-04-23 21:09:46 -04:00
Miss Islington (bot) d01cf5072b
IDLE: Simplify DynOptionsMenu __init__code (GH-101371)
Refactor DynOptionMenu's initializer to not copy  kwargs dict and use subscripting;
improve its htest.

(cherry picked from commit c41af812c9)

Co-authored-by: JosephSBoyle <48555120+JosephSBoyle@users.noreply.github.com>
Co-authored-by: Terry Jan Reedy <tjreedy@udel.edu>
2023-02-27 22:41:20 -08:00
Miss Islington (bot) 83f85539a1
IDLE - fix module browser test (GH-100647)
(cherry picked from commit 1f6c87ca7b)

Co-authored-by: Terry Jan Reedy <tjreedy@udel.edu>
2022-12-31 16:31:53 -08:00
Miss Islington (bot) 21fbf1631d
gh-97527: IDLE - fix buggy macosx patch (GH-98313)
GH-97530 fixed IDLE tests possibly crashing on a Mac without a GUI.
But it resulted in IDLE not starting in 3.10.8, 3.12.0a1, and
Microsoft Python 3.10.2288.0 when test/* is not installed.
After this patch, test.* is only imported when testing on Mac.
(cherry picked from commit 35fa5d5e7f)

Co-authored-by: Terry Jan Reedy <tjreedy@udel.edu>
2022-10-16 09:00:47 -07:00
Miss Islington (bot) ab2f1a6152
bpo-35675: IDLE - separate config_key window and frame (GH-11427)
bpo-35598: IDLE: Refactor window and frame class

Co-authored-by: Terry Jan Reedy <tjreedy@udel.edu>
(cherry picked from commit 1cc308d03c)

Co-authored-by: Cheryl Sabella <cheryl.sabella@gmail.com>
2022-09-30 10:08:36 -07:00
Miss Islington (bot) fe8db634d4
gh-97527: IDLE: protect macosx Tk() call when no GUI (GH-97530)
Only call tkinter.tk and its follow-up code in _init_tk_type when requires('gui')
does not raise.  This function can be called as an unintended side-effect of
calling other idlelib code as part of tests on macOS without a GUI enabled.
(cherry picked from commit 9704f8da33)

Co-authored-by: Terry Jan Reedy <tjreedy@udel.edu>
2022-09-24 15:09:08 -07:00
Miss Islington (bot) 98b81c2ac3
gh-87179: Fix more IDLE class headers (GH-96899)
Remove unneeded '(object)' and '()'.
(cherry picked from commit aa671b48d6)

Co-authored-by: Terry Jan Reedy <tjreedy@udel.edu>
2022-09-17 15:15:23 -07:00
Miss Islington (bot) bc06f5c5f7
gh-75500: Update idlelib/help.html (GH-96523) (#96524)
(cherry picked from commit 837ce6460d)

Co-authored-by: Terry Jan Reedy <tjreedy@udel.edu>

Co-authored-by: Terry Jan Reedy <tjreedy@udel.edu>
2022-09-03 10:57:07 +01:00
Gregory P. Smith f8b71da9aa
[3.11] gh-95778: CVE-2020-10735: Prevent DoS by very large int() (#96500)
Integer to and from text conversions via CPython's bignum `int` type is not safe against denial of service attacks due to malicious input. Very large input strings with hundred thousands of digits can consume several CPU seconds.

This PR comes fresh from a pile of work done in our private PSRT security response team repo.

This backports https://github.com/python/cpython/pull/96499 aka 511ca94520

Signed-off-by: Christian Heimes [Red Hat] <christian@python.org>
Tons-of-polishing-up-by: Gregory P. Smith [Google] <greg@krypto.org>
Reviews via the private PSRT repo via many others (see the NEWS entry in the PR).

<!-- gh-issue-number: gh-95778 -->
* Issue: gh-95778
<!-- /gh-issue-number -->

I wrote up [a one pager for the release managers](https://docs.google.com/document/d/1KjuF_aXlzPUxTK4BMgezGJ2Pn7uevfX7g0_mvgHlL7Y/edit#).
2022-09-02 09:48:57 -07:00
Miss Islington (bot) d55a775ac2
gh-78143: IDLE - fix settings dialog page label. (GH-96009)
'/Tab' should have been removed from the font page label
when the tab-spaces setting was moved to the Windows page.
(cherry picked from commit f6b811059a)

Co-authored-by: Terry Jan Reedy <tjreedy@udel.edu>
2022-08-15 16:33:16 -07:00
Miss Islington (bot) 577dbc3c49
gh-95841: IDLE - Revise Windows local doc url (GH-95845) (#95905)
GH-91242 replaced the Windows chm help file with a copy
of the html docs.  This PR replaces the IDLE code that
fetches the Windows local help url passed to os.startfile.

Co-authored-by: Terry Jan Reedy <tjreedy@udel.edu>
Co-authored-by: Steve Dower
Approved by Steve Dower, #95845 (review), 2nd subblock.

(cherry picked from commit bdb2cf8e91)
2022-08-11 20:11:17 -04:00
Miss Islington (bot) f8df88e07a
gh-84910: Change 'IDLE Help' to 'IDLE Doc' (GH-95873)
'IDLE Help' was a plain text file.  It was superceded years ago
by a copy of the much more complete html doc.  .
(cherry picked from commit 05a0f37029)

Co-authored-by: Terry Jan Reedy <tjreedy@udel.edu>
2022-08-11 14:14:30 -07:00
Miss Islington (bot) c6aa68fdf5
gh-75500: Add idlelib section to IDLE doc (GH-95832)
This enables accessing IDLE as 'idlelib' in the Doc Module listing.
(cherry picked from commit 70fc9641b5)

Co-authored-by: Terry Jan Reedy <tjreedy@udel.edu>
2022-08-09 12:33:23 -07:00
Terry Jan Reedy 1a22ec5d69
[3.11] gh-88878: IDLE - replace type('') with str (#95792)
Change in idlelib.browser, line 54
cherrypicked from 3680ebed7f
2022-08-09 13:42:16 -04:00
Miss Islington (bot) 77fccc29df
gh-95491: Mention IDLE Issue project in Readme (GH-95750) (#95791)
(cherry picked from commit 63140b445e)

Co-authored-by: Terry Jan Reedy <tjreedy@udel.edu>
2022-08-09 13:38:36 -04:00
Miss Islington (bot) 11f7d41ccf
gh-89362: Doc IDLE menu and search (GH-95697) (GH-95718)
Update menu item position and capitalization.
Add paragraph about search.
For help.html, include save-as addition.
(cherry picked from commit 834064c19a)

Co-authored-by: Terry Jan Reedy <tjreedy@udel.edu>
2022-08-06 19:01:10 +02:00
Miss Islington (bot) 1f48913db3
gh-95251: IDLE - Add What's New section to README (GH-95688) (GH-95726)
Document what I (TJR) currently do for 3.10/3.11.

Co-authored-by: Erlend E. Aasland <erlend.aasland@protonmail.com>
(cherry picked from commit a302a27489)

Co-authored-by: Terry Jan Reedy <tjreedy@udel.edu>
2022-08-06 18:55:49 +02:00
Miss Islington (bot) 4512a160d0
gh-65802: IDLE - explain SaveAs and extensions (GH-95690) (GH-95692)
File name extensions may or may not be shown for the current name
and are added in an OS-dependent manner if not given for the new
name.
(cherry picked from commit 9890f86ae2)

Co-authored-by: Terry Jan Reedy <tjreedy@udel.edu>
2022-08-05 09:42:21 +02:00
Miss Islington (bot) 390c80d2c4
gh-95638: Update idlelib README file and menu lists (GH-95639)
(cherry picked from commit 621b33ce25)

Co-authored-by: Terry Jan Reedy <tjreedy@udel.edu>
2022-08-04 01:01:55 -07:00
Miss Islington (bot) 1ed023b7c0
gh-95597: Fix typo in Lib directory files (GH-95599)
(cherry picked from commit b53aed76d2)

Co-authored-by: Jo, Yunjin <black33jo@gmail.com>
2022-08-03 14:43:01 -07:00
Miss Islington (bot) 8570f6d1a0
gh-95191: IDLE: Include prompts when saving Shell GH-95554 (#95557)
(cherry picked from commit b85411fc5e)

Co-authored-by: Terry Jan Reedy <tjreedy@udel.edu>
2022-08-02 02:14:19 -04:00
Miss Islington (bot) 118851b8ba
gh-83270: Update IDLE's credits (GH-95528)
Co-authored-by: Terry Jan Reedy <tjreedy@udel.edu>
(cherry picked from commit 698fa8bf60)

Co-authored-by: Erlend Egeberg Aasland <erlend.aasland@protonmail.com>
2022-08-01 21:54:28 -07:00
Miss Islington (bot) e4541c474a
gh-95511: IDLE - fix Shell context menu copy-with-prompts bug (GH-95512)
If one selects whole lines, as the sidebar makes easy, do not
add an extra line.  Only move the end of a selection to the
beginning of the next line when not already at the beginning
of a line.  (Also improve the surrounding code.)
(cherry picked from commit fc31a13dc1)

Co-authored-by: Terry Jan Reedy <tjreedy@udel.edu>
2022-07-31 22:32:33 -07:00
Miss Islington (bot) ab444b7fc6
IDLE: Fix docs URL in the About window (GH-28417)
(cherry picked from commit 0f17a754d9)

Co-authored-by: Serhiy Storchaka <storchaka@gmail.com>
2022-07-31 14:11:35 -07:00
Miss Islington (bot) 3ca0016939
gh-95471: IDLE - Tweak Edit menu (GH-95481)
Move `Select All` above  `Cut` as it is used with `Cut` and `Copy` but not `Paste`.  Add a separator between `Replace` and `Go to Line` to separate items that belong to the 'Edit-find' (above) and 'Edit-show' (below) IDLE github project topics.
(cherry picked from commit 53357b3ee5)

Co-authored-by: Terry Jan Reedy <tjreedy@udel.edu>
2022-07-30 18:34:04 -07:00
Miss Islington (bot) cfef4df7ce
gh-90654: IDLE - Insert blank line in NEWS.txt (GH-95478)
Needed for backports.
(cherry picked from commit 9ec6abf6dc)

Co-authored-by: Terry Jan Reedy <tjreedy@udel.edu>
2022-07-30 13:24:13 -07:00
Miss Islington (bot) a459ee9543
gh-95411: IDLE - Enable using the module browser with .pyw files (GH-95397)
Co-authored-by: Terry Jan Reedy <tjreedy@udel.edu>
(cherry picked from commit 7e19e417b5)

Co-authored-by: Erlend Egeberg Aasland <erlend.aasland@protonmail.com>
2022-07-29 22:09:32 -07:00
Miss Islington (bot) 309c8f316d
gh-89610: Add .pyi as a recognised extension for IDLE on macOS (GH-95393)
This allows opening stub files by double clicking on them in the Finder.

Co-authored-by: Terry Jan Reedy <tjreedy@udel.edu>
(cherry picked from commit 06fc249135)

Co-authored-by: Erlend Egeberg Aasland <erlend.aasland@protonmail.com>
2022-07-28 16:28:50 -07:00
Miss Islington (bot) 57375d1d74
gh-90654: Remove unneeded blank line (GH-95044) (#95047)
(cherry picked from commit bd390ef825)

Co-authored-by: Terry Jan Reedy <tjreedy@udel.edu>

Co-authored-by: Terry Jan Reedy <tjreedy@udel.edu>
2022-07-20 18:03:35 -04:00
Miss Islington (bot) 1093804b88
gh-90654: Add item missing from idlelib/NEWS.txt (GH-95038)
(cherry picked from commit acb105a7c1)

Co-authored-by: Terry Jan Reedy <tjreedy@udel.edu>
2022-07-20 00:43:27 -07:00
Miss Islington (bot) 29fc20cdc0
idlelib: replace 'while 1' with 'while True' (GH-94827)
(cherry picked from commit 6a15f918b5)

Co-authored-by: Terry Jan Reedy <tjreedy@udel.edu>
2022-07-13 18:33:29 -07:00
John Belmonte 45896f2a02
[3.11] gh-93883: elide traceback indicators when possible (GH-93994) (GH-94740)
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
2022-07-11 04:27:29 -07:00
Miss Islington (bot) 1e7efbc449
IDLE doc: Tweek RESTART and Windows console start (GH-94530)
(cherry picked from commit 39c29f753e)

Co-authored-by: Terry Jan Reedy <tjreedy@udel.edu>
2022-07-03 10:20:48 -07:00
Miss Islington (bot) 1d2c8ff38f
gh-82006: IDLE doc improvements (GH-94349)
0. Update text start and stop conditions.
1. Title-case sections but not subsections.
2. Edit Shell Window sections: title, execute, restart.
(cherry picked from commit e6391e08bf)

Co-authored-by: Terry Jan Reedy <tjreedy@udel.edu>
2022-06-27 16:24:08 -07:00
Terry Jan Reedy bc8d81a8fe
[3.11] gh-84623: Remove unused imports in stdlib (#94313)
#93773

Backport only for 2 idlelib files.
Cherrypicked from  259dd71c32
2022-06-26 23:54:10 -04:00
Miss Islington (bot) b140e5a4ac
IDLE: replace if statement with expression (GH-94228)
(cherry picked from commit 91f9947f23)

Co-authored-by: Terry Jan Reedy <tjreedy@udel.edu>
2022-06-24 10:30:32 -07:00
Miss Islington (bot) a562d2dc8b
gh-84623: Remove unused imports in idlelib (GH-94143)
Remove commented code in test_debugger_r.py.

Co-authored-by: Terry Jan Reedy <tjreedy@udel.edu>
(cherry picked from commit 576dd90117)

Co-authored-by: Victor Stinner <vstinner@python.org>
2022-06-22 15:36:47 -07:00