You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Astro's BASE_URL was missing the trailing slash, so templates like
`${BASE_URL}framework/` rendered as `/scientific-agentic-engineeringframework/`
and broke in-site navigation on the deployed subpath. Normalize `base`
in astro.config.mjs to end with `/` and drop the compensating leading
slash in BaseLayout's favicon href.
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
Entire-Checkpoint: ff13b2224bf4
Copy file name to clipboardExpand all lines: docs/development-log.md
+26Lines changed: 26 additions & 0 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -403,6 +403,32 @@ The 3-commit structure from the plan proved its value immediately: if the deploy
403
403
404
404
---
405
405
406
+
## Session 3 — 2026-04-15: Post-Deploy Bug Fixes
407
+
408
+
### Interaction 15: Nav Link Slash Bug (Base Path Concatenation)
409
+
410
+
**Human prompt (paraphrased):**
411
+
> On the live site, clicking a nav link breaks it because the URL doesn't preserve the `/` between the base path and the route.
412
+
413
+
**What the AI did:**
414
+
- Reproduced the issue by inspecting built HTML in `dist/index.html`: hrefs were rendering as `/scientific-agentic-engineeringframework/` (no slash between base and route)
415
+
- Traced the cause to `astro.config.mjs` using `base: '/scientific-agentic-engineering'` (no trailing slash), combined with templates like `${import.meta.env.BASE_URL}framework/` that assume the base ends in `/`
416
+
- Noted an internal inconsistency: `BaseLayout.astro` had already worked around the problem with `${BASE_URL}/favicon.svg` (leading slash on the path), while `Nav.astro`, `Hero.astro`, `pages/index.astro`, and `pages/framework/index.astro` assumed the opposite convention
417
+
- Fixed by (a) adding the trailing slash to `base` in `astro.config.mjs` so all templates compose correctly, and (b) removing the now-redundant leading slash in the `BaseLayout.astro` favicon line to avoid `//favicon.svg`
418
+
- Rebuilt and verified all hrefs render as `/scientific-agentic-engineering/framework/` (with the slash)
419
+
420
+
**Key findings/output:**
421
+
- Astro 6 does **not** auto-normalize `import.meta.env.BASE_URL` to end with a trailing slash — it reflects the configured `base` literally. This differs from some older Astro documentation examples and is a realistic papercut for projects deployed under a subpath.
422
+
- The bug was invisible on the home page itself (which loads at the base URL directly) and only surfaced on *clicks* into subpaths — a reminder that automated CI builds passing ≠ the site works as users would use it. The `npm run build` and GitHub Pages deploy both succeeded in Session 2; the defect was latent.
423
+
424
+
**Human decisions:**
425
+
- Chose to fix at the config level (add trailing slash to `base`) rather than patch each template — a convention-at-the-source fix so future templates compose correctly by default
426
+
427
+
**Observation:**
428
+
This is the first post-deploy defect in the project, and it exposes a gap in Session 2's verification: the dev-server smoke test (Interaction 11) and the deploy verification (Interaction 14) both confirmed the site *loaded*, not that in-site navigation worked. A more complete smoke test would click through each top-level nav link. This is a small but worth-keeping example of the difference between "builds + serves HTTP 200" and "functions for a user," which is directly relevant to the fellowship's broader theme of how AI-assisted workflows should define "done."
0 commit comments