Files
clean-architecture-frontend…/tests
DongHyeonkaandClaude Opus 5.5 793d54b4a9 fix(service-worker): accept JavaScript MIME synonyms and encoded lengths (R-6.5)
Static install compared content-type by exact match, so a server
answering `.js` with `application/javascript` failed every install with
CONTENT_TYPE_INVALID. It also compared Content-Length with the decoded
byte count, so any gzip/br response (whose Content-Length is the
encoded size) failed with BYTES_MISMATCH.

- A response type and a manifest type that are both JavaScript MIME
  essences (WHATWG MIME Sniffing list) now match.
- With a content-encoding header, the declared Content-Length is not
  compared. The streamed decoded byte count and sha256 checks are
  unchanged.

RED before fix (both REJECTED):
- installs JavaScript served under a JavaScript MIME synonym (R-6.5)
- does not compare an encoded Content-Length with the decoded size (R-6.5)
Guard: "still checks the decoded byte count of an encoded response"
(BYTES_MISMATCH).
Gates: check:architecture, check:types:{app,test,service-worker}, lint,
test:component pass. test:unit passes except the pre-existing
removal-fixture.test.ts case that needs generated release evidence
under artifacts/ (absent in a fresh worktree; unrelated to this diff).

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-09-24 12:28:38 +09:00
..