René's URL Explorer Experiment


Title: projector(subjects): GET /subjects/ throws a raw URIError out of the handler — 500 instead of 400/404 · Issue #2693 · developing-today/code · GitHub

Open Graph Title: projector(subjects): GET /subjects/ throws a raw URIError out of the handler — 500 instead of 400/404 · Issue #2693 · developing-today/code

X Title: projector(subjects): GET /subjects/ throws a raw URIError out of the handler — 500 instead of 400/404 · Issue #2693 · developing-today/code

Description: Problem The projector's joined-subject read endpoint throws on a malformed percent-encoding instead of answering with a clean error (main b3f6d2b): pm-stack/projector/src/server.ts:175-176 if (path.startsWith("/subjects/") && method === ...

Open Graph Description: Problem The projector's joined-subject read endpoint throws on a malformed percent-encoding instead of answering with a clean error (main b3f6d2b): pm-stack/projector/src/server.ts:175-176 if (path...

X Description: Problem The projector's joined-subject read endpoint throws on a malformed percent-encoding instead of answering with a clean error (main b3f6d2b): pm-stack/projector/src/server.ts:175-176 if (...

Opengraph URL: https://github.com/developing-today/code/issues/2693

X: @github

direct link

Domain: github.com

IPv4 address: 140.82.113.4


Hey, it has json ld scripts:
{"@context":"https://schema.org","@type":"DiscussionForumPosting","headline":"projector(subjects): GET /subjects/\u003cmalformed percent-encoding> throws a raw URIError out of the handler — 500 instead of 400/404","articleBody":"## Problem\n\nThe projector's joined-subject read endpoint throws on a malformed percent-encoding instead of answering with a clean error (main b3f6d2b2):\n\n**`pm-stack/projector/src/server.ts:175-176`**\n```ts\nif (path.startsWith(\"/subjects/\") && method === \"GET\") {\n  const subject = decodeURIComponent(path.slice(\"/subjects/\".length));\n```\n\n`decodeURIComponent` is unguarded, and this handler has no try/catch (unlike `/health` and the webhook path in the same file). A subject containing an incomplete UTF-8 percent sequence (`%E0%A4%A`) or a non-hex escape (`%zz`) raises a raw `URIError` that escapes `handleRequest` entirely — under `Bun.serve` the request fails as an unhandled 500 with no JSON error body, instead of the endpoint's own `404 {\"error\":\"subject_not_found\"}` or a 400 naming the bad encoding.\n\nSubjects are external keys (`kaneo:\u003cprojectSlug>/\u003ctaskId>`, `grist:\u003cdocId>/\u003ctableId>/\u003crowId>`, `gh:\u003cref>` — schema.sql), i.e. caller-supplied strings interpolated into a URL path by the aggregator and other clients, so a malformed or hand-built link reaches this code as-is.\n\n## Evidence (verified this run)\n\nProbe on the laptop (`~/git/fleet/probe-2026-10-30-laneB-projector/probe.ts`, real `handleRequest` + `migrate` against an in-memory libSQL DB, main b3f6d2b2):\n\n```text\nGET /subjects/%E0%A4%A     -> THREW URIError: URI error\nGET /subjects/%zz          -> THREW URIError: URI error\nGET /subjects/valid%20name -> status 404 body {\"error\":\"subject_not_found\"}\nGET /subjects/plain        -> status 404 body {\"error\":\"subject_not_found\"}\n```\n\nWell-formed encodings decode and 404 cleanly; only the malformed forms escape the handler as a thrown exception.\n\n## Why it matters\n\nThis is the projector's one joined read (links + item state + unified activity in one call — aggregator requirement #1 + #2). Any client that builds the path from an untrusted or hand-edited subject gets an opaque server error with no JSON body to handle, and the throw lands in the server log as an unhandled exception rather than a client error. Every other structured input on this server is validated at the boundary (webhook HMAC + bounded body, link `ref` regex); this decode is the loose one.\n\n## Acceptance criteria\n\n- [ ] `GET /subjects/\u003cmalformed percent-encoding>` (e.g. `%E0%A4%A`, `%zz`, a trailing `%`) returns a JSON 400 (or the endpoint's 404) — `handleRequest` never throws for any path input.\n- [ ] Well-formed subjects are unchanged: an existing subject still returns 200 with its view, an unknown one still returns `404 {\"error\":\"subject_not_found\"}`.\n- [ ] A handler-level test pins the malformed forms alongside the well-formed control cases.\n\nDistinct from #2633 (the same defect family in lab-ops-hub's file route — different app, different handler) and from #1547 (projector read-API `limit` validation; its acceptance criteria cover only the limit parameter).\n","author":{"url":"https://github.com/dezren39","@type":"Person","name":"dezren39"},"datePublished":"2026-10-30T10:55:53Z","url":"https://github.com/developing-today/code/issues/2693"}

