Skip to content

Harden parser input validation and stream resource contracts - #166

Merged
Ismail-elkorchi merged 3 commits into
mainfrom
fix/validated-input-lifecycles
Jul 21, 2026
Merged

Harden parser input validation and stream resource contracts#166
Ismail-elkorchi merged 3 commits into
mainfrom
fix/validated-input-lifecycles

Conversation

@Ismail-elkorchi

Copy link
Copy Markdown
Owner

Summary

  • validate caller-built trees and traversal arguments before work, including graph ownership, namespaces, names, attributes, templates, and cycles
  • separate mandatory BOM detection from optional meta prescanning, commit stream decoding when encoding evidence is final, and avoid retaining decoded byte input unless requested
  • return deterministic resource evidence for eager tokenization and fragment parsing, including enforceable step budgets
  • make registry audits fail closed, retain reviewed per-case browser differences, and qualify Node, Deno, and Bun agreement on Linux, macOS, and Windows

Breaking changes

  • parseFragment() returns a result containing tree and metadata
  • tokenizeByteStreamEager() returns a result containing tokens and metadata
  • malformed caller-built node graphs and invalid query arguments now fail with HtmlConfigurationError

No deprecated overloads or compatibility paths are retained.

Validation

  • npm run qualification:release
  • 202 behavior/tooling tests and 89 engine tests
  • 3,828 WPT tree executions and 6,998 tokenizer fixtures
  • 1,724 document cases across Chromium, Firefox, and WebKit
  • 600 fuzz runs and 113/113 mutation kills
  • package, supply-chain, resource, performance, and Node/Deno/Bun agreement gates

@Ismail-elkorchi
Ismail-elkorchi merged commit 4c4d711 into main Jul 21, 2026
11 checks passed
@Ismail-elkorchi
Ismail-elkorchi deleted the fix/validated-input-lifecycles branch July 21, 2026 22:58
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant