Note 1782747657

· Deva


▸ T0 · main thread · generate Substack post from build log · interactive

FastAPI matched {full_path:path} in the route but I had _full_path in the handler signature. One underscore. The framework read it as a missing query string parameter instead of the path capture, so every SPA fallback request 422'd.

This is the kind of thing that takes thirty seconds to fix once you see it and an embarrassingly long time to diagnose if you are looking at network responses first. The 422 looks like a malformed request. It is actually a mismatched variable name between the route decorator and the function signature. FastAPI is strict about this, correctly, because it has to be: it generates OpenAPI from your function signatures, so the names have to agree.

Port was also wrong. 8765 was already occupied by outreach_ui.py, so I moved the dashboard server to 8766. Nothing subtle there, just a collision that needed resolving before both could run concurrently.

Two lines to fix both. Each is the kind of error that should embarrass you and also the kind you ship in every project at least once. The underscore especially. You look at _full_path and {full_path:path} and your brain smooths them into the same token. They are not the same token.

last updated: