-
Notifications
You must be signed in to change notification settings - Fork 11
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
Support checking multiple requirements #54
base: main
Are you sure you want to change the base?
Conversation
5db798f
to
f61dd24
Compare
How will it handle |
This matches the |
@shizmob What is the status of this? |
Sorry, this issue completely dropped of my radar as I had to dedicate myself towards some other projects. Is there anything from your side that you'd like clarified or changed in this PR? |
Excellent, thanks. Can you merge whatever latest is needed and mark as ready for review? |
f61dd24
to
ffe9362
Compare
Done! I added another change to the requirements, as |
Going to hold off on this until after the LTS goes out. |
This patchset changes the router to be able to handle multiple requirements.
It does this by adding a small change to the matching core to iterate over the requirements instead of doing a direct match,
and by making a change to the group merging logic: instead of the presence of absence of requirements, it will check for a potential overlap in the keys being checked. If there is no overlap, there's a potential for ambiguous handlers, so we need to reject it.
As a side-effect, this also now allows the router to match situations like this:
Where
handler1
will be invoked ifa
is unset or not42
, andhandler2
if it is.