This release was yanked from PyPI due to a partial wheel publishing problem.
Bug fixes
-
Delayed importing pydantic until it's needed to avoid increased import time -- by :user:
Dreamsorcerer. -
Fixed pickling of :class:
~yarl.URLon Python 3.15, whereSplitResult
gained a__getstate__that requires attributes set by__init__.
__getstate__now returns the raw 5-tuple instead of aSplitResult
built viatuple.__new__, so pickling no longer touchesSplitResult
serialization at all. Pickles produced by older yarl releases (which embed
aSplitResult) continue to load unchanged
-- by :user:befeleme.Related issues and pull requests on GitHub:
#1632, #1642, #1687. -
Fixed a parsing issue where URLs containing text before an opening bracket
in the host component (e.g.http://127.0.0.1[aa::ff]) were silently accepted
instead of being rejected as strictly invalid per RFC 3986
-- by :user:rodrigobnogueira.Related issues and pull requests on GitHub:
#1654. -
Raise :exc:
ValueErrorwhen a URL's authority component contains a
backslash, which is not a valid character per :rfc:3986
-- by :user:rodrigobnogueira.Related issues and pull requests on GitHub:
#1659. -
Fixed a host-confusion parsing bug where URLs containing multiple bracket
characters in the host component (e.g.http://[:localhost[]].google:80)
were silently parsed as an unintended host. Bothsplit_url()and
split_netloc()now raise :exc:ValueErrorwhen more than one[or
]is found in the authority, or when[does not appear at the start of
the host subcomponent, in compliance with :rfc:3986-- by
:user:rodrigobnogueira.Related issues and pull requests on GitHub:
#1661. -
Fixed a parser/serializer inconsistency where percent-encoded characters in
the scheme portion of a URL (e.g.ht%74p://...) were decoded by the
requoter, causingstr()and :py:meth:~yarl.URL.human_reprto emit an
absolute URL with a scheme and host while the parsed properties
(:attr:~yarl.URL.scheme, :attr:~yarl.URL.host, :attr:~yarl.URL.absolute)
reported a relative, hostless URL. The fix preserves the percent-encoding of
the colon (%3A) in relative paths whenever decoding it would materialize a
URL scheme -- by :user:rodrigobnogueira.Related issues and pull requests on GitHub:
#1669. -
Fixed a parsing issue where URLs containing text after the closing bracket
of an IP-literal host (e.g.http://[::1]allowed.example:1/) were silently
accepted and normalized to the bracketed IP address (http://[::1]:1/),
dropping the trailing suffix and changing the effective host identity.
Per RFC 3986, after the closing]only:followed by a port number or
end-of-authority is valid
-- by :user:rodrigobnogueira.Related issues and pull requests on GitHub:
#1672.
Features
-
Start building and shipping riscv64 wheels
-- by :user:justeph.Related issues and pull requests on GitHub:
#1626.
Removals and backward incompatible breaking changes
-
Dropped support for the experimental free-threaded build of Python 3.13 -- by :user:
ngoldbaum.Related issues and pull requests on GitHub:
#1667.
Improved documentation
-
Added a note in the :meth:
~yarl.URL.with_querydocumentation explaining
that types implementing__int__(e.g. :class:~uuid.UUID) are
converted to integers, and advising users to cast to :class:strwhen the
human-readable representation is needed -- by :user:r266-tech.
Contributor-facing changes
-
Resolved a ruff
ISC004violation in the PEP 517 build backend so the
pre-commitruff-checkhook passes again
-- by :user:bdraco.Related issues and pull requests on GitHub:
#1674. -
Renamed the
actions/checkoutdepthinput tofetch-depthin the
reusable codspeed workflow so the actionlint pre-commit hook passes and the
intended shallow clone actually takes effect
-- by :user:bdraco.Related issues and pull requests on GitHub:
#1676. -
Bumped the pinned
pyupgradepre-commit hook tov3.21.2so it stops
crashing on Python 3.14, which madetokenize.cookie_rebytes-only
-- by :user:bdraco.Related issues and pull requests on GitHub:
#1677. -
The type preciseness coverage report generated by
MyPy <https://mypy-lang.org>__ is now uploaded toCoveralls <https://coveralls.io/github/aio-libs/yarl>__ and
will not be included in theCodecov views <https://app.codecov.io/gh/aio-libs/yarl>__ going forward
-- by :user:webknjaz.Related issues and pull requests on GitHub:
#1680. -
Raised the per-matrix-cell timeout of the CI
Testjob from
5 to 10 minutes to prevent false failures on slower runners
-- by :user:aiolibsbot.Related issues and pull requests on GitHub:
#1683. -
Added an
AGENTS.mdorientation file at the repository root,
covering the pull request template,CHANGES/news fragment
conventions, draft-PR workflow, and the Cython quoter layout, so
LLM contributors land changes that match project style
-- by :user:bdraco.Related issues and pull requests on GitHub:
#1685. -
Documented in :file:
AGENTS.mdthat the coverage gate also
applies to test code, so unreachable defensiveraiseguards
and one-sided cleanup branches in tests will fail CI
-- by :user:bdraco.Related issues and pull requests on GitHub:
#1689. -
Shrunk the CI wheel-build matrix on pull requests and non-tag pushes by
restrictingCIBW_ARCHS_MACOStoarm64,CIBW_ARCHS_WINDOWSto
AMD64, and skipping thewindows-11-armrunner -- the test matrix only
exercises those architectures, so the previously-builtx86_64macOS and
ARM64Windows wheels were never installed. Tag releases still build the
full architecture set
-- by :user:aiolibsbot.Related issues and pull requests on GitHub:
#1692. -
Documented the docs spell check (
make doc-spelling) in
:file:AGENTS.mdas a pre-push gate, mirroring
aio-libs/multidict#1345 <https://github.com/aio-libs/multidict/pull/1345>__. The
spell checker reads everyCHANGES/*.rstfragment as part
of the docs build, so an unknown technical word in a news
fragment fails CI before a human sees the PR
-- by :user:bdraco.Related issues and pull requests on GitHub:
#1693. -
Added a
CLAUDE.mdat the repository root that imports
:file:AGENTS.mdvia Claude Code's@-syntax, so the
project's LLM contributor rules load automatically when
working in Claude Code
-- by :user:bdraco.Related issues and pull requests on GitHub:
#1696. -
Enforced top-level imports across
yarlandtestsvia the ruff
PLC0415rule, wired through a newruff-checkpre-commit hook.
Function-scoped imports must now opt in with# noqa: PLC0415plus
a comment explaining the import-time reason. Dropped theyesqa
hook, which could not recognize ruff-only codes and stripped the new
noqacomments as stale; a wider migration off flake8 onto ruff
will follow separately
-- by :user:bdraco.Related issues and pull requests on GitHub:
#1697. -
Migrated the main tree from standalone
blackandisort
pre-commit hooks toruff formatand the ruffIlint rule,
sharing the existing[tool.ruff]config inpyproject.toml.
ruff-checknow runs with--fixso import-order fixes apply
on commit, and the orphan[isort]block insetup.cfgwas
removed. Thepackaging/pep517_backend/subtree keeps its own
.ruff.tomland is unaffected
-- by :user:bdraco.Related issues and pull requests on GitHub:
#1698. -
Switched the
cibuildwheelbuild frontend tobuild[uv]so
thatuvprovisions every build and test virtual environment
in the wheel matrix. Test-dependency installation in particular
drops from a multi-secondpip installper ABI to a roughly
sub-seconduvresolve
-- by :user:bdraco.Related issues and pull requests on GitHub:
#1699. -
Restructured the root :file:
CLAUDE.mdto import contributor
context from a sharedaio-libslayer
(~/.claude/aio-libs/context.md), a project-specific layer
(~/.claude/aio-libs/yarl/context.md), the in-tree
:file:AGENTS.md, and an optional per-checkout
:file:CLAUDE.local.mdoverride (added to :file:.gitignore),
so sharedaio-libsguidance can live outside the repository
while project rules continue to load automatically in Claude
Code -- by :user:aiolibsbot. -
Switched CI/CD to
tox-dev/workflow's :file:reusable-tox.yml
driven by an in-tree :file:tox.ini. Thebuild,
metadata-validationandlint(pre-commit,
spellcheck-docs,build-docs) jobs all run through the
reusable workflow; MyPy coverage uploads to Coveralls from a
post-tox-jobhook
-- by :user:bdraco.Related issues and pull requests on GitHub:
#1711. -
Switched the CI
testjob fromactions/setup-pythonto
astral-sh/setup-uvwithuv pip install. Pre-release
interpreters skip the wheel cache so each run resolves freshly
against the current snapshot
-- by :user:bdraco.Related issues and pull requests on GitHub:
#1715. -
Switched the
Aiohttpworkflow that runs the aiohttp test
suite against the in-tree yarl checkout from
actions/setup-pythontoastral-sh/setup-uvwithuv pip install
-- by :user:bdraco.Related issues and pull requests on GitHub:
#1716. -
Switched the
Aiohttpworkflow'smake .developstep to
install aiohttp's dev env throughuv pipby passing
PIP="uv pip"
-- by :user:bdraco.Related issues and pull requests on GitHub:
#1717.