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

aio-libs / yarl / 36439868226
98%

Build:
DEFAULT BRANCH: master
Ran 28 Sep 2026 02:58PM UTC
Jobs 1
Files 41
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

28 Sep 2026 02:57PM UTC coverage: 97.574% (-0.1%) from 97.69%
36439868226

push

github

web-flow
Add per-URL mode selecting RFC 3986 or WHATWG (#1931)

* Add per-URL compat mode selecting RFC 3986 or WHATWG

URL() and URL.build() accept compat="rfc" or compat="whatwg" (the
default), or a member of the new Compatibility enum, and URL.compat
reports it. Derived URLs keep the mode of the URL they come from; join()
uses the base URL's mode. The mode is excluded from equality and hashing
and survives pickling. Both modes behave the same for now; later changes
can make parsing depend on the mode.

* Default compat to None to keep the URL() hot path cheap

Comparing with a module-level enum member costs a global lookup on every
cached URL(str) call; None is a constant. Both URL() and URL.build() treat
None as WHATWG.

* Rename compat to mode and Compatibility to Mode

The argument and property are now URL(..., mode=...) and URL.mode, and
the enum is yarl.Mode. None stays an undocumented internal default for
WHATWG; URL() also matches "whatwg" with == before normalizing, so an
explicit WHATWG argument skips the lookup. Drop the no-op sys.intern.

* Raise ValueError for an unhashable mode

The mode lookup hashes its argument, so a value such as a list raised
TypeError instead of the documented ValueError.

93 of 186 branches covered (50.0%)

Branch coverage included in aggregate %.

241 of 246 new or added lines in 4 files covered. (97.97%)

1 existing line in 1 file now uncovered.

8072 of 8182 relevant lines covered (98.66%)

0.99 hits per line

Uncovered Changes

Lines Coverage ∆ File
4
95.68
tests/test_url_mode.py
1
96.1
-0.29% yarl/_url.py

Coverage Regressions

Lines Coverage ∆ File
1
96.1
-0.29% yarl/_url.py
Jobs
ID Job ID Ran Files Coverage
1 MyPy - 36439868226.1 28 Sep 2026 02:58PM UTC 41
97.57
GitHub Action Run
Source Files on build 36439868226
  • Tree
  • List 41
  • Changed 3
  • Source Changed 3
  • Coverage Changed 3
Coverage ∆ File Lines Relevant Covered Missed Hits/Line Branch Hits Branch Misses
  • Back to Repo
  • Github Actions Build #36439868226
  • 09e500de on github
  • Prev Build on master (#36422942642)
  • Next Build on master (#36453675814)
  • 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