Skip to content

refactor(spine): to_task_kwargs boundary key is 'task' not 'task_name' - #68

Merged
larsrollik merged 1 commit into
mainfrom
refactor/to-task-kwargs-boundary-key
Aug 10, 2026
Merged

refactor(spine): to_task_kwargs boundary key is 'task' not 'task_name'#68
larsrollik merged 1 commit into
mainfrom
refactor/to-task-kwargs-boundary-key

Conversation

@larsrollik

Copy link
Copy Markdown
Member

to_task_kwargs() is the frozen boundary projection RunContext will hand tasks (the linchpin of retiring the dict). But it emitted "task_name" while the actual contract key — the TaskProcess constructor param and what every task reads — is "task". Switching the boundary onto to_task_kwargs() (a later phase) would have silently handed tasks the wrong key; the new boundary characterization test (#66) would have caught it.

  • Fix the projection to emit "task".
  • Pin it: to_task_kwargs() keys must be a faithful subset of the resolved args_dict (never invent a key tasks don't read).

No runtime effect yet — to_task_kwargs() is not called at the boundary until a later phase.

to_task_kwargs() is the frozen boundary projection RunContext will hand tasks,
but it emitted 'task_name' while the actual contract key - the TaskProcess
constructor param and what every task reads - is 'task'. Switching the boundary
onto to_task_kwargs() would have handed tasks the wrong key. Fix the projection
and pin it with a test that its keys are a faithful subset of the resolved
args_dict. No runtime effect yet (to_task_kwargs is not called at the boundary
until a later phase).
@larsrollik
larsrollik requested a review from a team as a code owner August 10, 2026 20:11
@larsrollik
larsrollik merged commit 2908376 into main Aug 10, 2026
7 checks passed
@larsrollik
larsrollik deleted the refactor/to-task-kwargs-boundary-key branch August 10, 2026 20:14
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