Skip to content

Cap FileProcessor fixed-point loop at 5 iterations - #8715

Merged
TomasVotruba merged 1 commit into
mainfrom
tv-fileprocessor-iteration-cap
Oct 19, 2026
Merged

TomasVotruba merged 1 commit into
mainfrom
tv-fileprocessor-iteration-cap

Conversation

@TomasVotruba

@TomasVotruba TomasVotruba commented Oct 19, 2026 •

Copy link
Copy Markdown
Member

The rule do-while loop in FileProcessor runs until a file stops changing. Add a safety cap so a rule that keeps changing the same node cannot loop forever: in tests it throws (a rule bug must surface), in normal runs it returns a SystemError for that file.

A well-behaved rule set settles within a couple of passes, so 5 leaves clear headroom while still catching a runaway loop early.

@TomasVotruba
TomasVotruba force-pushed the tv-fileprocessor-iteration-cap branch 3 times, most recently from 8bace8f to f2047cc Compare October 19, 2026 20:14
@TomasVotruba TomasVotruba changed the title Cap FileProcessor fixed-point loop at 10 iterations Cap FileProcessor fixed-point loop at 5 iterations Oct 19, 2026
Guard the rule do-while loop so a non-idempotent rule cannot loop forever; stop after 5 passes and surface it (throw in tests, SystemError otherwise).
@TomasVotruba
TomasVotruba force-pushed the tv-fileprocessor-iteration-cap branch from f2047cc to fa18276 Compare October 19, 2026 20:40
@TomasVotruba
TomasVotruba merged commit 86311b5 into main Oct 19, 2026
49 checks passed
@TomasVotruba
TomasVotruba deleted the tv-fileprocessor-iteration-cap branch October 19, 2026 20:44
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Development

Successfully merging this pull request may close these issues.

1 participant