This feature release adds support for PEP 728 (TypedDict with extra
items) and PEP 742 (TypeIs).
There are no changes since 4.10.0rc1.
4.10.0rc1
Release 4.10.0rc1 (February 17, 2024)
Add support for PEP 728, supporting the closed keyword argument and the
special __extra_items__ key for TypedDict. Patch by Zixuan James Li.
Add support for PEP 742, adding typing_extensions.TypeIs. Patch
by Jelle Zijlstra.
Drop runtime error when a read-only TypedDict item overrides a mutable
one. Type checkers should still flag this as an error. Patch by Jelle
Zijlstra.
Speedup issubclass() checks against simple runtime-checkable protocols by
around 6% (backporting python/cpython#112717, by Alex
Waygood).
Fix a regression in the implementation of protocols where typing.Protocol
classes that were not marked as @runtime_checkable would be unnecessarily
introspected, potentially causing exceptions to be raised if the protocol had
problematic members. Patch by Alex Waygood, backporting
python/cpython#113401.
This feature release adds support for PEP 728 (TypedDict with extra
items) and PEP 742 (TypeIs).
There are no changes since 4.10.0rc1.
Release 4.10.0rc1 (February 17, 2024)
Add support for PEP 728, supporting the closed keyword argument and the
special __extra_items__ key for TypedDict. Patch by Zixuan James Li.
Add support for PEP 742, adding typing_extensions.TypeIs. Patch
by Jelle Zijlstra.
Drop runtime error when a read-only TypedDict item overrides a mutable
one. Type checkers should still flag this as an error. Patch by Jelle
Zijlstra.
Speedup issubclass() checks against simple runtime-checkable protocols by
around 6% (backporting python/cpython#112717, by Alex
Waygood).
Fix a regression in the implementation of protocols where typing.Protocol
classes that were not marked as @runtime_checkable would be unnecessarily
introspected, potentially causing exceptions to be raised if the protocol had
problematic members. Patch by Alex Waygood, backporting
python/cpython#113401.
✨ Add typer-slim package without extras, make typer include typer-slim[default] and integrate Typer CLI (typer command) into Typer. PR #780 by @tiangolo.
Internal
🔧 Temporarily disable social plugin while a MkDocs issue is handled. PR #779 by @tiangolo.
👷 Fix install MkDocs Insiders only when available. PR #778 by @tiangolo.
0.11.1
Fixes
🔧 Explicitly include testing files in sdist for redistributors (e.g. OpenSUSE) and add CI to test redistribution. PR #773 by @tiangolo.
Internal
👷 Do not use the cache for dependencies when publishing to PyPI. PR #774 by @tiangolo.
0.11.0
Breaking Changes
🔧 Refactor package manager, move from Flit to PDM, remove private pip extras for test, doc, dev. PR #764 by @tiangolo.
🔥 Remove support for Click 7, require Click 8+. PR #760 by @tiangolo.
✨ Add typer-slim package without extras, make typer include typer-slim[default] and integrate Typer CLI (typer command) into Typer. PR #780 by @tiangolo.
Internal
🔧 Temporarily disable social plugin while a MkDocs issue is handled. PR #779 by @tiangolo.
👷 Fix install MkDocs Insiders only when available. PR #778 by @tiangolo.
0.11.1
Fixes
🔧 Explicitly include testing files in sdist for redistributors (e.g. OpenSUSE) and add CI to test redistribution. PR #773 by @tiangolo.
Internal
👷 Do not use the cache for dependencies when publishing to PyPI. PR #774 by @tiangolo.
0.11.0
Breaking Changes
🔧 Refactor package manager, move from Flit to PDM, remove private pip extras for test, doc, dev. PR #764 by @tiangolo.
🔥 Remove support for Click 7, require Click 8+. PR #760 by @tiangolo.
🐛 Fix unhandled growing memory for internal server errors, refactor dependencies with yield and except to require raising again as in regular Python. PR #11191 by @tiangolo.
This is a breaking change (and only slightly) if you used dependencies with yield, used except in those dependencies, and didn't raise again.
This was reported internally by @rushilsrivastava as a memory leak when the server had unhandled exceptions that would produce internal server errors, the memory allocated before that point would not be released.
Explicitly use encoding="locale" for .pth files whenever possible,
to reduce EncodingWarnings.
This avoid errors with UTF-8 (see discussion in python/cpython#77102). (#4265)
Bugfixes
Clarify some pkg_resources methods return bytes, not str. Also return an empty bytes in EmptyProvider._get -- by :user:Avasam (#4243)
Return an empty list by default in pkg_resources.ResourceManager.cleanup_resources -- by :user:Avasam (#4244)
Made pkg_resoursces.NullProvider's has_metadata and metadata_isdir methods return actual booleans like all other Providers. -- by :user:Avasam (#4254)
This release is not a usual bug fix release -- it contains features and improvements, being a follow up
to 8.1.0, which has been yanked from PyPI.
:::
Features
#11475: Added the new consider_namespace_packages{.interpreted-text role="confval"} configuration option, defaulting to False.
If set to True, pytest will attempt to identify modules that are part of namespace packages when importing modules.
#11653: Added the new verbosity_test_cases{.interpreted-text role="confval"} configuration option for fine-grained control of test execution verbosity.
See Fine-grained verbosity <pytest.fine_grained_verbosity>{.interpreted-text role="ref"} for more details.
Improvements
#10865: pytest.warns{.interpreted-text role="func"} now validates that warnings.warn{.interpreted-text role="func"} was called with a [str]{.title-ref} or a [Warning]{.title-ref}.
Currently in Python it is possible to use other types, however this causes an exception when warnings.filterwarnings{.interpreted-text role="func"} is used to filter those warnings (see [CPython #103577](python/cpython#103577) for a discussion).
While this can be considered a bug in CPython, we decided to put guards in pytest as the error message produced without this check in place is confusing.
#11311: When using --override-ini for paths in invocations without a configuration file defined, the current working directory is used
as the relative directory.
Previoulsy this would raise an AssertionError{.interpreted-text role="class"}.
#11475: --import-mode=importlib <import-mode-importlib>{.interpreted-text role="ref"} now tries to import modules using the standard import mechanism (but still without changing :pysys.path{.interpreted-text role="data"}), falling back to importing modules directly only if that fails.
This means that installed packages will be imported under their canonical name if possible first, for example app.core.models, instead of having the module name always be derived from their path (for example .env310.lib.site_packages.app.core.models).
#11801: Added the iter_parents() <_pytest.nodes.Node.iter_parents>{.interpreted-text role="func"} helper method on nodes.
It is similar to listchain <_pytest.nodes.Node.listchain>{.interpreted-text role="func"}, but goes from bottom to top, and returns an iterator, not a list.
#11850: Added support for sys.last_exc{.interpreted-text role="data"} for post-mortem debugging on Python>=3.12.
#11962: In case no other suitable candidates for configuration file are found, a pyproject.toml (even without a [tool.pytest.ini_options] table) will be considered as the configuration file and define the rootdir.
#11978: Add --log-file-mode option to the logging plugin, enabling appending to log-files. This option accepts either "w" or "a" and defaults to "w".
Previously, the mode was hard-coded to be "w" which truncates the file before logging.
Fix: in some cases, even with [run] relative_files=True, a data file
could be created with absolute path names. When combined with other relative
data files, it was random whether the absolute file names would be made
relative or not. If they weren't, then a file would be listed twice in
reports, as detailed in issue 1752_. This is now fixed: absolute file
names are always made relative when combining. Thanks to Bruno Rodrigues dos
Santos for support.
Fix: the last case of a match/case statement had an incorrect message if the
branch was missed. It said the pattern never matched, when actually the
branch is missed if the last case always matched.
Fix: clicking a line number in the HTML report now positions more accurately.
Fix: the report:format setting was defined as a boolean, but should be a
string. Thanks, Tanaydin Sirin <pull 1754_>_. It is also now documented
on the :ref:configuration page <config_report_format>.
Fix: setting COVERAGE_CORE=sysmon no longer errors on 3.11 and lower,
thanks Hugo van Kemenade <pull 1747_>_. It now issues a warning that
sys.monitoring is not available and falls back to the default core instead.
This is a fix release for the 2.1.x feature release branch. It fixes bugs but does not otherwise change behavior and should not result in breaking changes.
Fixes a regression in striptags behavior from 2.14. Spaces are now collapsed correctly.
Bumps the dependencies group with 17 updates:
4.9.0
4.10.0
0.9.0
0.12.0
13.7.0
13.7.1
0.27.0
0.29.0
0.109.0
0.110.0
69.0.3
69.2.0
8.0.0
8.1.1
7.4.1
7.4.4
0.26.0
0.27.0
0.7.13
0.7.16
2.1.4
2.1.5
1.0.4
1.0.8
1.0.2
1.0.6
2.0.1
2.0.5
1.0.3
1.0.7
1.1.5
1.1.10
2.1.0
2.2.1
Updates
typing-extensions
from 4.9.0 to 4.10.0Release notes
Sourced from typing-extensions's releases.
Changelog
Sourced from typing-extensions's changelog.
Commits
ed81f2b
Prepare release 4.10.0 (#343)06b23e3
Release 4.10.0rc1 (#340)b7bf949
Add support for PEP 728 (#329)9f040ab
Fix changelog entry and mutable_keys tracking for PEP 705 (#334)566e01e
Add support for TypeIs (PEP 742) (#330)d6c50f5
Drop runtime error in PEP 705 implementation (#333)ff530f5
Update GitHub Actions versions (#332)05ffab5
Catch a deprecation warning on Python 3.13 (#331)69b48c3
Fix display of TypedDict.readonly_keys (#328)004b893
Backport recent improvements to the implementation ofProtocol
(#324)Updates
typer
from 0.9.0 to 0.12.0Release notes
Sourced from typer's releases.
... (truncated)
Changelog
Sourced from typer's changelog.
... (truncated)
Commits
ef9beaf
🔖 Release version 0.12.08b02247
📝 Update release notes7d5d6bb
✨ Addtyper-slim
package without extras, maketyper
include `typer-slim[d...62988df
📝 Update release notes2ab3c26
🔧 Temporarily disable social plugin while a MkDocs issue is handled (#779)db27196
📝 Update release notes19efa77
👷 Fix install MkDocs Insiders only when available (#778)73efcb3
🔖 Release version 0.11.1f858db6
📝 Update release notes4b60ed6
👷 Do not use the cache for dependencies when publishing to PyPI (#774)Updates
rich
from 13.7.0 to 13.7.1Release notes
Sourced from rich's releases.
Changelog
Sourced from rich's changelog.
Commits
7f580bd
Merge pull request #3293 from Textualize/bump1371705bc46
bumpf4a7ed3
Merge pull request #3289 from Textualize/update-wcwidth18ebb42
Update wcwidth and cell widths.26152e9
Export TextType into the docs. (#3257)Updates
uvicorn
from 0.27.0 to 0.29.0Release notes
Sourced from uvicorn's releases.
Changelog
Sourced from uvicorn's changelog.
Commits
fe85206
Version 0.29.0 (#2279)9e32e8e
Cooperative signal handling (#1600)f73b8be
Version 0.28.1 (#2277)76a3812
Revert raiseClientDisconnected
on HTTP (#2276) (#2276)a05ae64
Version 0.28.0 (#2269)4a503d8
Change ruff rules (#2251)0d4747e
UseX-Forwarded-Proto
for WebSockets scheme when the proxy provides it (#2258)93897b5
ExceptAttributeError
onsys.stdin.fileno()
for Windows IIS10 (#1947)ed2d655
Bump cryptography from 42.0.2 to 42.0.4 (#2253)1e5f1be
RaiseClientDisconnected
onsend()
when client disconnected (#2220)Updates
fastapi
from 0.109.0 to 0.110.0Release notes
Sourced from fastapi's releases.
... (truncated)
Commits
e40747f
🔖 Release version 0.110.032b56a8
📝 Update release notesb6b0f2a
📝 Update release notesbf771bd
🐛 Fix unhandled growing memory for internal server errors, refactor dependenc...6336604
📝 Update release notescb93874
📝 Update release notes9210e6a
🌐 Add German translation fordocs/de/docs/reference/background.md
(#10820)dec45c5
🌐 Add German translation fordocs/de/docs/reference/templating.md
(#10842)5da35ff
📝 Update release notes626b066
🌐 Add German translation fordocs/de/docs/external-links.md
(#10852)Updates
setuptools
from 69.0.3 to 69.2.0Changelog
Sourced from setuptools's changelog.
... (truncated)
Commits
6ee23bf
Bump version: 69.1.1 → 69.2.035df7d0
Update upload-artefact action to v3 (#4274)50f0459
Update .github/workflows/ci-sage.ymlc9e6b2a
Update upload-artefact action to v49156fc0
Update cygwin-install-action to v4 (#4269)e0cb8e8
Update cygwin-install-action0badbf5
Update checkout action to v4 (#4272)fe64b70
Update setup-python action to v5 (#4271)b40a70b
Merge branch 'main' into update-setup-python-actionc3dc91e
CI: Update cache action to v4 (#4275)Updates
pytest
from 8.0.0 to 8.1.1Release notes
Sourced from pytest's releases.
... (truncated)
Commits
81653ee
Adjust changelog manually for 8.1.1e60b4b9
Prepare release version 8.1.115fbe57
[8.1.x] Revert legacy path removals (#12093)86c3aab
[8.1.x] Do not import duplicated modules with --importmode=importlib (#12077)5b82b0c
[8.1.x] Yank version 8.1.0 (#12076)0a53681
Merge pull request #12054 from pytest-dev/release-8.1.0b9a167f
Prepare release version 8.1.000043f7
Merge pull request #12038 from bluetech/fixtures-rm-arg2indexf4e1025
Merge pull request #12048 from bluetech/fixture-teardown-excgroup43492f5
Merge pull request #12051 from jakkdl/test_debugging_pythonbreakpointUpdates
coverage
from 7.4.1 to 7.4.4Changelog
Sourced from coverage's changelog.
Commits
bc5e2d7
docs: sample HTML for 7.4.49b0008b
docs: prep for 7.4.4a536161
docs: thanks, Bruno Rodrigues dos Santose06e4f9
chore: make doc_upgradef30818e
chore: make upgrade1b19799
fix: ensure absolute paths are relative when combined #17521ef020d
build: more cheats for convenient URLs3d57a07
docs: document the report:format setting8e30221
fix: correct the type of report:format in config.py (#1754)6289be8
refactor: use dataclasses, no namedtupleUpdates
httpx
from 0.26.0 to 0.27.0Release notes
Sourced from httpx's releases.
Changelog
Sourced from httpx's changelog.
Commits
326b943
Version 0.27.0 (#3095)3faa4a8
Improve 'Custom transports' docs (#3081)c51af4b
Extensions docs (#3080)cabd1c0
Deprecateapp=...
in favor of explicitWSGITransport
/ASGITransport
. (#3...6f46152
Bump the python-packages group with 6 updates (#3077)37a2901
Mention NO_PROXY environment variable on Advanced Usage page (#3066)371b6e9
Use__future__.annotations
(#3068)4f6edf3
testparse_header_links
via public api (#3061)c7cd6aa
testobfuscate_sensitive_headers
via public api (#3063)15f9253
Drop outdated section (#3057)Updates
alabaster
from 0.7.13 to 0.7.16Release notes
Sourced from alabaster's releases.
Changelog
Sourced from alabaster's changelog.
Commits
f3fdc04
Bump to 0.7.1639cbbc1
Do not display logo_name == 'false'd24c4cb
Bump to 0.7.1556f12de
Include documentation in the sdist2d8d038
Adorn the LICENSE file with a suffixa31816c
Remove obscenities (#173)166d6e7
Replace © with unicode decimal code entity (#161)b9e8d79
Deprecate canonical_url in favor of html_baseurl (#178)848e718
Allow an arbitrary string in the logo_name option (#213)6922a16
Improve sidebar stylesUpdates
markupsafe
from 2.1.4 to 2.1.5Release notes
Sourced from markupsafe's releases.
Changelog
Sourced from markupsafe's changelog.
Commits
fbba4ac
release version 2.1.5c5fa23b
update publish actions60a6512
striptags collapses spaces correctly (#418)0b6bee0
collapse spaces after stripping tags73e6a48
start version 2.1.5d704bf4
use pip-compile, dependabot updates (#419)1f82932
use pip-compile, dependabot updates25a640f
release version 2.1.4 (#414)Updates
sphinxcontrib-applehelp
from 1.0.4 to 1.0.8Release notes
Sourced from sphinxcontrib-applehelp's releases.
Changelog
Sourced from sphinxcontrib-a... _Description has been truncated_