Unknown Hesychia URLs return 404 with 404.html instead of 200 and the app shell.
Extensionless routes (/legal/terms-of-service, billing return paths, /document_storage) are served as HTML.
chat_web_app sends the security headers. The enforcing CSP stays loose enough for Tianji, the API, and the new analytics hosts. A stricter policy is report-only.
Production only: one-character paths redirect for HeyCatch short links.
Depends on #44. Merge that first, then retarget this to master if Gitea does not do it automatically.
Test plan
After #44 and this change are deployed, curl -sI https://hesychia.ai/not-a-page is 404.
curl -sI https://hesychia.ai/pricing/ is 200 once the frontend shells are published.
Response headers include Content-Security-Policy, X-Content-Type-Options: nosniff, X-Frame-Options: DENY, and Referrer-Policy.
curl -sI https://hesychia.ai/x is a 302 to /?utm_source=heycatch&utm_campaign=x.
## Summary
- Unknown Hesychia URLs return 404 with `404.html` instead of 200 and the app shell.
- Extensionless routes (`/legal/terms-of-service`, billing return paths, `/document_storage`) are served as HTML.
- `chat_web_app` sends the security headers. The enforcing CSP stays loose enough for Tianji, the API, and the new analytics hosts. A stricter policy is report-only.
- Production only: one-character paths redirect for HeyCatch short links.
Depends on #44. Merge that first, then retarget this to `master` if Gitea does not do it automatically.
## Test plan
- [ ] After #44 and this change are deployed, `curl -sI https://hesychia.ai/not-a-page` is 404.
- [ ] `curl -sI https://hesychia.ai/pricing/` is 200 once the frontend shells are published.
- [ ] Response headers include `Content-Security-Policy`, `X-Content-Type-Options: nosniff`, `X-Frame-Options: DENY`, and `Referrer-Policy`.
- [ ] `curl -sI https://hesychia.ai/x` is a 302 to `/?utm_source=heycatch&utm_campaign=x`.
Unknown URLs were returning the app shell with status 200. Return 404 for missing paths, keep the extensionless pages, and send the security headers. Production short links redirect for HeyCatch.
Co-authored-by: Cursor <cursoragent@cursor.com>
westfarn
merged commit 5e9878632e into feat/43-static-crawler-files2026-10-19 08:02:52 -07:00
Blocking a user prevents them from interacting with repositories, such as opening or commenting on pull requests or issues. Learn more about blocking a user.
Summary
404.htmlinstead of 200 and the app shell./legal/terms-of-service, billing return paths,/document_storage) are served as HTML.chat_web_appsends the security headers. The enforcing CSP stays loose enough for Tianji, the API, and the new analytics hosts. A stricter policy is report-only.Depends on #44. Merge that first, then retarget this to
masterif Gitea does not do it automatically.Test plan
curl -sI https://hesychia.ai/not-a-pageis 404.curl -sI https://hesychia.ai/pricing/is 200 once the frontend shells are published.Content-Security-Policy,X-Content-Type-Options: nosniff,X-Frame-Options: DENY, andReferrer-Policy.curl -sI https://hesychia.ai/xis a 302 to/?utm_source=heycatch&utm_campaign=x.