Title: stream: improve Web Compression spec compliance by panva · Pull Request #62107 · nodejs/node · GitHub
Open Graph Title: stream: improve Web Compression spec compliance by panva · Pull Request #62107 · nodejs/node
X Title: stream: improve Web Compression spec compliance by panva · Pull Request #62107 · nodejs/node
Description: Investigating why wpt.fyi daily runs took 26 minutes and then started taking 75 minutes last week lead me down this road. Daily epoch synced WPTs were hanging again on test-compression, the switch to arm kicked in tools/test.py increase in timeouts (hence going from 26 to 75 minutes), and because the entire WPT subsuite errored there were no compression tests reported to wpt.fyi. This PR updates the WPTs (some of which are no longer tentative) and improves the conformance of CompressionStream and DecompressionStream to the WHATWG Compression standard. test: update WPT compression to ae05f5cb53 Simple WPT update test: improve WPT report runner Add incremental report writing after each spec completes and on worker errors so that reports survive if the process is killed before the exit handler runs. Add bytes() method to readAsFetch() to match the Response API used by newer WPT tests. stream: improve Web Compression spec compliance Pass rejectGarbageAfterEnd: true to createInflateRaw() and createBrotliDecompress(), matching the behavior already in place for deflate and gzip. The Compression Streams spec treats any data following a valid compressed payload as an error. When the underlying Node.js stream throws synchronously from write() (e.g. zlib rejects an invalid chunk type), destroy the stream so that the readable side is also errored. Without this, the readable side hangs forever waiting for data that will never arrive. Introduce a kValidateChunk callback option in the webstreams adapter layer. Compression streams use this to validate that chunks are BufferSource instances not backed by SharedArrayBuffer, rather than monkey-patching the underlying handle's write method. Unskip WPT compression bad-chunks tests which now run instead of hang and mark the remaining expected failures. stream: fix brotli error handling in web compression streams Convert brotli decompression errors to TypeError to match the Compression Streams spec, by extending handleKnownInternalErrors() in the adapters layer to recognize brotli error codes. This replaces the manual error event handler on DecompressionStream which was redundant with the adapter's built-in error propagation.
Open Graph Description: Investigating why wpt.fyi daily runs took 26 minutes and then started taking 75 minutes last week lead me down this road. Daily epoch synced WPTs were hanging again on test-compression, the switch ...
X Description: Investigating why wpt.fyi daily runs took 26 minutes and then started taking 75 minutes last week lead me down this road. Daily epoch synced WPTs were hanging again on test-compression, the switch ...
Opengraph URL: https://github.com/nodejs/node/pull/62107
X: @github
Domain: github.com
| route-pattern | /:user_id/:repository/pull/:id/files(.:format) |
| route-controller | pull_requests |
| route-action | files |
| fetch-nonce | v2:28fe6400-2799-f30b-ac93-ffa835656cd2 |
| current-catalog-service-hash | ae870bc5e265a340912cde392f23dad3671a0a881730ffdadd82f2f57d81641b |
| request-id | 873A:127DAD:112C66D:171603B:6A4C6E06 |
| html-safe-nonce | a1361bb3b4ce15d92b5b84863fb564d93dad01a0ac8b83b2e5b405405835832d |
| visitor-payload | eyJyZWZlcnJlciI6IiIsInJlcXVlc3RfaWQiOiI4NzNBOjEyN0RBRDoxMTJDNjZEOjE3MTYwM0I6NkE0QzZFMDYiLCJ2aXNpdG9yX2lkIjoiMjEzNDI4MDQ2MzkxOTYzMTQzIiwicmVnaW9uX2VkZ2UiOiJpYWQiLCJyZWdpb25fcmVuZGVyIjoiaWFkIn0= |
| visitor-hmac | f9b9fa3b8c26532d59c27cf4a4f31c09bf25a513b9dcf18222f8804ffb8476af |
| hovercard-subject-tag | pull_request:3355441929 |
| github-keyboard-shortcuts | repository,pull-request-list,pull-request-conversation,pull-request-files-changed,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/nodejs/node/pull/62107/files |
| twitter:image | https://avatars.githubusercontent.com/u/241506?s=400&v=4 |
| twitter:card | summary_large_image |
| og:image | https://avatars.githubusercontent.com/u/241506?s=400&v=4 |
| og:image:alt | Investigating why wpt.fyi daily runs took 26 minutes and then started taking 75 minutes last week lead me down this road. Daily epoch synced WPTs were hanging again on test-compression, the switch ... |
| og:site_name | GitHub |
| og:type | object |
| hostname | github.com |
| expected-hostname | github.com |
| None | 3d11bb817438277de2a940854450e83a7d32b6aeb5014e9e6b00a6423900251c |
| turbo-cache-control | no-preview |
| diff-view | unified |
| go-import | github.com/nodejs/node git https://github.com/nodejs/node.git |
| octolytics-dimension-user_id | 9950313 |
| octolytics-dimension-user_login | nodejs |
| octolytics-dimension-repository_id | 27193779 |
| octolytics-dimension-repository_nwo | nodejs/node |
| octolytics-dimension-repository_public | true |
| octolytics-dimension-repository_is_fork | false |
| octolytics-dimension-repository_network_root_id | 27193779 |
| octolytics-dimension-repository_network_root_nwo | nodejs/node |
| turbo-body-classes | logged-out env-production page-responsive full-width |
| disable-turbo | true |
| browser-stats-url | https://api.github.com/_private/browser/stats |
| browser-errors-url | https://api.github.com/_private/browser/errors |
| release | 14099438da5379150f15a2892474c7c7e6c0e55e |
| ui-target | full |
| theme-color | #1e2327 |
| color-scheme | light dark |
Links:
Viewport: width=device-width