react-profiling0
react-import-mapreact,react-dom,react-dom/client,react-dom/profiling,react-is,react/compiler-runtime,react/jsx-dev-runtime,react/jsx-runtime,scheduler@b8488ee2c322
route-pattern/_view_fragments/issues/show/:user_id/:repository/:id/issue_layout(.:format)
route-controllervoltron_issues_fragments
route-actionissue_layout
fetch-noncev2:1c53ee3c-5da7-d9b6-436a-807c59b6d3ca
current-catalog-service-hash81bb79d38c15960b92d99bca9288a9108c7a47b18f2423d0f6438c5b7bcd2114
request-id9BBA:34F10E:8085DA:AB8ECB:6B062FC0
html-safe-nonce836a1a1e9057e1e4b9722edd3e2bd763af8440befa0e27572d9e8541434f633f
visitor-payloadeyJyZWZlcnJlciI6IiIsInJlcXVlc3RfaWQiOiI5QkJBOjM0RjEwRTo4MDg1REE6QUI4RUNCOjZCMDYyRkMwIiwidmlzaXRvcl9pZCI6IjY4ODM2OTIwMTQzNTgzNzYzODQiLCJyZWdpb25fZWRnZSI6ImlhZCIsInJlZ2lvbl9yZW5kZXIiOiJpYWQifQ==
visitor-hmacef03f3c399ba506beafb8bc1ff272de28707ce0dabbef5da13a5f9010d75f69b
hovercard-subject-tagissue:6117743444
github-keyboard-shortcutsrepository,issues,copilot
google-site-verificationApib7-x98H0j5cPqHWwSMm6dNU4GmODRoqxLiDzdx9I
octolytics-urlhttps://collector.github.com/github/collect
analytics-location///voltron/issues_fragments/issue_layout
fb:app_id1401488693436528
apple-itunes-appapp-id=1477376905, app-argument=https://github.com/_view_fragments/issues/show/developing-today/code/2693/issue_layout
twitter:imagehttps://opengraph.githubassets.com/2713228435a94f2ee72cc2845ba1df4003cf972a1c0e0f89213478d8cd4308e7/developing-today/code/issues/2693
twitter:cardsummary_large_image
og:imagehttps://opengraph.githubassets.com/2713228435a94f2ee72cc2845ba1df4003cf972a1c0e0f89213478d8cd4308e7/developing-today/code/issues/2693
og:image:altProblem The projector's joined-subject read endpoint throws on a malformed percent-encoding instead of answering with a clean error (main b3f6d2b): pm-stack/projector/src/server.ts:175-176 if (path...
og:image:width1200
og:image:height600
og:site_nameGitHub
og:typeobject
og:author:usernamedezren39
hostnamegithub.com
expected-hostnamegithub.com
None7f961de5dd5c5d4aca24d33f8b3ffb3fb8b2ef53d0a4f32f01f0a790e512f6d3
turbo-cache-controlno-preview
go-importgithub.com/developing-today/code git https://github.com/developing-today/code.git
octolytics-dimension-user_id26439447
octolytics-dimension-user_logindeveloping-today
octolytics-dimension-repository_id627308783
octolytics-dimension-repository_nwodeveloping-today/code
octolytics-dimension-repository_publictrue
octolytics-dimension-repository_is_forkfalse
octolytics-dimension-repository_network_root_id627308783
octolytics-dimension-repository_network_root_nwodeveloping-today/code
turbo-body-classeslogged-out env-production page-responsive
disable-turbofalse
browser-stats-urlhttps://api.github.com/_private/browser/stats
browser-errors-urlhttps://api.github.com/_private/browser/errors
release494ea0bb1e0feef734a83e2628697647755e8864
ui-targetfull
theme-color#1e2327
color-schemelight dark
react-app-nameissues

