Skip to content

Clear regex output variables - #256

Merged
thorinaboenke merged 3 commits into
ait-testbed:developmentfrom
thorinaboenke:fix_regex_output_varibles
Aug 25, 2026
Merged

Clear regex output variables#256
thorinaboenke merged 3 commits into
ait-testbed:developmentfrom
thorinaboenke:fix_regex_output_varibles

Conversation

@thorinaboenke

@thorinaboenke thorinaboenke commented Aug 24, 2026

Copy link
Copy Markdown
Contributor

Task

#255

Description

Fix

  • register_outputvars: on no-match, clear each declared output variable to '' before returning.
  • search no-match branch now routes through forge_and_register_variables(command.output, None) --> same clearing path.

Only the variables named in that command's own output: block are affected. No other variables in the VariableStore are touched

Tests
Updated findall/search no-match tests to expect the cleared '' value.

  • Added test_exec_cmd_search_no_match_clears_stale_value reproducing the loop scenario.

Checklist

  • This Pull-Request goes to the development branch.
  • I have successfully run prek locally.
  • I have added tests to cover my changes.
  • I have linked the issue-id to the task-description.
  • I have performed a self-review of my own code.

@thorinaboenke thorinaboenke changed the title Clear regex outout variables Clear regex output variables Aug 24, 2026
@thorinaboenke
thorinaboenke merged commit a3f17e8 into ait-testbed:development Aug 25, 2026
1 check passed
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.

2 participants