Skip to content

Add Request Blocklist case for a valid rule with missing reason#155

Merged
kzar merged 1 commit intoduckduckgo:mainfrom
kzar:request-blocklist-reason
Dec 19, 2025
Merged

Add Request Blocklist case for a valid rule with missing reason#155
kzar merged 1 commit intoduckduckgo:mainfrom
kzar:request-blocklist-reason

Conversation

@kzar
Copy link
Collaborator

@kzar kzar commented Dec 19, 2025

In the future, we might strip the "reason" field if the configuration becomes
too large, we should ensure implementations will still consider rules as valid
if we do.


Note

Add config example and test to validate that rules without a reason are still considered valid and block requests.

  • Request Blocklist:
    • Config Reference: Add rule in request-blocklist/config-reference.json for request-blocklist.example/missing-reason with domains: ["<all>"] (no reason).
    • Tests: Add test in request-blocklist/tests.json asserting requests to /missing-reason are blocked (expectAction: "block").

Written by Cursor Bugbot for commit 9a227f8. This will update automatically on new commits. Configure here.

In the future, we might strip the "reason" field if the configuration becomes
too large, we should ensure implementations will still consider rules as valid
if we do.
@kzar kzar merged commit c2b49fe into duckduckgo:main Dec 19, 2025
3 of 5 checks 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