• Home
  • Features
  • Pricing
  • Docs
  • Announcements
  • Sign In

aio-libs / yarl / 36881578467
98%

Build:
DEFAULT BRANCH: master
Ran 01 Oct 2026 03:08PM UTC
Jobs 1
Files 48
Run time 1min
Badge
Embed ▾
README BADGES
x

If you need to use a raster PNG badge, change the '.svg' to '.png' in the link

Markdown

Textile

RDoc

HTML

Rst

01 Oct 2026 03:05PM UTC coverage: 97.752% (+0.01%) from 97.741%
36881578467

push

github

web-flow
Accept IPv6 zone identifiers only in the RFC 6874 form (#1957)

<!-- Thank you for your contribution! -->

## What do these changes do?

Accepts IPv6 zone identifiers only in the RFC 6874 form, `%25` followed
by the percent-encoded zone identifier, in both modes. Parsing (with
`encoded=False` and `encoded=True`) and `URL.build(authority=...)` now
reject a bare `%` such as `http://[fe80::1%eth0]/` and a zone that
starts with another percent-encoded octet, such as `http://[::%31]/`,
which RFC 3986 and WHATWG both reject. An empty zone (`[fe80::1%25]`) is
still accepted when parsing (#998).

`URL.build(host=...)` and `with_host()` still take the zone identifier
after a bare `%`, as `socket` and `ipaddress` write it, and now
percent-encode it behind `%25`: `with_host("fe80::1%eth0")` gives
`http://[fe80::1%25eth0]/`. Characters such as `/` or non-ASCII in the
zone, which used to produce a URL that yarl could not parse back, are
now percent-encoded; octets that are already percent-encoded are kept.
`.host` decodes the zone identifier except for `%`, authority delimiters
and octets that are not UTF-8, so `with_host(url.host)` and
`URL.build(host=url.host)` give the same URL back. `human_repr()` keeps
the zone identifier percent-encoded (`http://[fe80::1%25eth0]/`), since
the parser no longer accepts a bare `%`.

In the conformance report, `http://[::%31]` moves to "RFC 3986+3987,
WHATWG and yarl in both modes agree" (462 to 463), and the "yarl
differs, RFC 3986+3987 and WHATWG agree" section is now empty. No other
rows move.

## Are there changes in behavior for the user?

Yes. URLs with a bare `%` zone separator, or a zone that is not `%25`
followed by unreserved characters and percent-encoded octets, now raise
`ValueError`. Built URLs spell the separator `%25` instead of keeping a
bare `%`, and so does `human_repr()`. `.host` keeps a `%25` inside the
zone encoded: `[fe80::1%25a%25b]` gives `fe80::1%a%25b` (previously
`fe80::1%a%b`).

## Is it a substantia... (continued)

97 of 194 branches covered (50.0%)

Branch coverage included in aggregate %.

106 of 106 new or added lines in 8 files covered. (100.0%)

9817 of 9948 relevant lines covered (98.68%)

0.99 hits per line

Jobs
ID Job ID Ran Files Coverage
1 MyPy - 36881578467.1 01 Oct 2026 03:08PM UTC 48
97.75
GitHub Action Run
Source Files on build 36881578467
  • Tree
  • List 48
  • Changed 8
  • Source Changed 8
  • Coverage Changed 8
Coverage ∆ File Lines Relevant Covered Missed Hits/Line Branch Hits Branch Misses
  • Back to Repo
  • Github Actions Build #36881578467
  • 5f916ec4 on github
  • Prev Build on master (#36879979364)
  • Next Build on master (#36882483374)
  • Delete
STATUS · Troubleshooting · Open an Issue · Sales · Support · CAREERS · ENTERPRISE · START FREE TRIAL · SCHEDULE DEMO
ANNOUNCEMENTS · TWITTER · TOS & SLA · Supported CI Services · What's a CI service? · Automated Testing

© 2026 Coveralls, Inc