* PEP 540: Update based on PEP 538 experience
- CentOS 7 is a better example of problems than Alpine Linux
(default locale is C/POSIX, C.UTF-8 isn't available for coercion)
- reword the annex discussing the design trade-offs between
PEP 538's locale coercion and PEP 540's introduction of a
UTF-8 specific mode
* Tweak wording of PEP 538 comparison
Mention an updated schedule for non-provisional status and the end of
non-typing annotations in PEP 563, and link there for the __future__
statement as well.
Neither of the authors of these PEPs are currently actively
championing them, and offering dedicated constructs for
working with partially structured hierarchical data is
still a relatively novel programming language design concept
in general.
Since there's no harm in waiting for more feedback and ideas,
deferring them for potential future consideration seems like a
good option for now.
- note advice for test runners in abstract
- add explicit sections for test runner and
interactive shell guidance
- simplify the warning category descriptions
by moving the test runner details to their
new section
- make it clear FutureWarning is gaining a
second use case, while also keeping its old
one
- note that IPython already follows the new
guidance for interactive shells (and use
their approach as an example)
- reword the advice for library and framework
authors wanting seeking noisier compatibility
warnings on earlier Python versions
The major changes from the previous version are:
- Add InitVar to specify initialize-only fields.
- Renamed __dataclass_post_init__() to __post_init().
- Rename cmp to compare.
- Added eq, separate from compare, so you can test
unorderable items for equality.
- Flushed out asdict() and astuple().
- Changed replace() to just call __init__(), and dropped
complex post-create logic.