fix: preserve large Unicode drafts with bounded keepalive transport

This commit is contained in:
2026-10-29 23:08:09 +02:00
parent fa2ece10de
commit ed96fd10b9
7 changed files with 305 additions and 25 deletions
@@ -1376,5 +1376,63 @@
"preservation": "Frontend recovery only. Backend confirmation/idempotency, data/schema, permissions and fiscal rules unchanged. No active writes or deployment. Historical accepted suites reused.",
"visual_acceptance": "Pending team execution and recording; mocked asynchronous tests do not constitute browser-session acceptance.",
"installation": "Not triggered; main and active release unchanged."
},
"context_draft_transport_increment": {
"recorded_at": "2026-10-29T21:08:08.809170+00:00",
"base_commit": "fa2ece10deb0570b50e3ae9bdc8349a54f8bf055",
"requirements": [
"V2-07",
"V2-10",
"Tempo adaptive journey decision 2026-10-23: retain choices on refresh and navigation"
],
"defects": [
"Character count was used instead of UTF-8 byte length when selecting keepalive.",
"Concurrent context keepalive requests did not share a local byte budget.",
"Page exit silently skipped drafts at or above 60000 characters."
],
"behavior": "Serialise once and preserve the entire body; use keepalive only when UTF-8 body plus contextApi keepalive bytes in flight is below 60000. Larger/concurrent requests fall back to ordinary fetch without truncation or automatic write retry. Release reservation on success/error. Autosave and pagehide delegate transport eligibility instead of dropping large drafts.",
"technical_basis": {
"source": "https://fetch.spec.whatwg.org/#http-network-or-cache-fetch",
"rule": "Fetch limits aggregate in-flight keepalive request bodies to 64 KiB; 60000-byte local headroom is an implementation choice, not a business rule."
},
"checks": {
"previous_revision_transport": {
"passed": 2,
"failed": 2
},
"previous_revision_large_pagehide": {
"passed": 0,
"failed": 1
},
"directed_frontend_passed": 20,
"new_frontend_cases": 5,
"existing_cases_reused": 15,
"types": "passed",
"lint": "passed",
"format": "passed",
"qa_build": "passed"
},
"source_sha256": {
"resources/js/lib/investor-context.ts": "ee225034e65caf3547a82aef55f1cef23c2984bb430e375742317754313c1996",
"resources/js/pages/investor-path/context.tsx": "43ec8ee55056f1f014fd4ac5d1da2febeb77d565c6baeef89f07d677029af1a7",
"tests/frontend/investor-context-api.test.mjs": "c12037c6284762a01a0971010aed9d4df9866aa61b01ddb2be29b3b156e8684d",
"tests/frontend/investor-usability-components.test.mjs": "cee14ae2c3e4234b8ab76e7bacd8369cb9cbb8a24ca1aa0c672384f4f192ece1"
},
"evidence": {
"outputs/validation-20261029/context-transport-red.log": "ba5b77dccfa91f4ac415c7bf4787c515f6c68e905144e24fdf601e5365e83e10",
"outputs/validation-20261029/context-transport-page-red.log": "c138dfd4c38080f9e497965f6715f0dca1fb4bbcd5dc33a9afc909c11b9ca6c7",
"outputs/validation-20261029/context-transport-tests.log": "3d787cc079b28fc72f40aa36f96cef8a84e77e59454f66992a3689d2e60914c4",
"outputs/validation-20261029/context-transport-types.log": "82962651e47f564de653ad2883f8fd34e7dae4b4468e4ac459cb3331962a3879",
"outputs/validation-20261029/context-transport-lint.log": "e3b0c44298fc1c149afbf4c8996fb92427ae41e4649b934ca495991b7852b855",
"outputs/validation-20261029/context-transport-component-lint.log": "e3b0c44298fc1c149afbf4c8996fb92427ae41e4649b934ca495991b7852b855",
"outputs/validation-20261029/context-transport-format-check.log": "4a1bea51045c40a97f34189c93babe919544f4e6fce4d89e876255b5e72d9f42",
"outputs/validation-20261029/context-transport-component-format-check.log": "b2d21e443253f5427422f71003397c1e188a181902594e82a1435e8a82342dbe",
"outputs/validation-20261029/context-transport-build.log": "94ecfec7f5b8eec6ef417466986d9ca88305f7daa3d131f0e8a864664245831a",
"outputs/validation-20261029/context-transport-build-exit.json": "124fd50cb6d223cdd18fedc166d00af7254199b6e6dedf9be82f71db87af6d01"
},
"limits": "Ordinary fetch after page exit remains best-effort. Local accounting cannot reserve browser-wide capacity used by other code. This does not claim guaranteed persistence on immediate tab close; normal autosave and its status/retry remain essential.",
"preservation": "No payload truncation, field/rule restrictions, backend/schema/permissions/tax changes or active writes. Authentication, methods and HTTP conflict behavior preserved. Historical accepted suites reused.",
"visual_acceptance": "Pending team execution and recording; mocked transport/component tests do not constitute browser acceptance.",
"installation": "Not triggered; main and active release unchanged."
}
}