chore(deps): Bump openjd-* Rust crates to 0.8.0 - #365
Merged
leongdl merged 1 commit intoSep 16, 2026
Merged
Conversation
openjd-expr 0.7.0 -> 0.8.0, openjd-model 0.7.1 -> 0.8.0, and
openjd-sessions 0.5.8 -> 0.6.0 (openjd-rs release PR #395).
Six upstream changes land, reconciled against a source diff of the
published crates. The only new public API is two methods on
openjd_expr::FormatString, segment_count and literal_segments, which
the model crate's validator uses (#383). Both are now exposed on
openjd.expr.FormatString, with the stub and specs/python-expr-interface.md
updated. openjd-model and openjd-sessions have no public signature
changes; the two [breaking] changelog entries are behavioural.
Each change exercised through this package's API, v1 and v0 side by
side where both apply:
* openjd-rs#396 type-checks an `in`/`not in` item against the list's
element type. `'a' in [1, 2]` now raises where it returned False.
Int/float and path/string coercion kept; `x in []` is False for any x.
* openjd-rs#383 checks resolved-value constraints at template
validation. A job name resolving to 129 characters, and a chunks
defaultTaskCount naming an undeclared parameter, are now rejected at
decode. v0 already rejected both. The whole-field chunks expression
is resolved with target type int, so a STRING value fails inside the
evaluator: test_chunk_default_task_count_invalid_int's message match
moves from "not a valid integer" to "Cannot convert ... to int"; the
exception class it pins is unchanged.
* openjd-rs#397: a single-valued allOf with one literal and one
whole-field expression is now accepted at validation (0.7.1 rejected
it) because the expression can null-skip, and job creation re-checks
the resolved count. A control character in a resolved job name is
rejected at create_job; 0.7.1 produced the job.
* openjd-rs#398 renders NONCONTIGUOUS chunks like the v0 reference:
[1,2,4,6] is "1,2,4,6", not "1,2-6:2". Both paths agree on all four
probed shapes.
* openjd-rs#384: preprocess_job_parameters accepts its own output for a
LIST[PATH] parameter defaulting to []. 0.7.1 refused the second pass.
* openjd-rs#359 rejects embedded filenames ".", ".." and any containing
a null byte at template validation. v0 accepts all three. The
sessions-side check for Windows drive anchors ("C:", "D:relative") is
not reachable from this repo's tests: the model layer accepts them
and the check is Windows-only.
One test template was invalid and passed only because 0.7.1 did not
validate chunk fields: test_chunks_with_format_string_default_task_count
now declares the parameter it references.
Old-pins mutant: with the three pins reverted and the two new bindings
removed, 30 tests fail, all in the new or updated classes, and the
whole-field allOf deferral was measured as rejected on 0.7.1. Two new
cases (a tab in a literal run of an interpolated name, two certain
allOf elements) were already rejected on 0.7.1 and are labelled
controls.
THIRD-PARTY-LICENSES.txt regenerated; only the three crate versions
changed. Cargo.lock moved only those three packages.
Signed-off-by: David Leong <116610336+leongdl@users.noreply.github.com>
seant-aws
approved these changes
Sep 16, 2026
wyongzhi
approved these changes
Sep 16, 2026
Merged
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Fixes: n/a (dependency bump for OpenJobDescription/openjd-rs#395)
What was the problem/requirement? (What/Why)
openjd-rs published a release on 2026-09-15: openjd-expr 0.8.0, openjd-model 0.8.0, openjd-sessions 0.6.0. This package pinned 0.7.0 / 0.7.1 / 0.5.8. The release carries six fixes, two of them tagged breaking in the changelog.
What was the solution? (How)
Bump the three pins in
rust-bindings/Cargo.toml.Cargo.lockmoved only those three packages;THIRD-PARTY-LICENSES.txtregenerated with only the three version lines changing.Public API. A source diff of the published crates and of upstream's
specs/*/public-api.mdshows one addition:openjd_expr::FormatString::segment_count()andliteral_segments(), added by openjd-rs#383 for the model validator. Both are now exposed onopenjd.expr.FormatString, with the.pyistub andspecs/python-expr-interface.mdupdated. openjd-model and openjd-sessions have no public signature changes, so the bindings built with no edits. The two[breaking]tags (#396, #383) are behavioural, not API.Behaviour changes, each exercised through this package's API (v1 and the v0 reference side by side where both apply):
openjd.expr.evaluate_expression'a' in [1, 2]isFalseExpressionErrordecode_job_templatedefaultTaskCountnaming an undeclared parameter acceptedintcreate_job"not a valid integer""Cannot convert 'not-an-integer' to int", sameExpressionErrorclassallOfelement deferreddecode_job_template+create_job["linux", "{{Param.X}}"]rejected at decodeX="windows", acceptsXresolving tonullcreate_jobrender-a\nbDecodeValidationErrorStepParameterSpaceIterator[1,2,4,6]renders1,2-6:21,2,4,61,2,4,6(agrees on all 4 probed shapes)LIST[PATH]round-trippreprocess_job_parameterscreate_jobaccepts.,.., NULdecode_job_templateNot reachable from this repo's tests: the openjd-sessions half of #359 (Windows drive-relative anchors
C:,D:relative). The model layer accepts those strings and the sessions check is Windows-only. Coverage lives in openjd-rs.What is the impact of this change?
Two existing v1 tests changed:
test_chunks_with_format_string_default_task_countused a template referencingParam.ChunkSizewithout declaring it. It passed only because 0.7.1 did not validate chunk fields; the v0 reference rejects that template. It now declares the parameter, and a new test pins the rejection.test_chunk_default_task_count_invalid_intpins the exception class, which is unchanged; its message regex moves to the evaluator's coercion message.No other test changed. Nothing regressed.
How was this change tested?
hatch run test: 6058 passed, 24 skipped, 3 xfailed (pre-existing, unrelated), coverage 94.14%.hatch run lint(ruff, black, mypy) clean.cargo fmt --checkandcargo clippy -p openjd-python --all-targets -- -D warningsclean.New tests:
TestListMembershipElementTypeCheck(cases copied from upstreamtest_comparison.rs),TestEmbeddedFileFilenameIsASinglePathComponent,TestResolvedValueConstraintsAtTemplateValidation,TestPreprocessAcceptsItsOwnEmptyListPath,TestResolvedJobNameControlCharacters,TestDeferredSingleValuedAllOfIsRecheckedAtJobCreation,TestNoncontiguousChunkRendering, plussegment_count/literal_segmentscases inTestFormatString.Mutation check: with the three pins reverted to 0.7.0 / 0.7.1 / 0.5.8 (and the two new bindings removed so the crate compiles), 30 tests fail, all in the new or updated classes. The whole-field
allOfdeferral was measured as rejected on 0.7.1 by probe. Two new cases were already rejected on 0.7.1 and are labelled as controls in their docstrings: a tab in a literal run of an interpolated job name, and two certainallOfelements. The two new binding methods were also mutated independently (wrongsegment_countshape,literal_segmentsreturning the raw text); each mutant fails 3 tests.Was this change documented?
Yes: docstrings on the two new bindings, the
.pyistub, andspecs/python-expr-interface.md. Every new test docstring states what 0.7.1 did with the same input and cites the spec section where one applies.Is this a breaking change?
No public contract of this package changes. Callers see stricter validation from openjd-model 0.8.0 on templates that were invalid per the spec (see table). One message string changes for a non-integer
defaultTaskCount.Does this change impact security?
No.
By submitting this pull request, I confirm that you can use, modify, copy, and redistribute this contribution, under the terms of your choice.