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

go-playground / validator / 45500535864
73%
v8: 100%

Build:
Build:
LAST BUILD BRANCH: fix-cyclic-alias-panic
DEFAULT BRANCH: v8
Ran 24 Nov 2026 10:24PM UTC
Jobs 1
Files 37
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

24 Nov 2026 10:23PM UTC coverage: 72.668% (+0.02%) from 72.649%
45500535864

push

github

web-flow
fix: support BIP-350 Bech32m checksums and padding in btc_addr_bech32 (#1697)

## Fixes Or Enhances

Updates `isBitcoinBech32Address` (`btc_addr_bech32`) to comply with
BIP-350 (Bech32m) and BIP-173 padding rules:

- Use the BIP-173 Bech32 checksum constant (`1`) for witness version 0
and the BIP-350 Bech32m checksum constant (`0x2bc830a3`) for witness
versions 1–16 (including SegWit v1 Taproot `bc1p...` addresses).
- Validate 5-to-8-bit conversion padding per BIP-173 / BIP-350
(`convertbits` with `pad=false`) by rejecting non-zero padding bits, and
mask the bit accumulator to avoid overflow.
- Replace the unused `[]int` witness-program slice accumulation with a
byte counter to avoid an unnecessary allocation.
- Update the pre-BIP-350 witness v1/v2/v16 test vectors in
`TestBitcoinBech32AddressValidation` and add official BIP-350
valid/invalid Taproot vectors plus non-zero padding tests.
- Update `README.md` and `doc.go` to reflect Bech32m / Taproot support.

> **AI Disclosure**: This pull request was AI-assisted (implemented with
Gemini).

**Make sure that you've checked the boxes below before you submit PR:**
- [x] Tests exist or have been written that cover this particular
change.

@go-playground/validator-maintainers

Co-authored-by: Gemini <noreply@google.com>

21 of 21 new or added lines in 1 file covered. (100.0%)

15673 of 21568 relevant lines covered (72.67%)

90.46 hits per line

Jobs
ID Job ID Ran Files Coverage
1 45500535864.1 24 Nov 2026 10:24PM UTC 37
72.67
GitHub Action Run
Source Files on build 45500535864
  • Tree
  • List 37
  • Changed 1
  • Source Changed 0
  • Coverage Changed 1
Coverage ∆ File Lines Relevant Covered Missed Hits/Line
  • Back to Repo
  • 5e29d8d3 on github
  • Prev Build on master (#44644256455)
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