Skip to content

Commit 89e01c1

Browse files
gipertclaude
andcommitted
fix(processing-chain): cast processors to plain dict at entry
build_processing_chain stored values via 'processors[key] = node'. When processors is a dbetto AttrsDict (which CLI configs are, after Props.read_from), __setitem__ wraps any plain dict in a fresh AttrsDict via __init__'s copy loop, decoupling the stored entry from the local reference. Later in-place mutations like node["prereqs"] = ... then never reached the entry in processors[key], so resolve_dependencies failed with KeyError: 'prereqs'. Cast processors to a plain dict once at the top of the function so all subsequent assignments behave normally, regardless of the input type. Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
1 parent d57a1e7 commit 89e01c1

1 file changed

Lines changed: 6 additions & 0 deletions

File tree

src/dspeed/processing_chain.py

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2372,6 +2372,12 @@ def build_processing_chain(
23722372
if "processors" in processors:
23732373
processors = processors["processors"]
23742374

2375+
# cast to a plain dict so that subsequent processors[key] = ... does not
2376+
# go through wrapping __setitem__ overrides (e.g. dbetto.AttrsDict copies
2377+
# plain dicts into fresh AttrsDicts on assignment, which would silently
2378+
# decouple the stored value from any local reference)
2379+
processors = dict(processors)
2380+
23752381
buffer_len = len(tb_in) if tb_in is not None else 1
23762382
proc_chain = ProcessingChain(block_width, buffer_len)
23772383

0 commit comments

Comments
 (0)