ReviewOS

home-lang/home

Port HTTP/1.1 chunked transfer TCP corpus

#176
Closed chris opened this 10 days ago ·
10 days ago

Focused Bun parity tranche split from #66.

Current state:

  • js/bun/http/http-server-chunking.test.ts is byte-identical to ~/Code/bun
  • Home currently rewrites the complete file to one native TODO

Scope:

  • activate fragmented chunk terminator handling
  • activate split chunk-size CRLF and extension handling
  • reject bare LF, invalid terminators, zero-digit sizes, and oversized Content-Length state aliasing
  • preserve request-smuggling protections for trailing pipelined requests
  • cover tiny TCP send-buffer behavior
  • keep the upstream fixture untouched and add a permanent Home regression

Acceptance:

  • exact fixture passes with zero failures/TODOs/unsupported cases
  • adjacent HTTP parser corpora remain green
  • complete home_test gate passes
10 days ago

Completed and pushed to main in b104516ce.

What landed:

  • activated the untouched js/bun/http/http-server-chunking.test.ts corpus
  • added test.concurrentIf / it.concurrentIf compatibility
  • implemented socket send/receive option handling used by the tiny-buffer cases
  • replaced the one-request bridge with persistent sequential HTTP/1.1 request processing
  • buffered fragmented chunk-size lines and chunk terminators
  • parsed chunk extensions and validated hexadecimal sizes and CRLF framing
  • rejected malformed framing with HTTP 400 plus deterministic connection close
  • preserved ordered pipelined responses and HTTP/1.1 keep-alive / explicit close behavior
  • added a durable exact-corpus Home regression

Verification:

  • exact upstream corpus: 11 passed, 0 failed, 0 unsupported, 0 TODO
  • focused matrix including adjacent HTTP/server/header corpora: 118 active passed, 0 failed, 0 unsupported, with 2 explicit upstream TODOs in bun-serve-file
  • bun-serve-static.test.ts: 34/34 passed
  • complete home_test gate: exit 0 in 19m39.84s
  • Home and ~/Code/bun fixture SHA-256 match: fb092606e46ef5f1e331fe1a6358e9836f9c187d69e0e1a48f842dc98a0bea00

No upstream corpus files were modified.

Sign in to comment on this issue.