Skip to content

feat(scopes): vendored meshguide scope engine, per-position table and a neutral verdict (#1035 M1) - #1101

Merged
dborup merged 2 commits into
masterfrom
feat/1035-m1-scope-engine
Dec 3, 2026
Merged

dborup merged 2 commits into
masterfrom
feat/1035-m1-scope-engine

Conversation

@adminopenclaw8-sketch

@adminopenclaw8-sketch adminopenclaw8-sketch commented Dec 2, 2026 •

Copy link
Copy Markdown
Collaborator

Relates to #1035

What

#1035 M1, following the M0 plan and the owner decisions of 2026-12-02. This PR adds meshguide.dk's scope rules as a pinned, vendored engine, an offline-generated per-postnummer table, and a pure Go lookup plus a neutral verdict. It has no UI and no API route: M2 adds the node page and M3 the Scope Audit "Location" view.

  • Vendored, unmodified: internal/scopeguide/meshguide/ contains lib/scopes.js, regions.json, postnumre/{index,fyn,sjaelland}.json and the WTFPL LICENSE from github.com/twinoak/meshguide.dk at 9a5d7f5fd210d863067f87581e75eaf562327d71. Its README.md names the commit and the sha256 of each file. .gitattributes marks the directory -text, so the bytes stay hash-exact. No message is sent to meshguide (decision 1).
  • Generator: scripts/gen-scope-guide.mjs is run by hand and its output is checked in. It imports the vendored scopes.js and writes two files:
    • internal/scopeguide/scopeguide-table.json has one row per DAGI postnummer, 605 rows in all. The 484 Copenhagen street postcodes are grouped under 1050 K, 1550 V and 1800 Frb C, exactly like cmd/server/dagi.go (decision 3). Each row carries the postal scopes meshguide recommends there. The header carries the commit, the file hashes, the DAGI asset hash, the scope universe (428) and the firmware cap.
    • internal/scopeguide/testdata/conformance.json holds meshguide's own scopesForPoint() output for 3,918 grid and named points over Denmark.
    • --check fails when the checked-in files differ from a regeneration. The generator also fails if any point would need more than 31 scopes (MAX_REGION_ENTRIES 32, less *).
  • Go package internal/scopeguide: its own module, embedded assets, parsed once.
    • Load() and Recommend(lat, lon, postnummer) Recommendation give the recommended default (dk) and the allow-list in meshguide's order: fixed, then regions, then postal. Each scope carries a Kind.
    • Postnummer(code) is the shared lookup for Home: "Find your area" by postnummer #1039. RegionHits, IsMeshguideScope and ParseList round out the lookup side.
    • Compare(rec, Node) Verdict is pure.
    • Everything uses named structs; there is no map[string]interface{}.

Plan / design choices

  1. Postal scopes only where meshguide has them (decision 4). Fyn and Sjælland 3000–4793 get exactly meshguide's postal answer: 204 rows. Everywhere else (Jylland, Copenhagen, Bornholm, Lolland-Falster), a row has no postal scopes, so a position gets eu, europe, dk and its region hits.
  2. Unclipped DAGI for neighbour geometry (decision 2) is moot under decision 4. meshguide computes neighbour prefixes postnummer to postnummer (scopesFor), so they are exact per row. Adding DAGI geometry would only add DAGI-derived neighbours meshguide.dk does not show. For example, Hillerød would gain dk29, which decision 4 rules out. So the generator reads no DAGI geometry: DAGI supplies only the key space (codes, names, street groups). A test pins that 3400 Hillerød has no dk29.
  3. Region scopes are hit-tested at runtime, not tabulated. meshguide's 40 region polygons overlap and cut across postnumre, so the region answer depends on the exact point. Go does the same ray-cast as scopes.js, operation for operation, behind a bbox prefilter. The conformance golden pins that Go matches the JS engine on all 3,918 points: region hits in order, and the full scope list.
  4. The position's postnummer is the caller's DAGI membership. An empty or unknown code means outside Denmark, which gives no recommendation. Swedish nodes inside se12/oresund therefore get no verdict.
  5. Everything is info (decision 5). The verdict uses neutral categories only.
    • Default scope status: none (no scoped advert, or the firmware's * sentinel), undecoded ("cannot be decoded": a scoped advert whose name this instance does not know, decision 9), recommended (dk), in_list (a scope recommended for this position), other_meshguide (a meshguide scope recommended elsewhere) and not_meshguide.
    • Allow-list: Listed, NotListed (each with its kind: fixed, region or postal), OtherMeshguide, NotMeshguide and Wildcard.
    • Names are compared without # and with exact case (#DK ≠ dk), as the firmware does.
  6. Repeaters and rooms only (decision 8). Other roles get notApplicable: "role".
  7. Not in M1 (left for M2): the store accessor for the newest flood advert's scope and time, and the report-age (stale) handling. Both need the server. M1 keeps the comparison pure and takes DefaultUndecoded and ConfiguredReported as inputs.

Tests

  • test-1035-scope-guide.js (in test-all.sh) checks:
    • the vendored hashes and the commit against the README, the -text attribute, and meshguide's own point fixtures on the vendored engine;
    • that the generator is deterministic (two runs, same bytes) and that --check passes;
    • table spot checks: 5000 Odense C, 3400 Hillerød, 8000 Aarhus C, 3700 Rønne, and the 1051/1473 → 1050 K and 1799 → 1550 V groups;
    • that only Fyn and Sjælland rows carry postal scopes.
  • Go internal/scopeguide:
    • the hash integrity of the embedded regions.json, the spot checks through Recommend, outside Denmark, the Postnummer lookup and street groups, the conformance golden, the universe, ParseList and Load running once;
    • every M0 verdict case: default #dk, a covering local region or postal scope, a neighbour prefix layer, a neighbour postnummer, another region, #dk2100 in Frederiksberg, an unknown name, #DK, none, *, undecoded;
    • lists without dk, without a covering region scope, with postal gaps, with other or unknown names, empty or wildcard;
    • applicability by role and position, and purity.
  • Perf: TestRecommendCompare5kWithinBudget times Recommend + Compare for 5,000 nodes against the M0 20 ms target. The target is logged and only a 100 ms limit fails, outside -race, the same pattern as the share-card renderers.
    • Locally it takes 2.8 ms. The first CI run measured 23 ms on a shared runner, which is why the hard limit sits above the target.
    • Load-independent proof: TestRecommendCompareAllocs caps allocations per call (Recommend ≤ 6, measured 5; Compare ≤ 16, measured 13). TestPostnummerLookupConstantTime asserts that the postnummer lookup costs < 10x a one-entry map lookup in the same process; it measures about 3.5x, while a linear scan would be about 100x.
    • BenchmarkRecommend runs at 275 ns/op. The lookup is one map hit plus a bbox-prefiltered hit test over 40 polygons, so it is O(1) in the node count.
  • Memory: TestGuideMemoryBounded measures the parsed guide at about 215 KB and asserts < 1 MiB. It holds 605 rows, 484 aliases, 40 regions and 428 universe names. The 845 KB of meshguide postnumre are generator-only and never embedded.
  • CI: deploy.yml runs internal/scopeguide (go vet + go test -race) next to internal/regions, and prints the perf, allocation, lookup, memory and conformance lines. The fork guards are unchanged.

Config / customizer (rule 8)

None in M1. The roles checked are hard-coded, as M0 planned. scopeCheck.enabled, scopeCheck.publicList, the report max age and the meshguide link come in M4.

🤖 Generated with Claude Code

dborup and others added 2 commits December 3, 2026 00:26
…nd a neutral verdict (#1035 M1)

Vendor meshguide.dk lib/scopes.js, regions.json and its Fyn/Sjælland
postnumre unmodified at 9a5d7f5 (WTFPL, hashes in README.md). Generate
offline the per-DAGI-postnummer table (postal scopes only where meshguide
has them; street postcodes grouped) plus a conformance golden from the JS
engine. internal/scopeguide: O(1) lookup, region hit test identical to
scopes.js, and a pure, info-only Compare for repeaters and rooms.

Relates to #1035.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
The first CI run measured 23 ms for 5k Recommend+Compare (3.8 ms locally)
against a hard 20 ms. Log the 20 ms target and fail only at 100 ms, like
the share-card renderers, and add load-independent proof: fixed allocs per
call (Recommend <= 6, Compare <= 16) and an O(1) postnummer lookup ratio
against a one-entry map. Compare no longer builds per-node sets.

Relates to #1035.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@adminopenclaw8-sketch

Copy link
Copy Markdown
Collaborator Author

Rapport — CS-Macmini PR#1101 #1035 — head 7d71231

Status: #1035 M1 is complete as a draft. All required CI jobs on 7d712316 are green; the first run on 4b63667e was red because the perf limit was too tight, fixed in 7d712316. 32 mutants: 31 killed, 1 survivor (an equivalent mutant: an output-neutral optimisation).

Evidence tags: [T] test (red before, green after), [A] analysis or a measurement in this report, [K] CI.

Requirements

# Requirement Test Mutant(s)
1 Vendor lib/scopes.js, regions.json and the Fyn/Sjælland postnumre from meshguide.dk 9a5d7f5 unmodified, with the WTFPL licence and a README naming the commit [T] test-1035-scope-guide.js: hashes + commit against the README, -text attribute, meshguide's own point fixtures on the vendored engine. [T] Go TestVendoredFilesMatchTableHashes (disk + embedded regions.json vs the table header) I1 (Go) and I2 (node), a LICENSE byte changed → killed
2 Offline generator (run by hand, output checked in) that is deterministic [T] "two runs write the same bytes" + "--check equals a regeneration" (red before the outputs existed) G3 (clock in the header) → killed; G4 (universe truncated) → killed
3 Postal scopes only where meshguide has them; elsewhere region scopes + dk [T] Aarhus 8000 and Rønne 3700 have no postal scopes; only the 204 Fyn/Sjælland rows carry postal scopes; Hillerød has no DAGI-only dk29 G2 (a DAGI-derived postal scope) → killed; M3 (postal layers dropped) → killed
4 Copenhagen street postcodes grouped [T] node: 1051/1473 → 1050, 1799 → 1550, one København K row. [T] Go TestPostnummerLookup, København K spot check G1 (group keyed by highest code) → killed; M4 (alias ignored) → killed
5 Table spot checks: Fyn, Sjælland, Aarhus, Copenhagen K group, Bornholm [T] node + Go TestRecommendSpotChecks (5000, 4000, 8000, 1051→1050, 3700) M5 (region kind mislabelled) → killed
6 Lookup position → recommended scopes, matching the JS engine [T] TestConformanceWithMeshguideEngine: 3,918/3,918 points equal meshguide's scopesForPoint (region order and full list) M1 (bbox max-x) and M2 (region order) → killed; M6 (ray-cast +xi→-xi) → killed
7 Pure, neutral comparison, info only: default #dk, covering local scope, neighbour postnummer, list without dk, list without a covering region scope [T] TestCompareDefaultScope (14 cases), TestCompareConfiguredList (6), TestComparePure V1, V5, V10, V11 → killed
8 Unknown names give "cannot be decoded" (default) or "not a meshguide scope" (name), and exact case [T] undecoded cases; #dk-kb, #DK, $priv, europa; TestMeshguideScopeUniverse V2, V4 and M8 (case-fold) → killed
9 * sentinel, wildcard list, dedup [T] TestParseList, * default → none V3, V6, V9 → killed
10 Repeaters and rooms only; no verdict outside Denmark (Swedish nodes in se12) [T] TestCompareApplicability, TestRecommendOutsideDenmark V7 (companions compared) and V8 (outside gate) → killed
11 Table loaded once [T] TestLoadOnce M7 → killed
12 Perf: lookup O(1), 5k nodes inside budget [T] TestPostnummerLookupConstantTime (< 10x a one-entry map); TestRecommendCompareAllocs (≤ 6 / ≤ 16 allocs); TestRecommendCompare5kWithinBudget (20 ms target logged, 100 ms limit) P2 (linear scan) and P3 (slice not pre-sized) → killed. P1 (bbox prefilter removed) survives: same output, 6.4 ms vs 3.8 ms locally, inside budget [A]
13 Table memory bounded and measured [T] TestGuideMemoryBounded < 1 MiB – (measured only)
14 Firmware cap (32 regions) [T] generator fails above 31 scopes; conformance asserts ≤ 31 for every point G5 (cap 5) → killed

Measurements [A]/[K]

Local (M-series) CI
5k Recommend+Compare 2.8 ms 6.3 ms [K] (first run: 23.1 ms, against the old hard 20 ms)
Allocs per call Recommend 5, Compare 13 same [K]
Postnummer lookup vs a one-entry map 3.5x 2.0x [K]
Guide heap 215 KB 141 KB [K]
BenchmarkRecommend 275 ns/op –

Local runs [T]

  • cd internal/scopeguide && go test ./... and go test -race ./... pass.
  • cd cmd/server && go test ./... passes (ok … 135.5s).
  • node scripts/run-go-server-shard.js --validate: 4117 entries, each in exactly one shard.
  • sh test-all.sh: 411 passed, 0 failed (including test-1035-scope-guide.js); node test-test-all.js passes 10/10.
  • scripts/check-xss-sinks.sh --diff origin/master: clean (no public/ changes).
  • E2E: not run locally. The PR touches neither public/ nor cmd/server, so no E2E is affected; CI ran all 3 shards.

Invariants [A]

  • cmd/server is unchanged, so it stays read-only. There is no new map[string]interface{}; everything uses named structs.
  • No colours.
  • Fork guards are unchanged: 9 in deploy.yml, 1 in release-fast-path.yml.

CI per job [K]

Run 1, 4b63667e:

  • Go Libraries & CLI: fail. TestRecommendCompare5kWithinBudget took 23.1 ms against a hard 20 ms. Fixed in 7d712316: the target is now logged with a 100 ms limit, plus the load-independent alloc and ratio assertions.
  • Playwright 2/3: fail in test-issue-873-base-deep-link-e2e.js ("config 1500 ms late … osm-standard"). It is unrelated, since there are no frontend changes, and it passed on run 2.
  • The three dependent gate jobs failed as a consequence.

Run 2, 7d712316:

Job Result
Go Build & Test pass
Go Ingestor Tests pass
Go Libraries & CLI pass
Go Server Tests 1/3, 2/3, 3/3 pass
JavaScript Unit Tests & Lint pass
Script & Container Unit Checks pass
Playwright E2E 1/3, 2/3, 3/3 pass
Verify Go Test Assignments pass
Validate Docker Image pass
Build & Publish Docker Image pass
Verify E2E Shards & Coverage pass
Badges, Release, Deploy Staging skipped (PR)

No reruns.

Choices made without an owner answer [A]

  1. Decision 2 vs decision 4. meshguide's neighbour prefixes are per postnummer and exact within its own data. Using DAGI geometry (unclipped or not) for neighbours would only add DAGI-derived postal scopes meshguide.dk does not show (Hillerød would get dk29), and decision 4 forbids that. So the generator reads no DAGI geometry; DAGI supplies only codes, names and street groups.
  2. Region scopes are hit-tested at runtime, not tabulated. meshguide's polygons cut across postnumre, so the answer depends on the point. The table holds only the per-postnummer postal part. A conformance golden pins Go to the JS engine.
  3. Rønne also gets se12 and oresund, because meshguide's polygons reach Bornholm. The golden reproduces it unchanged.
  4. The store accessor for the newest flood advert and the report-age (stale) handling move to M2. Both need the server. M1 takes DefaultUndecoded and ConfiguredReported as inputs and stays pure.
  5. Perf assertion: a logged target with a hard limit, as the share-card renderers do, plus load-independent alloc and ratio checks.

Remaining

  • M2: server wiring (DAGI membership → Recommend, newest-advert accessor, report age), GET /api/nodes/{pk}/scope-check and the node page section.
  • M3: the Scope Audit Location view.
  • M4: drift check + customizer (scopeCheck.*).
  • P1 survivor is an equivalent mutant: an output-neutral optimisation, accepted.
  • conformance.json is 376 KB of testdata; the vendored postnumre (845 KB) are generator-only and never embedded.
  • The vendored scopes.js triggers Node's MODULE_TYPELESS_PACKAGE_JSON warning on stderr. It is harmless; I left it so the vendored directory stays unmodified.

@dborup

dborup commented Dec 3, 2026

Copy link
Copy Markdown
Owner

Review — CS-Minimax PR#1101 — head 7d71231

Dom: APPROVE with nits

Read-only review against my M0 research and the owner decisions of 2026-12-02 on #1035. I tested the head (7d712316) and the merged tree against current origin/master (33ca6aba; git merge-tree → bd0d24e7), both as git archive exports. The head was 7d712316 at git ls-remote before and after.

Evidence tags: [T] a test I ran, [A] analysis or my own measurement, [K] CI.

Findings

# Severity Finding Evidence
1 nit (document it, don't block) The postal answer follows the postnummer, not the point. Recommend takes postal scopes from the caller's DAGI postnummer, but meshguide.dk hit-tests its own DAWA polygons, which extend into the sea. The two disagree in a thin band along postnummer borders. On a 0.01° grid of every point inside a DAGI postnummer, 61,784 of 61,996 points (99.66 %) give exactly meshguide's scopesForPoint list. The 212 that differ:
• 206 have a neighbouring postnummer, e.g. 54.84,10.72: DAGI 5932, meshguide 5900, so +dk593 dk5932 −dk57 dk590 dk5900.
• 3 get postal scopes where meshguide's polygon misses, e.g. 55.90,12.39 in 3450.
• 3 lose postal scopes, e.g. 55.71,12.25: DAGI 2765 Smørum, meshguide 4000 Roskilde.
The conformance golden can't see this, because it feeds meshguide's own postnummer hit into Recommend rather than a DAGI code. So "Fyn and Sjælland get exactly meshguide's postal answer" holds per postnummer, not per point. Since the verdict is info only, this is acceptable. Please say it in the package doc and the PR, and have M2's wording name the postnummer ("recommended for 5932 …").
[A] my own DAGI grid probe (dagiDefault().locate) + the vendored engine
2 nit The M0 border tolerance is dropped without a note. M0 proposed also accepting scopes whose polygon lies within NEIGHBOR_DIST_M (2 km) of the point, and listed it as an M4 customizer value. Under decision 5 (info only) it no longer suppresses a finding, so leaving it out is defensible. A node 300 m outside dk-fyn-odense with that default will still show as other_meshguide. Please record the choice in the M2/M4 plan, or drop it from the M4 config list. [A]
3 nit Two getters can mutate the "immutable" guide. Guide.Postnummer returns a struct copy whose Postal slice shares the guide's backing array, and Upstream() returns the internal Files map. If a caller writes to either, it changes the shared, supposedly immutable guide across goroutines. Nothing calls them today. A copy costs ≤ 10 strings, or document "do not modify". [A]
4 nit The 31-scope cap only guards the conformance points. The generator checks the cap on those points, not on every row plus the worst-case region overlap. The margin is wide: my MAX_SCOPES = 21 mutant still generates (see below), and the largest postal row has 10 scopes. [A]
5 info Deviations from the M0 plan, all disclosed and fine:
• README.md replaces UPSTREAM.json.
• Upstream tools/scopes.test.js isn't vendored; its points are inlined in test-1035-scope-guide.js.
• The newest-advert accessor and the report-age handling move to M2.
• Region scopes are hit-tested at runtime, not tabulated.
[A]

The points I was asked to check

  • Vendored, pinned, licensed: all six files are byte-identical to twinoak/meshguide.dk@9a5d7f5fd210d863067f87581e75eaf562327d71. I fetched them from upstream and compared sha256 [A]. They match the README hashes and the table header [T], the WTFPL LICENSE is present, and git check-attr reports text: unset [T].

  • Deterministic offline generator: two --out runs and the checked-in files have the same sha256 [T]:

    • scopeguide-table.json: c4975a87…
    • conformance.json: 85ba3f2a…

    --check exits 0 on the head and on the merged tree [T]. The generator uses no clock and no randomness.

  • Postal scopes only in Fyn and Sjælland (decision 4): 204 rows carry postal scopes. Their codes run from 3000 to 5985, with none outside 3000–4793 / 5000–5999. meshguideOnly is [], and no postal scope is DAGI-derived [T][A]. The Hillerød (3400) row has no dk29, which my M0 prototype only got from the DAGI extension [T].

  • Unclipped DAGI neighbours (decision 2): I agree it is moot. Under decision 4 every postal scope, including the cross-water neighbours, comes from meshguide's own scopesFor. The rows reproduce my M0 water cases: Nyborg 5800 has dk42 dk53, and Marstal 5960 and Ærøskøbing 5970 have dk57 [A].

  • Copenhagen street postcodes grouped (decision 3): there are 484 aliases into 1050, 1550 and 1800, by the same lowest-code-per-name rule as dagiGroupStreetPostcodes [A]. 1051/1473 → 1050 and 1799 → 1550 [T].

  • Spot checks: each matches my M0 prototype's meshguide-only column [T][A].

    Postnummer Scopes
    Odense C 5000 dk-fyn-odense dk-fyn dk5 dk50 dk52 dk53 dk54 dk500 dk5000
    Roskilde 4000 dk-sjl + dk4 dk36 dk40 dk41 dk43 dk46 dk400 dk4000
    Aarhus C 8000 dk-aarhus dk-mj dk-oj dk-jylland, no postal
    København K dk-sjl se12 oresund dk-kbh, no postal
    Rønne 3700 dk-bhm se12 oresund, no postal

    The universe is 428, as in M0.

  • Repeaters and rooms only (decision 8): yes, and other roles get notApplicable: "role" [T].

  • Neutral and info-only (decision 5): the statuses are recommended, in_list, other_meshguide, not_meshguide, none and undecoded. Nothing says wrong, warn or mismatch [A].

  • Unknown names (decision 9): DefaultUndecoded gives undecoded, and it overrides a stale column value [T].

  • Exact case and #: names are compared exactly, so #DK ≠ dk [T].

  • Lookup cost:

    • BenchmarkRecommend: 351 ns/op [A].
    • BenchmarkRecommendCompare5k: 3.9 ms for 5,000 nodes, which meets M0's < 5 ms expectation [A].
    • The test logs 5.5 ms locally and 6.3 ms in CI against the 20 ms target [T][K].
    • Allocations: Recommend 5, Compare 13. The postnummer lookup is 2.5x a one-entry map locally and 2.0x in CI [T][K].
    • Only a 100 ms ceiling fails the test. That is acceptable because the alloc and ratio assertions are load-independent.
  • Table memory: 213 KB locally, 141 KB in CI, against a 1 MiB limit [T][K]. The 845 KB of postnumre are not embedded [A].

  • Server read-only and named structs:

    • The diff under cmd/ is empty, and nothing in cmd/ or public/ imports scopeguide yet [A].
    • There is no new map[string]interface{} in the diff [A]. The two map[string]string fields (Upstream.Files, aliases) are typed.
  • XSS, colours, fork guards, keywords, author:

    • check-xss-sinks.sh --diff origin/master is clean, since no public/ files changed [T]. There are no colours.
    • The fork guards are unchanged: 9 in deploy.yml, and release-fast-path.yml is untouched [A].
    • There are no closing keywords in the PR body or the commits [A].
    • Both commits are authored by dborup <kontakt@meshview.dk> [A].

Tests and mutants

Runs on the merged tree:

  • internal/scopeguide: go vet and go test ./... pass, and so does go test -race ./... [T].
  • cd cmd/server && go test ./...: ok … 155.7s [T].
  • node scripts/run-go-server-shard.js --validate: 4,129 entries, each in exactly one shard [T].
  • sh test-all.sh: 412 passed, 0 failed [T].
  • node test-frontend-helpers.js: 746 passed [T].
  • node test-1035-scope-guide.js: 11/11 [T].
  • E2E: not run locally. The PR changes nothing under public/ or cmd/server, and no binary imports the package, so no E2E is affected. All 3 Playwright shards are green in CI [K].
  • UI phone walk-through: not applicable, because M1 has no UI.

My own mutants:

Mutant Result
compareList drops Wildcard killed (the_full_recommended_list)
comparedRole drops room killed (TestCompareApplicability)
OtherMeshguide names go to NotMeshguide killed
Street alias ignored in Postnummer killed (spot checks, TestPostnummerLookup)
in_list only for the default killed (TestCompareDefaultScope)
undecoded only when the column is empty killed (TestCompareDefaultScope)
bbox prefilter too tight (maxLat − 0.02) killed (conformance)
Generator: street codes become rows (1,089 rows) killed by the node test. The Go tests stay green because the aliases still win [T]
Ray-cast < → <= survives. Equivalent: no grid point lies on an edge
seen dedup removed in Recommend survives. Equivalent today: no region name equals a postal or fixed name
Holes ignored in pointInPolygon survives. Equivalent today: none of the 40 regions has a hole [A]
bbox prefilter loosened survives. Equivalent, the same as the author's P1
MAX_SCOPES 31 → 21 in the generator survives. The data never exceeds 21 (finding 4)
TrimSpace removed from the default scope survives. Untested, but DB values carry no spaces, so it is harmless

CI per job [K]

Run 47002622813 on 7d712316, attempt 1, no reruns:

Job Result
Go Build & Test pass
Go Ingestor Tests pass
Go Libraries & CLI pass. The scopeguide lines are present: 6.27 ms, allocs 5/13, 2.0x, 140,512 B, 3918/3918
Go Server Tests 1/3, 2/3, 3/3 pass
JavaScript Unit Tests & Lint pass
Script & Container Unit Checks pass
Playwright E2E 1/3, 2/3, 3/3 pass
Verify Go Test Assignments pass
Validate Docker Image pass
Build & Publish Docker Image pass
Verify E2E Shards & Coverage pass
Badges, Release, Deploy Staging skipped (PR)

The earlier run 46994706735 on 4b63667e failed, as the author reports: the 20 ms hard limit, and the known flaky shard 2 deep-link case. The head fixes it.

What I did not verify

  • I did not run local Playwright E2E. Not needed (see above), but not done.
  • Live nodes: I did not re-run my M0 live-node comparison against this build (no prod access in this review). The border analysis above uses a synthetic grid.
  • The -race CI timing, and the arm64 vs amd64 float behaviour of the ray-cast beyond the conformance golden. The golden passes both locally on arm64 and in CI on amd64.

🤖 Generated with Claude Code

@dborup
dborup marked this pull request as ready for review December 3, 2026 02:53
@dborup
dborup merged commit 10a5f1d into master Dec 3, 2026
18 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants