cpython/Misc
Michał Górny 33494b4d0d
gh-130959: Reject whitespace in fractions, in pure Python fromisoformat() (#130962)
* gh-130959: Reject whitespace in fractions, in pure Python `fromisoformat()`

Fix the pure Python implementation of `fromisoformat()` to reject any
non-digit characters, including whitespace, in the fractional part
of time specification.  This makes the behavior consistent with the C
implementation, and prevents incorrect parsing of these fractions
(e.g. `.400 ` would be misinterpreted as `.04`).

* Add the news entry

* Use a different example to fix Sphinx lint

* Apply suggestions from code review

Co-authored-by: Peter Bierma <zintensitydev@gmail.com>
Co-authored-by: Paul Ganssle <1377457+pganssle@users.noreply.github.com>

* Try fixing `:func:` ref.

---------

Co-authored-by: Peter Bierma <zintensitydev@gmail.com>
Co-authored-by: Paul Ganssle <1377457+pganssle@users.noreply.github.com>
2025-03-11 10:15:40 +01:00
..
NEWS.d gh-130959: Reject whitespace in fractions, in pure Python fromisoformat() (#130962) 2025-03-11 10:15:40 +01:00
rhel7
ACKS gh-124927: Fix conversion issue between coordinates and position in REPL (#125001) 2025-03-10 21:54:49 +00:00
externals.spdx.json
HISTORY
indent.pro
platform_triplet.c
Porting
python-config.in
python-config.sh.in
python-embed.pc.in
python.man Correct typo in GH-129623 (#130079) 2025-02-14 16:27:17 +00:00
python.pc.in
README
README.AIX
README.valgrind
sbom.spdx.json gh-129467: Fix compiler warning in mpdecimal word_to_string() (#116346) 2025-01-30 11:57:55 +01:00
SpecialBuilds.txt GH-129763: Remove the LLTRACE macro (GH-129764) 2025-02-07 08:49:51 -08:00
stable_abi.toml gh-91417: Remove PySequence_Fast() from the limited C API (#129398) 2025-02-02 23:17:30 +01:00
svnmap.txt
valgrind-python.supp
vgrindefs

Python Misc subdirectory
========================

This directory contains files that wouldn't fit in elsewhere.  Some
documents are only of historic importance.

Files found here
----------------

ACKS                    Acknowledgements
HISTORY                 News from previous releases -- oldest last
indent.pro              GNU indent profile approximating my C style
NEWS                    News for this release (for some meaning of "this")
Porting                 Mini-FAQ on porting to new platforms
python-config.in        Python script template for python-config
python.man              UNIX man page for the python interpreter
python.pc.in            Package configuration info template for pkg-config
README                  The file you're reading now
README.AIX              Information about using Python on AIX
README.valgrind         Information for Valgrind users, see valgrind-python.supp
SpecialBuilds.txt       Describes extra symbols you can set for debug builds
svnmap.txt              Map of old SVN revs and branches to hg changeset ids,
                        help history-digging
valgrind-python.supp    Valgrind suppression file, see README.valgrind
vgrindefs               Python configuration for vgrind (a generic pretty printer)