Skip to content

fix: clean matched vars after chained and non-chained rule #3418

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
wants to merge 2 commits into
base: v3/master
Choose a base branch
from

Conversation

airween
Copy link
Member

@airween airween commented Jul 14, 2025

what

This PR changes the code behavior: now the engine cleans the MATCHED_VAR* variables after chained and non-chained rules too.

why

Until now if there was a single (non-chained) rule, and if any of the MATCHED_VAR* variable were filled, then the next rule which used them accessed the filled value, even the rule does not use chain action.

references

See issue #3382.

This PR fixes #3382.

other notes

please see commit 5572ac0; I added this change because the first test on Windows was failed. It seems like the argument processing order is non-deterministic, at least it's different on Windows (see the log: the first argument is the last from the QUERY_STRING, and the tests were success on all other platforms).

Copy link

@airween
Copy link
Member Author

airween commented Jul 14, 2025

@mirkodziadzka-avi could you take a review on this?

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.

Semantic of MATCHED_VARS / MATCHED_VARS_NAMES
1 participant