Upgrade to cel-rust 0.14.5, refresh dependencies, bump CI actions - #42
Conversation
cel-rust 0.14.4/0.14.5 bring behaviour the wrapper must follow: - Reserved CEL words (var, let, if, ...) are rejected as identifiers at parse time. Tests that used `var` as a variable name are renamed, and the change is called out in the CHANGELOG as user-visible. - type() is native and returns a first-class type value, so the string-returning shim and the identity dyn() shim in cel.stdlib are removed; built-ins already took precedence over them. uint now reports "uint" and null "null_type". - int()/uint() reject out-of-range conversions with a FunctionError whose message ends in "overflow"; map those to OverflowError to match the existing arithmetic overflow mapping. Also moves dev deps to dependency-groups (tool.uv.dev-dependencies is deprecated), refreshes uv.lock and in-range crates, and bumps checkout, setup-python, upload/download-artifact and setup-uv to their current majors.
Codex Review SummaryThis comment shows the latest Codex review activity on this pull request.
ℹ️ About Codex in GitHubYour team has set up Codex to review pull requests in this repo. Reviews are triggered when you
Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings. |
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: 86dccb57b7
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
| "A function was called without a required argument or method target.", | ||
| ) | ||
| }, | ||
| ExecutionError::FunctionError { function, message } if message.ends_with("overflow") => { |
There was a problem hiding this comment.
Restrict overflow mapping to conversion built-ins
When a registered Python callback raises an exception whose message ends in overflow (for example, RuntimeError("buffer overflow")), build_environment wraps it as a FunctionError with a message that still ends in that word, so this guard incorrectly converts the callback failure into OverflowError instead of the usual RuntimeError. Limit this mapping to the native int/uint conversion functions or their exact known error messages.
Useful? React with 👍 / 👎.
There was a problem hiding this comment.
Confirmed with a callback raising RuntimeError("buffer overflow"): it came back as OverflowError. Fixed in db0e48a by matching the two exact upstream messages (int/"integer overflow", uint/"unsigned integer overflow") instead of the suffix, with a regression test for the callback case.
A Python callback raising an exception whose text ends in "overflow" was being reclassified as OverflowError by the suffix match. Match the two exact upstream messages instead, and pin the callback case with a test.
Why
cel-rust 0.14.4/0.14.5 change behaviour the wrapper has to follow, and the Python and Actions dependencies had drifted.
Upstream behaviour now reflected
var,let,if, ...). Spec-correct, but user-visible:var == "x"is now a parse-timeValueErroreven if the context definesvar. Tests that usedvarare renamed; a parametrised test pins all 17 words. Called out first in the CHANGELOG.type()is native and returns a first-class type value, sotype(1u) == uintandtype(null) == null_typework inside expressions. Upstream converts a type value to its name when returning it, so Python receives"int". The string-returningtype()and identitydyn()shims are removed fromcel.stdlib(built-ins already shadowed them). Visible differences:uintreports"uint"not"int",nullreports"null_type".int()/uint()reject out-of-range conversions. Mapped toOverflowError, matching the existing arithmetic overflow mapping.Dependencies
tool.uv.dev-dependencies→dependency-groups.dev(deprecation warning);uv.lockrefreshed (ruff 0.16.6 stays inside the 0.16 pin).Verification
cargo fmt --check,cargo clippy -D warnings,cargo test, pytest (510 passed, 1 skipped, 5 xfailed; was 482/6 xfailed), ruff format/check, mypy,typrobe, and the executed doc snippets all pass locally.