Skip to content
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

Add support for soft/hard block in upload_to_mllf_to_remote_settings cron #22885

Merged
merged 6 commits into from
Nov 25, 2024

Conversation

KevinMind
Copy link
Contributor

@KevinMind KevinMind commented Nov 22, 2024

Relates to: mozilla/addons#15014

Description

  • adds support to process fort blocks in the cron
  • does not actually support soft blocks, we skip them always
  • adds test proving we always skip them

Context

This commit makes actually adding them more clear and easier to grok

Testing

Test exactly the same as #22828

Adding hard or soft blocks should produce only hard block filter/stash regardless of the soft block change count or the enable-soft-blocking waffle_switch.

Checklist

  • Add #ISSUENUM at the top of your PR to an existing open issue in the mozilla/addons repository.
  • Successfully verified the change locally.
  • The change is covered by automated tests, or otherwise indicated why doing so is unnecessary/impossible.
  • Add before and after screenshots (Only for changes that impact the UI).
  • Add or update relevant docs reflecting the changes made.

@KevinMind KevinMind changed the base branch from soft-block-bloom-filter-filter to master November 22, 2024 17:09
@KevinMind KevinMind changed the title Soft-block-cron-job Add support for soft/hard block in upload_to_mllf_to_remote_settings cron Nov 22, 2024
@KevinMind KevinMind force-pushed the soft-block-cron-job branch 2 times, most recently from 6884583 to 32b86be Compare November 22, 2024 17:35
@KevinMind KevinMind changed the base branch from master to soft-block-upload-task November 22, 2024 17:42
@KevinMind KevinMind marked this pull request as ready for review November 25, 2024 12:34
@KevinMind KevinMind force-pushed the soft-block-upload-task branch 2 times, most recently from 2488f60 to 9efc622 Compare November 25, 2024 14:33
Base automatically changed from soft-block-upload-task to master November 25, 2024 16:33
@KevinMind KevinMind force-pushed the soft-block-cron-job branch 2 times, most recently from 4b1719c to d8a5812 Compare November 25, 2024 16:43
…cron:

- adds support to process fort blocks in the cron
- does not actually support soft blocks, we skip them always
- adds test proving we always skip them

This commit makes actually adding them more clear and easier to grok
Copy link
Member

@willdurand willdurand left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Some preliminary (minor) feedback, this looks good.

src/olympia/blocklist/tests/test_tasks.py Show resolved Hide resolved
src/olympia/blocklist/tests/test_cron.py Outdated Show resolved Hide resolved
src/olympia/blocklist/tests/test_cron.py Outdated Show resolved Hide resolved
src/olympia/blocklist/tests/test_cron.py Outdated Show resolved Hide resolved
src/olympia/blocklist/tests/test_cron.py Show resolved Hide resolved
src/olympia/blocklist/cron.py Outdated Show resolved Hide resolved
src/olympia/blocklist/cron.py Outdated Show resolved Hide resolved
src/olympia/blocklist/cron.py Outdated Show resolved Hide resolved
src/olympia/blocklist/cron.py Outdated Show resolved Hide resolved
src/olympia/blocklist/cron.py Outdated Show resolved Hide resolved
Co-authored-by: William Durand <[email protected]>

Update src/olympia/blocklist/cron.py

Co-authored-by: William Durand <[email protected]>

Update src/olympia/blocklist/cron.py

Co-authored-by: William Durand <[email protected]>

Update src/olympia/blocklist/cron.py

Co-authored-by: William Durand <[email protected]>

Update src/olympia/blocklist/cron.py

Co-authored-by: William Durand <[email protected]>

Update src/olympia/blocklist/cron.py

Co-authored-by: William Durand <[email protected]>

Update src/olympia/blocklist/tests/test_cron.py

Co-authored-by: William Durand <[email protected]>
Copy link
Member

@willdurand willdurand left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

r+wc, thanks

This looks good, especially when we do not enable the soft-blocking switch, haha

src/olympia/blocklist/tests/test_cron.py Outdated Show resolved Hide resolved
@KevinMind KevinMind merged commit 6e44ecb into master Nov 25, 2024
31 checks passed
@KevinMind KevinMind deleted the soft-block-cron-job branch November 25, 2024 20:42
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