Repository navigation
fix: 4 bugs from round-2 Chrome walkthrough (redirect loop, slug routing, seed CLIs, label-form roles) - #82
Merged
Conversation
… 069 seed CLIs + slug routing
Round-2 Chrome walkthrough fixes + 2 more STORY filings.
Fixes (verified end-to-end in Chrome):
- **STORY-066** — `destinationFor` now uses `getRecommendation` to check whether
`target_role` actually maps to a known role before routing to /recommended.
Unknown roles go straight to /dashboard. Breaks the infinite
/dashboard ↔ /recommended 307 loop that hit every deterministic-onboarding
user. New dep: `apps/web` → `@learnpro/profile`.
- **STORY-067** — `getRecommendation` matches against `label` as well as
`slug`, both case-insensitive + trimmed. The deterministic onboarding
fallback writes labels ("Backend engineer"); now those resolve to the
`backend-engineer` slug's role.
- **STORY-068** — Two new bin scripts:
- `pnpm --filter @learnpro/tracks db:seed:tracks` — loads python-fundamentals
and typescript-fundamentals YAMLs into Postgres. Idempotent.
- `pnpm --filter @learnpro/problems db:seed:problems` — loads all 182
curated problem YAMLs (35 Py + 32 TS implement, 25 Py + 22 TS debug,
38 Py + 30 TS comprehension). Idempotent. Requires tracks first.
- Root `pnpm db:bootstrap` aggregates: migrate → seed → seed:concepts
→ seed:tracks → seed:problems. Single-command bootstrap for fresh
self-host clones.
- **STORY-069** (filed + fixed) — `/session?track=<slug>` now resolves
through new `getTrackIdBySlug(db, slug)` helper. Previously the route
required UUID-form input and the /recommended cards built slug-form
hrefs, so every "Start track" click bricked at "Pick a track."
Filed (not fixed in this PR):
- **STORY-070** — Today's plan + Hint + Grade all surface 500/503 when
ANTHROPIC_API_KEY is unset. The deterministic-onboarding fallback path
(STORY-053 AC #6) needs sibling fallbacks for these surfaces or the
no-API-key self-host story is broken end-to-end.
Walkthrough verification (round 2):
- ✓ Onboarding → /recommended → click Python card → /session?track=python-fundamentals → real problem renders (Monaco editor + file tree + paste-detect + got-help toggle all wired)
- ✓ Settings pages: /settings/llm (tutor mode), /settings/notifications (quiet hours + email digest), /settings/data (GDPR summary + actions) — all render with coach-voice copy
- ✓ STORY-042 paste-detect modal fires on paste into Monaco, coach-voice copy
- ✓ STORY-037 debug-problem panel renders the yellow "this is a debug problem" callout + pre-bugged code
- ✗ Hint / Today's plan / Submit blocked by STORY-070 (no LLM fallback)
- ✗ Run / Submit also blocked by STORY-065 (Piston on Windows Docker Desktop)
2 tasks done
khoks
added a commit
that referenced
this pull request
May 14, 2026
The harness writes `.claude/scheduled_tasks.lock` to serialize scheduled-task firings. It slipped into PR #82 via `git add -A`; remove from tracking and add to .gitignore so it stops appearing in `git status`. Also gitignore `.dev-logs/` — the per-component log directory created by scripts/dev.sh on each run.
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
Round-2 Chrome walkthrough fixed 4 of the bugs filed in PR #81 and uncovered 2 more.
destinationForonly routes to /recommended when role library recognizes the target_rolegetRecommendationmatches by label, not just slugdb:seed:tracks+db:seed:problemsCLIs + rootdb:bootstrapaggregator/session?track=<slug>resolves throughgetTrackIdBySlugNewly filed (not fixed here)
Walkthrough log (round 2)
What works now
Still broken (existing STORY filings)
Test plan
pnpm format:checkclean🤖 Generated with Claude Code