Repository navigation
Commit ffd4be3
committed
docs: Document the create_job step-let contract as breaking
Dropping the step-level `let` merge means the Job returned by plain
create_job() is no longer self-contained for an EXPR template whose step
declares a `let` its script references: at 6a23815 script.let was
['a = 1'] and the task succeeded; at 260b147 script.let is None and the
task fails with `Undefined variable: 'a'`.
The removal is correct -- both channels evaluating caused the clobber this
branch fixes -- so document the contract instead of adding a shim. Rewrite
create_job's docstring to say plainly that the Job does not carry
step-level `let` values and that a caller running such a job must use
create_job_with_symbol_tables and forward the tables, add a CHANGELOG
breaking-change entry, and add the same pointer to the README's
"Creating a Job from a Job Template" example.
The README's other two create_job() examples only inspect the Job at
creation time (StepDependencyGraph, StepParameterSpaceIterator), so
plain create_job stays correct there and they are left alone.
BREAKING CHANGE: create_job() no longer returns a Job carrying evaluated
step-level `let` values. A caller that runs a job whose steps declare a
template-scope `let` referenced from the step's script must switch to
create_job_with_symbol_tables and forward the step's step_symbol_tables
entry to the session.
Signed-off-by: David Leong <116610336+leongdl@users.noreply.github.com>1 parent 71dc2f1 commit ffd4be3
3 files changed
Lines changed: 39 additions & 4 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
| 1 | + | |
| 2 | + | |
| 3 | + | |
| 4 | + | |
| 5 | + | |
| 6 | + | |
| 7 | + | |
| 8 | + | |
| 9 | + | |
| 10 | + | |
| 11 | + | |
| 12 | + | |
| 13 | + | |
| 14 | + | |
1 | 15 | | |
2 | 16 | | |
3 | 17 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
211 | 211 | | |
212 | 212 | | |
213 | 213 | | |
| 214 | + | |
| 215 | + | |
| 216 | + | |
| 217 | + | |
| 218 | + | |
| 219 | + | |
| 220 | + | |
| 221 | + | |
| 222 | + | |
214 | 223 | | |
215 | 224 | | |
216 | 225 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
529 | 529 | | |
530 | 530 | | |
531 | 531 | | |
532 | | - | |
533 | | - | |
534 | | - | |
| 532 | + | |
| 533 | + | |
| 534 | + | |
| 535 | + | |
| 536 | + | |
| 537 | + | |
| 538 | + | |
| 539 | + | |
| 540 | + | |
| 541 | + | |
| 542 | + | |
| 543 | + | |
| 544 | + | |
| 545 | + | |
535 | 546 | | |
536 | 547 | | |
537 | 548 | | |
538 | 549 | | |
539 | 550 | | |
540 | | - | |
| 551 | + | |
| 552 | + | |
541 | 553 | | |
542 | 554 | | |
543 | 555 | | |
| |||
0 commit comments