turborepo
82ea25fe - feat: Refuse version expressions outside the bundled vocabulary (#15133)

Commit
1 day ago
feat: Refuse version expressions outside the bundled vocabulary (#15133) ### Description Part 5 of 8. This stack replaces #15127. The recipe reader evaluates `version_constraint` with an expression language. That language builds a range such as `0..99999999999` in memory, and nested `any` calls take time that grows exponentially with their depth. - A `version_constraint` can use only the words and operators that the bundled registry uses, within 512 bytes and a nesting depth of 16. - A `version_filter` can use a few more words, because `turbo` never evaluates it. A test loads the bundled registry through the check. A catalog refresh that needs a new word fails that test, and not a user's machine. ### Testing Instructions CI runs the Rust tests only for a PR whose base is `main`, so I ran `cargo lint`, the crate tests, and the setup tests on this branch locally. All pass. I built this branch and ran the 25 real-download checks from #15124 on macOS arm64 (jq, ripgrep, protoc, kustomize, and gh resolve, install, and run). All pass.
Author
Parents
Loading