Links:

Skip to contenthttps://github.com/developing-today/code/issues/2693#start-of-content
https://github.com/
Sign inhttps://github.com/login?return_to=https%3A%2F%2Fgithub.com%2Fdeveloping-today%2Fcode%2Fissues%2F2693
GitHubRepository hosting, code review, and collaborationhttps://github.com/platform
CopilotAI coding agent for tasks, projects, and automated workhttps://github.com/features/copilot
ActionsCI/CD and automationhttps://github.com/features/actions
Code QualityQuality analysis, fixes, and enforcementhttps://github.com/features/code-quality
CodespacesCloud development environmentshttps://github.com/features/codespaces
Code SecurityVulnerability detection and remediationhttps://github.com/security/advanced-security/code-security
Secret ProtectionSecret scanning and leak preventionhttps://github.com/security/advanced-security/secret-protection
All Featureshttps://github.com/features
Documentationhttps://docs.github.com/en
Traininghttps://learn.github.com/skills
Certificationshttps://learn.github.com/credentials
Build with Copilothttps://github.com/features/ai
Customize Copilothttps://docs.github.com/en/copilot/how-tos/copilot-on-github/customize-copilot/customize-copilot-overview
Integrationshttps://github.com/marketplace
Trending reposhttps://github.com/trending
GitHub Sponsorshttps://github.com/open-source/sponsors
Developer articleshttps://github.com/resources/articles
ChangelogYour source for the latest features, improvements, and fixes across GitHub products, all in one place.https://github.blog/changelog/
Enterpriseshttps://github.com/enterprise
Teamhttps://github.com/team
Startupshttps://github.com/enterprise/startups
Nonprofitshttps://github.com/solutions/industry/nonprofits
Healthcarehttps://github.com/solutions/industry/healthcare
Financial serviceshttps://github.com/solutions/industry/financial-services
Manufacturinghttps://github.com/solutions/industry/manufacturing
Governmenthttps://github.com/solutions/industry/government
See all industrieshttps://github.com/solutions/industry
Why GitHubhttps://github.com/why-github
Customer Storieshttps://github.com/customer-stories
Business insightshttps://github.com/solutions/executive-insights
Trust Centerhttps://github.com/trust-center
GitHub Advanced SecurityEnterprise-grade code securityhttps://github.com/security/advanced-security
Copilot for businessEnterprise-grade AI featureshttps://github.com/features/copilot/copilot-business
Premium SupportEnterprise-grade 24/7 supporthttps://github.com/enterprise/premium-support
Documentationhttps://docs.github.com/en
Resource centerhttps://github.com/resources
Bloghttps://github.blog/
Events & webinarshttps://github.com/resources/events
Community Forumhttps://github.com/orgs/community/discussions
Customer Storieshttps://github.com/customer-stories
Integrationshttps://github.com/marketplace
Customer supporthttps://help.github.com/
Traininghttps://learn.github.com/skills
GitHub Statushttps://www.githubstatus.com/
Abouthttps://github.com/about
Partnershttps://github.com/partners
Changeloghttps://github.blog/changelog/
GitHub UniverseThe event for developers, by developers — talks, workshops, and what’s next for GitHub.https://githubuniverse.com/
Pricinghttps://github.com/pricing
Sign inhttps://github.com/login?return_to=https%3A%2F%2Fgithub.com%2Fdeveloping-today%2Fcode%2Fissues%2F2693
Sign uphttps://github.com/signup?ref_cta=Sign+up&ref_loc=header+logged+out&ref_page=%2F%3Cuser-name%3E%2F%3Crepo-name%3E%2Fvoltron%2Fissues_fragments%2Fissue_layout&source=header-repo&source_repo=developing-today%2Fcode
Reloadhttps://github.com/developing-today/code/issues/2693
Reloadhttps://github.com/developing-today/code/issues/2693
Reloadhttps://github.com/developing-today/code/issues/2693
developing-todayhttps://github.com/developing-today
codehttps://github.com/developing-today/code
Codehttps://github.com/developing-today/code
Issues1.1k (1.1k)https://github.com/developing-today/code/issues
Pull requests151 (151)https://github.com/developing-today/code/pulls
Discussionshttps://github.com/developing-today/code/discussions
Actionshttps://github.com/developing-today/code/actions
Projectshttps://github.com/developing-today/code/projects
Wikihttps://github.com/developing-today/code/wiki
Security and qualityhttps://github.com/developing-today/code/security
Insightshttps://github.com/developing-today/code/insights
https://github.com/developing-today/code
New issuehttps://github.com/login?return_to=https://github.com/developing-today/code/issues/2693
New issuehttps://github.com/login?return_to=https://github.com/developing-today/code/issues/2693
#2906https://github.com/developing-today/code/pull/2906
projector(subjects): GET /subjects/ throws a raw URIError out of the handler — 500 instead of 400/404https://github.com/developing-today/code/issues/2693#top
#2906https://github.com/developing-today/code/pull/2906
https://github.com/dezren39
app/pm-stackhttps://github.com/developing-today/code/issues?q=state%3Aopen%20label%3A%22app%2Fpm-stack%22
effort/xshttps://github.com/developing-today/code/issues?q=state%3Aopen%20label%3A%22effort%2Fxs%22
kind/bughttps://github.com/developing-today/code/issues?q=state%3Aopen%20label%3A%22kind%2Fbug%22
priority/lowhttps://github.com/developing-today/code/issues?q=state%3Aopen%20label%3A%22priority%2Flow%22
source/creatorhttps://github.com/developing-today/code/issues?q=state%3Aopen%20label%3A%22source%2Fcreator%22
source/design-architecthttps://github.com/developing-today/code/issues?q=state%3Aopen%20label%3A%22source%2Fdesign-architect%22
task/triagehttps://github.com/developing-today/code/issues?q=state%3Aopen%20label%3A%22task%2Ftriage%22
https://github.com/dezren39
dezren39https://github.com/dezren39
on Oct 30, 2026https://github.com/developing-today/code/issues/2693#issue-6117743444
b3f6d2bhttps://github.com/developing-today/code/commit/b3f6d2b2c7cac6cd60d71e42a8fe537d676442df
b3f6d2bhttps://github.com/developing-today/code/commit/b3f6d2b2c7cac6cd60d71e42a8fe537d676442df
#1https://github.com/orgs/developing-today/discussions/1
#2https://github.com/developing-today/code/pull/2
#2633https://github.com/developing-today/code/issues/2633
#1547https://github.com/developing-today/code/issues/1547
Nexthttps://github.com/developing-today/code/issues/2693?timeline_page=1
dezren39https://github.com/dezren39
kind/bughttps://github.com/developing-today/code/issues?q=state%3Aopen%20label%3A%22kind%2Fbug%22
priority/lowhttps://github.com/developing-today/code/issues?q=state%3Aopen%20label%3A%22priority%2Flow%22
queue/queuedhttps://github.com/developing-today/code/issues?q=state%3Aopen%20label%3A%22queue%2Fqueued%22
source/creatorhttps://github.com/developing-today/code/issues?q=state%3Aopen%20label%3A%22source%2Fcreator%22
task/triagehttps://github.com/developing-today/code/issues?q=state%3Aopen%20label%3A%22task%2Ftriage%22
status/needs-triagehttps://github.com/developing-today/code/issues?q=state%3Aopen%20label%3A%22status%2Fneeds-triage%22
app/pm-stackhttps://github.com/developing-today/code/issues?q=state%3Aopen%20label%3A%22app%2Fpm-stack%22
effort/xshttps://github.com/developing-today/code/issues?q=state%3Aopen%20label%3A%22effort%2Fxs%22
on Oct 30, 2026https://github.com/developing-today/code/issues/2693#event-34682464655
https://github.com/dezren39
dezren39https://github.com/dezren39
on Oct 30, 2026https://github.com/developing-today/code/issues/2693#issuecomment-6520988630
b3f6d2bhttps://github.com/developing-today/code/commit/b3f6d2b2c7cac6cd60d71e42a8fe537d676442df
lab-ops-hub: GET /api/files/ returns 500 (raw URIError) — the key decode is unguarded, so a bad key spelling is never a 400/404 #2633https://github.com/developing-today/code/issues/2633
lab-ops-hub: GET /api/files/ returns 500 (raw URIError) — the key decode is unguarded, so a bad key spelling is never a 400/404 #2633https://github.com/developing-today/code/issues/2633
projector: read-API limit is never validated — ?limit=-1 returns the whole table and ?limit=2.7 500s the request #1547https://github.com/developing-today/code/issues/1547
projector: read-API limit is never validated — ?limit=-1 returns the whole table and ?limit=2.7 500s the request #1547https://github.com/developing-today/code/issues/1547
github-actionshttps://github.com/apps/github-actions
dezren39https://github.com/dezren39
on Oct 30, 2026https://github.com/developing-today/code/issues/2693#event-34685016548
dezren39https://github.com/dezren39
on Oct 30, 2026https://github.com/developing-today/code/issues/2693#event-34694722068
design(path-decode): one decode for path segments — a malformed percent-encoding is a 400, never a 500 #2747https://github.com/developing-today/code/issues/2747
dezren39https://github.com/dezren39
source/design-architecthttps://github.com/developing-today/code/issues?q=state%3Aopen%20label%3A%22source%2Fdesign-architect%22
on Oct 30, 2026https://github.com/developing-today/code/issues/2693#event-34694733576
https://github.com/dezren39
dezren39https://github.com/dezren39
on Oct 30, 2026https://github.com/developing-today/code/issues/2693#issuecomment-6524058830
#2747https://github.com/developing-today/code/issues/2747
#2747https://github.com/developing-today/code/issues/2747
#2747https://github.com/developing-today/code/issues/2747
#2748https://github.com/developing-today/code/issues/2748
#2633https://github.com/developing-today/code/issues/2633
#2720https://github.com/developing-today/code/issues/2720
#2747https://github.com/developing-today/code/issues/2747
#2747https://github.com/developing-today/code/issues/2747
dezren39https://github.com/dezren39
work/assignedhttps://github.com/developing-today/code/issues?q=state%3Aopen%20label%3A%22work%2Fassigned%22
queue/claimedhttps://github.com/developing-today/code/issues?q=state%3Aopen%20label%3A%22queue%2Fclaimed%22
on Oct 31, 2026https://github.com/developing-today/code/issues/2693#event-34744408526
dezren39https://github.com/dezren39
queue/parkedhttps://github.com/developing-today/code/issues?q=state%3Aopen%20label%3A%22queue%2Fparked%22
status/parkedhttps://github.com/developing-today/code/issues?q=state%3Aopen%20label%3A%22status%2Fparked%22
status/in-progresshttps://github.com/developing-today/code/issues?q=state%3Aopen%20label%3A%22status%2Fin-progress%22
queue/claimedhttps://github.com/developing-today/code/issues?q=state%3Aopen%20label%3A%22queue%2Fclaimed%22
on Oct 31, 2026https://github.com/developing-today/code/issues/2693#event-34746797569
https://github.com/dezren39
dezren39https://github.com/dezren39
on Oct 31, 2026https://github.com/developing-today/code/issues/2693#issuecomment-6537623685
1ad8da6https://github.com/developing-today/code/commit/1ad8da6b73a2c41de0207244bc336a66b01a236e
projector(subjects): GET /subjects/ throws a raw URIError out of the handler — 500 instead of 400/404 #2693https://github.com/developing-today/code/issues/2693
projector(subjects): GET /subjects/ throws a raw URIError out of the handler — 500 instead of 400/404 #2693https://github.com/developing-today/code/issues/2693
fix(projector): malformed percent-encoding in /subjects/ returns JSON 400 (#2693) #2906https://github.com/developing-today/code/pull/2906
dezren39https://github.com/dezren39
queue/claimedhttps://github.com/developing-today/code/issues?q=state%3Aopen%20label%3A%22queue%2Fclaimed%22
status/in-progresshttps://github.com/developing-today/code/issues?q=state%3Aopen%20label%3A%22status%2Fin-progress%22
status/parkedhttps://github.com/developing-today/code/issues?q=state%3Aopen%20label%3A%22status%2Fparked%22
queue/parkedhttps://github.com/developing-today/code/issues?q=state%3Aopen%20label%3A%22queue%2Fparked%22
on Oct 31, 2026https://github.com/developing-today/code/issues/2693#event-34747929044
dezren39https://github.com/dezren39
on Oct 31, 2026https://github.com/developing-today/code/issues/2693#event-34747940563
fix(projector): malformed percent-encoding in /subjects/ returns JSON…https://github.com/developing-today/code/commit/0281d10f41054783bd56d8e7a243b06ab95c1507
0281d10https://github.com/developing-today/code/commit/0281d10f41054783bd56d8e7a243b06ab95c1507
dezren39https://github.com/dezren39
completedhttps://github.com/developing-today/code/issues?q=is%3Aissue%20state%3Aclosed%20archived%3Afalse%20reason%3Acompleted
#2906https://github.com/developing-today/code/pull/2906
on Oct 31, 2026https://github.com/developing-today/code/issues/2693#event-34747941458
dezren39https://github.com/dezren39
status/in-progresshttps://github.com/developing-today/code/issues?q=state%3Aopen%20label%3A%22status%2Fin-progress%22
queue/claimedhttps://github.com/developing-today/code/issues?q=state%3Aopen%20label%3A%22queue%2Fclaimed%22
work/assignedhttps://github.com/developing-today/code/issues?q=state%3Aopen%20label%3A%22work%2Fassigned%22
on Oct 31, 2026https://github.com/developing-today/code/issues/2693#event-34747964709
https://github.com/dezren39
dezren39https://github.com/dezren39
on Oct 31, 2026https://github.com/developing-today/code/issues/2693#issuecomment-6537634215
1ad8da6https://github.com/developing-today/code/commit/1ad8da6b73a2c41de0207244bc336a66b01a236e
0281d10https://github.com/developing-today/code/commit/0281d10f41054783bd56d8e7a243b06ab95c1507
fix(projector): malformed percent-encoding in /subjects/ returns JSON 400 (#2693) #2906https://github.com/developing-today/code/pull/2906
Sign up for freehttps://github.com/signup?return_to=https://github.com/developing-today/code/issues/2693
Sign in to commenthttps://github.com/login?return_to=https://github.com/developing-today/code/issues/2693
dezren39https://github.com/dezren39
app/pm-stackhttps://github.com/developing-today/code/issues?q=state%3Aopen%20label%3A%22app%2Fpm-stack%22
effort/xshttps://github.com/developing-today/code/issues?q=state%3Aopen%20label%3A%22effort%2Fxs%22
kind/bughttps://github.com/developing-today/code/issues?q=state%3Aopen%20label%3A%22kind%2Fbug%22
priority/lowhttps://github.com/developing-today/code/issues?q=state%3Aopen%20label%3A%22priority%2Flow%22
source/creatorhttps://github.com/developing-today/code/issues?q=state%3Aopen%20label%3A%22source%2Fcreator%22
source/design-architecthttps://github.com/developing-today/code/issues?q=state%3Aopen%20label%3A%22source%2Fdesign-architect%22
task/triagehttps://github.com/developing-today/code/issues?q=state%3Aopen%20label%3A%22task%2Ftriage%22
https://github.com
Termshttps://docs.github.com/site-policy/github-terms/github-terms-of-service
Privacyhttps://docs.github.com/site-policy/privacy-policies/github-privacy-statement
Securityhttps://github.com/security
Statushttps://www.githubstatus.com/
Communityhttps://github.community/
Docshttps://docs.github.com/
Contacthttps://support.github.com?tags=dotcom-footer

Response headers:
Servergithub.com
Content-Typetext/html; charset=utf-8
Cache-Controlmax-age=0, private, must-revalidate

Viewport: width=device-width


URLs of crawlers that visited me.