release: v0.1.2 polish + docs reconciliation#12
Merged
Conversation
Drop unreachable cgnat_on_blocked case from TestDecideForecast_Precedence (applyCGNAT runs only when classifyMapping produces Unknown or a multi-success type, so Type=Blocked,CGNAT=true is unreachable from the pipeline). Replace with a reachable EIM+CGNAT+ADF case that locks in CGNAT precedence over restrictive filtering. Add TestClassify integration row for EIM+CGNAT+endpoint-independent filtering: the CGNAT honesty rule must override even the most favourable filtering outcome. Add wantWarnAbsent assertions to nil_filtering, test1_failed, and rfc_impossible_t2_true_t3_false rows in TestClassify_FilteringMatrix so the warning vocabulary contract (filtering_behavior_not_tested vs filtering_skipped_no_change_request) cannot leak across cases.
stunserver.Handle Unmaps before encoding, so the existing TestProbe_OtherAddressExtracted only exercises v4-family input on the probe side. Add a hand-crafted responder that emits OTHER-ADDRESS as v6-family carrying ::ffff:198.51.100.1 and assert Result.Other.Addr() comes back as Is4() with string "198.51.100.1:3479".
…ue cases Existing godoc listed two zero-value paths (filtering not attempted, server did not advertise OTHER-ADDRESS). applyFiltering also leaves the field zero for ErrTest1Failed and the (T2=true, T3=false) RFC-impossible state. Document all four so consumers know zero-value is the only signal for "no §4.4 sequence ran successfully", regardless of cause.
README, site/index.md, site/nat-types.md previously claimed filtering classification was out of scope and showed example output with the "(v0.1)" suffix that no longer matches the binary. Update example output to current human renderer; revise §Scope to describe filtering as capability-driven; mention the coturn setup recipe; add the new "filtering" key to the JSON-contract list. design.md: mark v0.1.2 as shipped in the v0.2 staged-sequence table and update the document status header. v0.1.3 (hairpinning) and v0.1.4 (natcheck server) remain planned. CHANGELOG: promote [Unreleased] to [0.1.2] with date 2026-04-26, add a fresh empty [Unreleased], update the link refs at the bottom.
Contributor
Author
Code reviewFound 1 issue:
natcheck/internal/classify/classify_test.go Lines 40 to 44 in e1764c8 Two additional findings scored just below the post-threshold and are flagged here without being attached as blocking — |
- Drop dead struct field wantNotTestedWarn from TestClassify case struct (added in b24c651 but never set or read; the intended check was inlined as `if tc.filtering == nil && !hasWarning(...)`). - Strip "Hairpinning detection is planned for v0.1.3." from README §Scope. Public-surface lean rule forbids version-target parentheticals; describe hairpinning as out of scope instead. - Strip "v0.1.3 (hairpinning) and v0.1.4 (`natcheck server`) remain planned." from docs/design.md status header. Same rule. The v0.2 staged-sequence table inside the addendum still carries the planned state for those patches.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Final pre-tag pass for v0.1.2. Folds the four sub-80 polish items from PR #10's
/code-reviewpass and reconciles the public surface (README, site, design.md, CHANGELOG) so the docs match the binary at the moment of tag.Polish (PR #10 carry-over)
test(classify): tighten precedence and matrix coverage— drops unreachablecgnat_on_blockedcase fromTestDecideForecast_Precedence(applyCGNAT runs only when classifyMapping produces Unknown or a multi-success type, so Type=Blocked,CGNAT=true is unreachable). Adds reachable EIM+CGNAT+filtering integration row inTestClassify. AddswantWarnAbsentto nil_filtering, test1_failed, and rfc_impossible_t2_true_t3_false rows inTestClassify_FilteringMatrixso the warning vocabulary contract cannot leak across cases.test(probe): cover OTHER-ADDRESS Unmap for IPv4-mapped IPv6— stunserver.Handle Unmaps before encoding, so the existingTestProbe_OtherAddressExtractedonly exercised v4-family input on the probe side. New test hand-crafts a response withOTHER-ADDRESSas v6-family carrying::ffff:198.51.100.1and assertsResult.Othersurfaces asIs4()with string"198.51.100.1:3479".docs(classify): enumerate all Verdict.FilteringTestedAgainst zero-value cases— godoc previously listed two zero-value paths;applyFilteringactually leaves the field zero in four cases (filtering not attempted, ErrFilteringNotSupported, ErrTest1Failed, RFC-impossible T2=true/T3=false). Public-surface accuracy.Docs reconciliation
(v0.1)suffix; §Scope rewritten to describe filtering as capability-driven rather than out-of-scope; JSON-contract list adds the newfilteringkey; pointer todocs/coturn-setup.mdadded.[Unreleased]to[0.1.2]with date 2026-04-26, adds fresh empty[Unreleased], updates link refs.Test plan
make test(race, count=1)make lint(0 issues)gofmt -l .cleango mod tidy -diffcleangovulncheck ./...no vulnerabilitiesgh release create v0.1.2 --notes-from-tagdocs/samples/filtering.txt(separate commit on main)