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

dunglas / go-urlpattern
93%
main: 92%

Build:
Build:
LAST BUILD BRANCH: fuzz-oss-fuzz-compat
DEFAULT BRANCH: main
Repo Added 15 Sep 2024 08:23PM UTC
Token yGjZrxkSLEYRXjo0G6xsg1Sx0WLJ4o8bQ regen
Build 68 Last
Files 6
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

LAST BUILD ON BRANCH fuzz-testing
branch: fuzz-testing
CHANGE BRANCH
x
Reset
Sync Branches
  • fuzz-testing
  • chore/bump-deps
  • chore/lint-fixes
  • chore/upstream-whatwg-url
  • claude/ci-main-fix-e25ogb
  • fix/canonicalize-hash-error
  • fix/process-hash-strip-prefix
  • fix/string-delimiters
  • fix/tokenizer-error-swallow
  • fuzz-oss-fuzz-compat
  • main
  • perf/duplicate-name-map
  • perf/scheme-lookups
  • perf/share-common-component-regexps
  • refs/tags/v1.0.0
  • spec/conformance
  • test/benchmarks

14 Aug 2026 10:32PM UTC coverage: 92.919% (+1.0%) from 91.899%
31847908056

Pull #14

github

dunglas
fix: prevent panic on syntax-only pathname/hostname pattern components

Some canonicalization callbacks (e.g. hostname, opaque-pathname) can
collapse a non-empty component like "#" down to an empty string.
generatePatternString assumed adjacent fixed-text parts always carry
a non-empty value and indexed into their rune slice unconditionally,
panicking on inputs like URLPatternInit{Protocol: "A", Hostname: "#*0"}.

Guard both indexing sites, and make canonicalizeHostname fail instead
of silently returning an empty hostname for a non-empty forbidden-host-
code-point input, matching the URL spec and the existing ':' guard.

Found by the new fuzz targets.
Pull Request #14: Add fuzz testing, fix panics it found

9 of 9 new or added lines in 2 files covered. (100.0%)

1509 of 1624 relevant lines covered (92.92%)

1562.7 hits per line

Relevant lines Covered
Build:
Build:
1624 RELEVANT LINES 1509 COVERED LINES
1562.7 HITS PER LINE
Source Files on fuzz-testing
  • Tree
  • List 6
  • Changed 4
  • Source Changed 0
  • Coverage Changed 4
Coverage ∆ File Lines Relevant Covered Missed Hits/Line

Recent builds

Builds Branch Commit Type Ran Committer Via Coverage
31847908056 fuzz-testing fix: prevent panic on syntax-only pathname/hostname pattern components Some canonicalization callbacks (e.g. hostname, opaque-pathname) can collapse a non-empty component like "#" down to an empty string. generatePatternString assumed adjacent fi... Pull #14 14 Aug 2026 10:46PM UTC dunglas github
92.92
31847016393 fuzz-testing fix: prevent panic on syntax-only pathname/hostname pattern components Some canonicalization callbacks (e.g. hostname, opaque-pathname) can collapse a non-empty component like "#" down to an empty string. generatePatternString assumed adjacent fi... push 14 Aug 2026 10:33PM UTC dunglas github
92.92
See All Builds (57)

Badge your Repo: go-urlpattern

We detected this repo isn’t badged! Grab the embed code to the right, add it to your repo to show off your code coverage, and when the badge is live hit the refresh button to remove this message.

Could not find badge in README.

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

Refresh
  • Settings
  • Repo on GitHub
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