Repository navigation
fix(frontend): the marketing nav was never a consumer of MARKETING_PATHS - #715
Merged
Merged
Conversation
`routes.ts` called itself the "single source of truth for three consumers": the proxy, the sitemap, and "the marketing nav itself". The third does not exist. Nothing under `src/components/marketing/` imports either list — `marketing-header.tsx` carries a wordmark link to `/` and one CTA to PORTAL_ENTRY_PATH, and the footer only the CTA. The real consumers are two. The cost is a silent failure in the likeliest edit this surface gets. Following the documented "adding a page" recipe, a new `/pricing` is added to MARKETING_PATHS, becomes reachable through the proxy and appears in the sitemap — and is linked from nowhere on the site, because no nav derives from that list. The recipe reads as complete, and `make frontend` passes. Corrected at all five sites, and each now states the obligation rather than just dropping the count: - `routes.ts`, the MARKETING_PATHS doc comment: two consumers, plus why the nav is deliberately not one (a plain row at every width is what keeps the mobile DOM a subset of the desktop one, which the desktop-only axe sweep rests on) and that the link is a separate manual edit. - `routes.ts`, the file header: it said the proxy spreads MARKETING_PATHS. The proxy spreads MARKETING_PUBLIC_PATHS, which is the superset. Same confusion between the two lists that #682 fixed in the skill, one file over. - `landing-page/SKILL.md` trap 2 and the "adding a page" workflow. - `landing-page/evals.md` scenario 1, which now requires the answer to name the manual header link and calls an answer that stops at MARKETING_PATHS incomplete. Found by the post-merge consistency pass on #682, which had restated the false claim while fixing the neighbouring one. Co-Authored-By: Claude Opus 5 (1M context) <[email protected]>
…serted
`tests/unit/site-routes.test.ts` opens by claiming each assertion "pins a
property something else depends on". The property the proxy actually depends
on — that MARKETING_PUBLIC_PATHS contains every MARKETING_PATHS entry, since
PUBLIC_PATHS *is* that list — was the one nothing pinned.
The failure mode is a refactor rather than a typo: rewriting
MARKETING_PUBLIC_PATHS as a literal and dropping the `...MARKETING_PATHS`
spread keeps today's single page public by coincidence, and every future
marketing page is served a 307 to /login while the sitemap advertises it.
Mutation-tested rather than assumed. With the spread dropped, this is the only
case that fails:
× keeps every marketing path inside the public list
AssertionError: expected [ '/robots.txt', '/sitemap.xml' ] to include '/'
Tests 1 failed | 6 passed (7)
Six pre-existing assertions stayed green against a tree where the landing page
itself would have redirected to login — which is what makes this an accidental
pass rather than a thin one. Spread restored: 7 passed.
Co-Authored-By: Claude Opus 5 (1M context) <[email protected]>
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.
Post-merge follow-ups on #682. Two commits, each independently verified; one flagged item deliberately not done, with reasons.
1.
routes.tsclaimed a consumer that does not exist (ac90d33b)MARKETING_PATHScalled itself the "single source of truth for three consumers": the proxy, the sitemap, and "the marketing nav itself". The third does not exist — nothing undersrc/components/marketing/imports either list.marketing-header.tsxcarries a wordmark link to/and one CTA toPORTAL_ENTRY_PATH; the footer carries only the CTA.The cost lands on the likeliest edit this surface gets. Following the documented adding a page recipe,
/pricinggoes intoMARKETING_PATHS, becomes reachable through the proxy, appears in the sitemap — and is linked from nowhere, because no nav derives from that list. The recipe reads as complete and the gate passes.Corrected at five sites, each stating the obligation rather than just dropping the count:
routes.tsMARKETING_PATHScommentroutes.tsfile headerMARKETING_PATHS"MARKETING_PUBLIC_PATHS, the superset — the same two-list confusion #682 fixed in the skill, one file overlanding-page/SKILL.mdtrap 2landing-page/SKILL.mdadding-a-pagemarketing-header.tsxby handlanding-page/evals.mdscenario 1MARKETING_PATHSis incomplete#682 had restated this false claim while fixing the neighbouring one, which is how the consistency pass caught it.
2. The assertion nothing made (
77680247)tests/unit/site-routes.test.tsopens by claiming each assertion "pins a property something else depends on". The property the proxy actually depends on —MARKETING_PUBLIC_PATHScontaining everyMARKETING_PATHSentry, sincePUBLIC_PATHSis that list — was the one nothing pinned.Mutation-tested, not assumed. Dropping the
...MARKETING_PATHSspread (the realistic refactor, which keeps today's single page public by coincidence):Six pre-existing assertions stayed green against a tree where the landing page itself would 307 to
/login. That is what makes it an accidental pass rather than a thin one. Spread restored: 7 passed.Verification
eslint/prettier --check/tsc --noEmitmake skills-checklanding-pageloads intact; walking add a /pricing page against the pre-fix text reproduces the unlinked pageAn earlier combined run showed 4 failures (
usage.test.tshook timeouts on PGlite). Re-run alone it was fully green in 233s versus 479s — the failures were CPU contention from my own concurrentmake skills-check, not the diff. Flagging the sensitivity rather than treating it as a pass.Rebased onto
7fc70ead; main moved three times during this work.Deliberately not done
Next 16.4version literal (landing-page/SKILL.md), the one LOW finding I skipped in fix(skills): landing-page pointed a new page at the wrong routes list #682. On re-examination I still disagree with changing it: thecountslens exempts "a measurement with a fixture behind it … evidence, not inventory", and this dates a measured behaviour (ensureStaticrequirescacheComponents). Replacing it with a pointer to the pin would read as current after a Next upgrade nobody re-measured — strictly worse.merge busruns. Not a defect: the log readsmain moved from 8a74db3b to f034785d while the batch validated; abandoning. That is the bus's own base-moved guard firing correctly while a fleet of sibling audits hand-merged. No code change is the right answer; the remedy is the label workflow.frontend-data-ui's description at 3 characters of headroom.5d79a89adeferred that to an audit of that skill, and which of its clauses earns the space is that audit's judgement, not this PR's.🤖 Generated with Claude Code