Commit Graph

1518 Commits

Author SHA1 Message Date
Miss Islington (bot) f0104d2a2d
gh-115543: Update py.exe to know about Python 3.13 and to install 3.12 by default (GH-115544)
(cherry picked from commit 6cd18c75a4)

Co-authored-by: Steve Dower <steve.dower@python.org>
2024-02-19 21:05:04 +00:00
Miss Islington (bot) 279bbd2134
gh-100107: Make py.exe launcher ignore app aliases that launch Microsoft Store (GH-114358)
(cherry picked from commit d5c21c12c1)

Co-authored-by: Vincent Cunningham <flagrama@users.noreply.github.com>
2024-01-25 00:37:46 +00:00
Hugo van Kemenade d678ee7719
[3.11] Trim trailing whitespace and test on CI (GH-104275) (#108215) 2023-08-22 12:57:31 +03:00
Miss Islington (bot) e98fa7121d
gh-101467: Correct py.exe handling of prefix matches and cases when only one runtime is installed (GH-101468)
(cherry picked from commit eda60916bc)

Co-authored-by: Steve Dower <steve.dower@python.org>
2023-02-01 13:31:21 -08:00
Miss Islington (bot) 5a8ed019f9
gh-101135: Add backwards compatibility to Windows launcher for older 32-bit versions (GH-101138)
Python 2.x and up to 3.4 did not contain the "-32" in their registry name, so the 32 and 64-bit installs were treated equal. Since 3.5/PEP 514 this is no longer true, but we still want to detect the EOL versions correctly in case people are still using them.

Additionally, the code to replace a node with one with a lower sort key was buggy (wrong node chosen, replace never happened since parent was always NULL, replaced node never freed, etc)
(cherry picked from commit daec3a463c)

Co-authored-by: Martin Boisvert <martin.boisvert@optelgroup.com>
2023-01-24 09:04:00 -08:00
Miss Islington (bot) 6492492ce7
gh-100247: Fix py.exe launcher not using entire shebang command for finding custom commands (GH-100944)
(cherry picked from commit 468c3bf798)

Co-authored-by: Steve Dower <steve.dower@python.org>
2023-01-13 04:52:28 -08:00
Miss Islington (bot) 07d1f99e8f
[3.11] Update copyright years to 2023. (gh-100848) (GH-100849)
(cherry picked from commit 11f99323c2)

Co-authored-by: Benjamin Peterson <benjamin@python.org>
2023-01-08 17:57:17 -08:00
Miss Islington (bot) 3939a4b7d9
bpo-43984: Allow winreg.SetValueEx to set -1 without treating it as an error (GH-25775)
(cherry picked from commit a29a7b9b78)

Co-authored-by: Shreyan Avigyan <shreyan.avigyan@gmail.com>
2022-12-09 05:12:43 -08:00
Miss Islington (bot) d74117acc1
Use faster APIs to calculate paths at startup for Store packaged Python on Windows (GH-99345)
(cherry picked from commit 71a4a2da98)

Co-authored-by: Steve Dower <steve.dower@python.org>
2022-11-23 12:12:34 -08:00
Miss Islington (bot) d5e6f9b0ab
gh-99442: Fix handling in py.exe launcher when argv[0] does not include a file extension (GH-99542)
(cherry picked from commit a220c6d1ee)
2022-11-18 17:49:14 +00:00
Miss Islington (bot) 46a3cf4fe3
gh-98692: Enable treating shebang lines as executables in py.exe launcher (GH-98732)
(cherry picked from commit 88297e2a8a)

Co-authored-by: Steve Dower <steve.dower@python.org>
2022-10-31 14:31:26 -07:00
Miss Islington (bot) 9f01a2793a
gh-98745: Allow py.exe launcher to install 3.11 by default and 3.12 on request (GH-98780)
(cherry picked from commit 25811d9010)

Co-authored-by: Steve Dower <steve.dower@python.org>
2022-10-28 02:40:00 -07:00
Miss Islington (bot) 0b71dad9b8
gh-98414: py.exe launcher does not use defaults for -V:company/ option (GH-98460)
(cherry picked from commit 4bd63f66cd)

Co-authored-by: Steve Dower <steve.dower@python.org>
2022-10-19 15:41:28 -07:00
Serhiy Storchaka f07ee41479
[3.11] gh-97728: Argument Clinic: Fix uninitialized variable in the Py_UNICODE converter (GH-97729) (GH-97757)
It affects function os.system() on Windows and Windows-specific modules
winreg, _winapi, _overlapped, and _msi.
(cherry picked from commit 0ee9619a4c)
2022-10-03 15:01:54 +03:00
Miss Islington (bot) 9fa21d050a
gh-96577: Fixes buffer overrun in _msi module (GH-96633)
(cherry picked from commit 4114bcc9ef)

Co-authored-by: Steve Dower <steve.dower@python.org>
2022-09-07 12:46:09 -07:00
Miss Islington (bot) 08d8058b79
gh-96559: Fixes Windows launcher handling of defaults using old-style tags, and adds What's New section (GH-96595)
(cherry picked from commit 80a9bd2e94)

Co-authored-by: Steve Dower <steve.dower@python.org>
2022-09-05 15:13:24 -07:00
Miss Islington (bot) 2c0017b5e6
gh-94399: Restore PATH search behaviour of py.exe launcher for '/usr/bin/env' shebang lines (GH-95582)
(cherry picked from commit 67840edb28)

Co-authored-by: Steve Dower <steve.dower@python.org>
2022-08-03 15:00:46 -07:00
Steve Dower 1016df0a23
gh-95423: Update winreg.DeleteKeyEx documentation and remove dynamic function load (GH-95521)
Co-authored-by: Derek Kim <ddkim1024@gmail.com>
2022-08-03 22:25:47 +01:00
Christian Heimes 06b5f78d64
[3.11] gh-95174: WASI: skip missing sockets functions (GH-95179) (GH-95308)
Co-authored-by: Christian Heimes <christian@python.org>
Co-authored-by: Pablo Galindo Salgado <Pablogsal@gmail.com>
2022-07-31 18:19:32 +02:00
Christian Heimes db13c0c1b8
[3.11] gh-95174: Handle missing dup() and constants in WASI (GH-95229) (GH-95272)
Co-authored-by: Christian Heimes <christian@python.org>
2022-07-31 16:39:41 +01:00
Miss Islington (bot) 1368a1f724
gh-95359: Fix py.exe launcher handling of per-user py.ini and command names (GH-95399)
(cherry picked from commit 38bb2068fe)

Co-authored-by: Steve Dower <steve.dower@python.org>
2022-07-28 13:52:13 -07:00
Miss Islington (bot) 7df3a1ce4b
gh-95285: py.exe launcher fails with short argv0 (GH-95295) (GH-95298)
(cherry picked from commit 7ac5bb3e6a)

Co-authored-by: Steve Dower <steve.dower@python.org>
2022-07-27 10:06:59 +02:00
Miss Islington (bot) 8c08e86d8d
gh-90844: Allow virtual environments to correctly launch when they have spaces in the path (GH-94903)
(cherry picked from commit 4b4439daed)

Co-authored-by: Steve Dower <steve.dower@python.org>
2022-07-16 10:11:34 -07:00
Miss Islington (bot) b040617195
gh-94772: Fix off-by-one error in Windows launcher (GH-94779)
(cherry picked from commit 407ff6556c)

Co-authored-by: Paul Moore <p.f.moore@gmail.com>

Co-authored-by: Paul Moore <p.f.moore@gmail.com>
2022-07-16 10:42:08 +01:00
Miss Islington (bot) 516d90eb21
gh-93491: Add support tier detection to configure (GH-93492)
Co-authored-by: Adam Turner <9087854+AA-Turner@users.noreply.github.com>
Co-authored-by: Steve Dower <steve.dower@microsoft.com>
Co-authored-by: Erlend Egeberg Aasland <erlend.aasland@protonmail.com>
(cherry picked from commit 3124d9a5aa)

Co-authored-by: Christian Heimes <christian@python.org>
2022-06-10 06:50:26 -07:00
Miss Islington (bot) 8c5739e425
gh-93005: Fixes launcher test when no Python install is available (GH-93007)
(cherry picked from commit 949dbf97ba)

Co-authored-by: Steve Dower <steve.dower@python.org>
2022-05-23 09:42:41 -07:00
Miss Islington (bot) a2ec09b7f5
gh-92817: Fix precedence of options to py.exe launcher (GH-92988)
(cherry picked from commit 73473fdeac)

Co-authored-by: Steve Dower <steve.dower@python.org>
2022-05-19 16:10:38 -07:00
Miss Islington (bot) 635b62a376
[3.11] gh-76773: Update docs mentioning no-longer-supported Windows versions & features (GH-92529) (GH-92608)
(cherry picked from commit f1bbcba74f)


Co-authored-by: CAM Gerlach <CAM.Gerlach@Gerlach.CAM>

Automerge-Triggered-By: GH:serhiy-storchaka
2022-05-10 02:55:36 -07:00
Victor Stinner b270b82f11
gh-91320: Argument Clinic uses _PyCFunction_CAST() (#32210)
Replace "(PyCFunction)(void(*)(void))func" cast with
_PyCFunction_CAST(func).
2022-05-03 20:25:41 +02:00
Ganesh Kathiresan d414f7ece8
gh-90822: Make `PY_SSIZE_T_MAX` and `PY_SSIZE_T_MIN` constant expression (GH-92071) 2022-05-02 17:23:28 +09:00
Petr Viktorin 6dcbc08c95
gh-91324: List feature macros in the stable ABI manifest, improve tests (GH-32415) 2022-04-28 16:30:28 +02:00
Petr Viktorin ac4ffd3be2
bpo-47169: Export PyOS_CheckStack on Windows (GH-32414) 2022-04-21 18:03:25 +02:00
Barry Warsaw 7173fd5de0
Remove the ancient Pynche color editor (#91554)
Closes #91551
2022-04-17 15:38:44 -07:00
Irit Katriel 5d421d7342
gh-90501: Add PyErr_GetHandledException and PyErr_SetHandledException (GH-30531) 2022-04-15 19:57:47 +01:00
Steve Dower 2390b2236d
bpo-47239: Fixes py.exe output when run in a virtual environment. (GH-32364) 2022-04-07 00:09:54 +01:00
Steve Dower bad86a621a
bpo-46566: Add new py.exe launcher implementation (GH-32062) 2022-03-29 00:21:08 +01:00
Steve Dower 3751b6b030
bpo-47086: Remove .chm from Windows installer and add HTML docs (GH-32038) 2022-03-22 01:08:37 +00:00
Victor Stinner 4657bf7016
bpo-1635741: Fix winreg reference leaks (GH-31560)
Clear also the PyHKEY_Type static type at exit.
2022-02-25 12:34:00 +01:00
Steve Dower 3a5afc14e1
bpo-46638: Makes registry virtualisation setting stable when building MSIX packages (GH-31130) 2022-02-07 16:59:40 +00:00
Steve Dower 9b4e3d94a5
bpo-46629: Update classicAppCompat.sccd for new signing certificate (GH-31111) 2022-02-04 16:11:19 +00:00
Manish Kumar ⛄ ba650af7d6
Optimize images by IMGbot (GH-21348)
Co-authored-by: ImgBotApp <ImgBotHelp@gmail.com>
2022-02-04 15:49:43 +09:00
Oleg Iarygin 38e0b9efdf
bpo-37705: Remove orphaned PC/errmap.mak (GH-29724)
After GH-15623 deleted `generrmap.c`, a related mak-file stopped working. The mak contains generrmap-related rules only so it should be removed altogether.

Further search for `errmap\.mak|generrmap` regex through content of CPython files shows no dangling reference left.

Since generrmap is already effectively removed, this pull request contains no blurp.
2022-02-02 08:23:30 -08:00
Christian Heimes f66c857572
bpo-45459: Add Py_buffer to limited API (GH-29991)
- [x] ``Py_buffer`` struct
- [x] ``PyBuffer_*()`` API functions
- [x] ``PyBUF_*`` constants
- [x] ``Py_bf_getbuffer`` and ``Py_bf_releasebuffer`` type slots
- [x] ``PyMemoryView_FromBuffer()`` API
- [x] tests for limited API
- [x] ``make regen-limited-abi``
- [x] documentation update
- [ ] export ``PyPickleBuffer*()`` API ???
2022-02-02 07:03:10 -08:00
Christian Heimes a6ca8eee22
bpo-46315: Add ifdef HAVE_ feature checks for WASI compatibility (GH-30507) 2022-01-13 09:46:04 +01:00
Victor Stinner 08bc1bad11
bpo-46303: Fix fileutils.h compiler warnings (GH-30550)
Add missing pycore_fileutils.h include in _tkinter.c and
_testconsole.c.
2022-01-12 00:35:26 +01:00
Mark Shannon e028ae99ec
bpo-45923: Handle call events in bytecode (GH-30364)
* Add a RESUME instruction to handle "call" events.
2022-01-06 13:09:25 +00:00
Benjamin Peterson ba00f0d93a
Update copyright year to 2022. (GH-30335)
Automerge-Triggered-By: GH:benjaminp
2022-01-02 12:08:48 -08:00
Gabriele N. Tornetta 50669083fe
bpo-43931: Export Python version as API data (GH-25577)
When Python is embedded in other applications, it is not easy to determine which version of Python is being used. This change exposes the Python version as part of the API data. Tools like Austin (https://github.com/P403n1x87/austin) can benefit from this data when targeting applications like uWSGI, as the Python version can then be inferred systematically by looking at the exported symbols rather than relying on unreliable pattern matching or other hacks (like remote code execution etc...).

Automerge-Triggered-By: GH:pablogsal
2021-12-09 17:52:05 -08:00
Mark Shannon 8319114fee
bpo-45947: Place dict and values pointer at fixed (negative) offset just before GC header. (GH-29879)
* Place __dict__ immediately before GC header for plain Python objects.

* Fix up lazy dict creation logic to use managed dict pointers.

* Manage values pointer, placing them directly before managed dict pointers.

* Convert hint-based load/store attr specialization target managed dict classes.

* Specialize LOAD_METHOD for managed dict objects.

* Remove unsafe _PyObject_GC_Calloc function.

* Remove unsafe _PyObject_GC_Malloc() function.

* Add comment explaning use of Py_TPFLAGS_MANAGED_DICT.
2021-12-07 16:02:53 +00:00
Steve Dower 99fcf15052
bpo-45582: Port getpath[p].c to Python (GH-29041)
The getpath.py file is frozen at build time and executed as code over a namespace. It is never imported, nor is it meant to be importable or reusable. However, it should be easier to read, modify, and patch than the previous code.

This commit attempts to preserve every previously tested quirk, but these may be changed in the future to better align platforms.
2021-12-03 00:08:42 +00:00