Title: Intermittent 500 on concurrent PUTs to different trackers (pilot drag-drop) · Issue #309 · JavaScriptSolidServer/JavaScriptSolidServer · GitHub
Open Graph Title: Intermittent 500 on concurrent PUTs to different trackers (pilot drag-drop) · Issue #309 · JavaScriptSolidServer/JavaScriptSolidServer
X Title: Intermittent 500 on concurrent PUTs to different trackers (pilot drag-drop) · Issue #309 · JavaScriptSolidServer/JavaScriptSolidServer
Description: Problem Pilot's drag-and-drop across trackers issues two concurrent PUTs (source tracker + destination tracker). This usually succeeds, but intermittently one of the PUTs returns 500 while the other returns 204. Response body is 91 bytes...
Open Graph Description: Problem Pilot's drag-and-drop across trackers issues two concurrent PUTs (source tracker + destination tracker). This usually succeeds, but intermittently one of the PUTs returns 500 while the othe...
X Description: Problem Pilot's drag-and-drop across trackers issues two concurrent PUTs (source tracker + destination tracker). This usually succeeds, but intermittently one of the PUTs returns 500 while the ...
Opengraph URL: https://github.com/JavaScriptSolidServer/JavaScriptSolidServer/issues/309
X: @github
Domain: github.com
IPv4 address: 140.82.112.3
{"@context":"https://schema.org","@type":"DiscussionForumPosting","headline":"Intermittent 500 on concurrent PUTs to different trackers (pilot drag-drop)","articleBody":"## Problem\n\nPilot's drag-and-drop across trackers issues two concurrent PUTs (source tracker + destination tracker). This usually succeeds, but intermittently one of the PUTs returns 500 while the other returns 204.\n\nResponse body is 91 bytes (length reported by access log — content not captured in logs). No stack trace is written — the top-level error handler appears to swallow whatever threw.\n\n## Reproduction (on solid.social)\n\n1. Sign into a pod via pilot (test@jss on solid.social)\n2. Create two trackers (e.g. `home`, `work`)\n3. Add a task to one\n4. Drag the task between trackers repeatedly\n\nRoughly 1 in 5-10 drags will fail with \"PUT failed: 500 Internal Server Error\" in pilot's UI.\n\nSample from pm2 logs — two near-simultaneous PUTs, one 500, one 204:\n\n```\nreq-36 OPTIONS /public/tracker/home-data.jsonld 204 t=0\nreq-37 OPTIONS /public/tracker/work-data.jsonld 204 t=+1ms\nreq-38 PUT /public/tracker/home-data.jsonld 500 36ms body=91B\nreq-39 PUT /public/tracker/work-data.jsonld 204 34ms\n```\n\nThe failing PUT takes slightly longer (35.96ms vs 33.88ms) suggesting something blocking.\n\n## What we know\n\n- **Intermittent** — same workflow often succeeds\n- **Concurrent** — the two PUTs arrive within ~1ms\n- **Different resources** — one fails, the other succeeds\n- **Auth OK** — neither is 401/403\n- **Quota OK** — well under default\n- **Not a client issue** — pilot produces identical requests shape each time\n\n## What we need\n\n1. Add a top-level error hook in `server.js` that logs the full stack on any 500, so the next occurrence gives us the exception\n2. Investigate `src/handlers/resource.js` handlePut — possible races:\n - ACL walker reading directory ACLs while another request writes siblings\n - Notifications/events emitted during the second PUT encountering inconsistent state\n - Did-nostr resolver throwing (saw `DID resolution error ... fetch failed` in stderr near the time)\n3. Ensure concurrent-write safety: file write is atomic at OS level, but the read-stats-before-write pattern is racy\n\n## Priority\n\nMedium — UX is visibly broken in pilot but retries work. Most pilot users won't hit it on first drag. Fix path is probably: better logging first, then whatever the actual race is second.\n\n## Env\n\n- JSS v0.0.150 (with #308 fix applied)\n- Pilot via `solid-apps.github.io/pilot/`\n- Solid-OIDC (DPoP) auth","author":{"url":"https://github.com/melvincarvalho","@type":"Person","name":"melvincarvalho"},"datePublished":"2026-04-23T01:56:31Z","url":"https://github.com/JavaScriptSolidServer/JavaScriptSolidServer/issues/309"}
| react-profiling | 0 |
| react-import-map | react,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-controller | voltron_issues_fragments |
| route-action | issue_layout |
| fetch-nonce | v2:b90af624-9e9e-1909-a805-0a3e0f6d4b40 |
| current-catalog-service-hash | 81bb79d38c15960b92d99bca9288a9108c7a47b18f2423d0f6438c5b7bcd2114 |
| request-id | CE9E:22ECD6:7411C:98977:6B0393AB |
| html-safe-nonce | f344a15e0f5fc4c5776400398cd589a0afa7c13cc7bb1f260e0864b2fd5f82a5 |
| visitor-payload | eyJyZWZlcnJlciI6IiIsInJlcXVlc3RfaWQiOiJDRTlFOjIyRUNENjo3NDExQzo5ODk3Nzo2QjAzOTNBQiIsInZpc2l0b3JfaWQiOiI4ODQxMDYxNTY3ODE1NzE3ODAzIiwicmVnaW9uX2VkZ2UiOiJpYWQiLCJyZWdpb25fcmVuZGVyIjoiaWFkIn0= |
| visitor-hmac | 6d7d189cf98494e9dbf42963e021d5045804e7a645f7997e6d8eb7bd382702d7 |
| hovercard-subject-tag | issue:4312889051 |
| github-keyboard-shortcuts | repository,issues,copilot |
| google-site-verification | Apib7-x98H0j5cPqHWwSMm6dNU4GmODRoqxLiDzdx9I |
| octolytics-url | https://collector.github.com/github/collect |
| analytics-location | / |
| fb:app_id | 1401488693436528 |
| apple-itunes-app | app-id=1477376905, app-argument=https://github.com/_view_fragments/issues/show/JavaScriptSolidServer/JavaScriptSolidServer/309/issue_layout |
| twitter:image | https://opengraph.githubassets.com/30d8e6d0d00be3f466ef140dab5ea7b698e72d39132a1d45c17146bcc418ec1e/JavaScriptSolidServer/JavaScriptSolidServer/issues/309 |
| twitter:card | summary_large_image |
| og:image | https://opengraph.githubassets.com/30d8e6d0d00be3f466ef140dab5ea7b698e72d39132a1d45c17146bcc418ec1e/JavaScriptSolidServer/JavaScriptSolidServer/issues/309 |
| og:image:alt | Problem Pilot's drag-and-drop across trackers issues two concurrent PUTs (source tracker + destination tracker). This usually succeeds, but intermittently one of the PUTs returns 500 while the othe... |
| og:image:width | 1200 |
| og:image:height | 600 |
| og:site_name | GitHub |
| og:type | object |
| og:author:username | melvincarvalho |
| hostname | github.com |
| expected-hostname | github.com |
| None | 87e774ee7c6b3bee0490394e4d3e57ec9dbc956f74b87ea685dc8996c1676456 |
| turbo-cache-control | no-preview |
| go-import | github.com/JavaScriptSolidServer/JavaScriptSolidServer git https://github.com/JavaScriptSolidServer/JavaScriptSolidServer.git |
| octolytics-dimension-user_id | 205442424 |
| octolytics-dimension-user_login | JavaScriptSolidServer |
| octolytics-dimension-repository_id | 958025407 |
| octolytics-dimension-repository_nwo | JavaScriptSolidServer/JavaScriptSolidServer |
| octolytics-dimension-repository_public | true |
| octolytics-dimension-repository_is_fork | false |
| octolytics-dimension-repository_network_root_id | 958025407 |
| octolytics-dimension-repository_network_root_nwo | JavaScriptSolidServer/JavaScriptSolidServer |
| turbo-body-classes | logged-out env-production page-responsive |
| disable-turbo | false |
| browser-stats-url | https://api.github.com/_private/browser/stats |
| browser-errors-url | https://api.github.com/_private/browser/errors |
| release | 423dbb54c5e7bfecc838eb387c1435eb3d0e760d |
| ui-target | full |
| theme-color | #1e2327 |
| color-scheme | light dark |
| react-app-name | issues |
Links:
| Server | github.com |
| Content-Type | text/html; charset=utf-8 |
| Cache-Control | max-age=0, private, must-revalidate |
Viewport: width=device-width