feat(nimbus) - Add targeting for TOU accepted before Dec 9, 2025#13805
Merged
feat(nimbus) - Add targeting for TOU accepted before Dec 9, 2025#13805
Conversation
7335828 to
c48f08a
Compare
mimizillaa
reviewed
Oct 29, 2025
mimizillaa
reviewed
Oct 29, 2025
c48f08a to
aadcd9d
Compare
Contributor
Author
|
Nov 12 date isn't final, so updated patch with TODOs until that's solidified. |
aadcd9d to
a3b42f6
Compare
lmegviar
commented
Nov 14, 2025
| ), | ||
| targeting=f""" | ||
| ( | ||
| !os.isLinux |
Contributor
Author
There was a problem hiding this comment.
We only want to exclude Linux in the "before dec 9" targeting and not in the "on or after dec 9" targeting.
c9e80cb to
213c1cc
Compare
freshstrangemusic
approved these changes
Nov 14, 2025
freshstrangemusic
previously requested changes
Nov 14, 2025
887713e to
0907acb
Compare
Contributor
Author
|
Thanks, @freshstrangemusic - updated. |
Stray comma removed
Collaborator
|
@lmegviar Ah looks like some JEXL validation errors: self = <Sequence expression = _ (conditional_expression / binary_expression / unary_expression / complex_value) _>
text = "\n (\n !os.isLinux\n &&\n ('termsofuse.acceptedDate'|preferenceValue != '0')\n &&\n ((('termsofuse.acceptedDate'|preferenceValue * 1) | date) < 1765324740000|date)\n )\n "
pos = 0
def match(self, text, pos=0):
"""Return the parse tree matching this expression at the given
position, not necessarily extending all the way to the end of ``text``.
Raise ``ParseError`` if there is no match there.
:arg pos: The index at which to start matching
"""
error = ParseError(text)
node = self.match_core(text, pos, defaultdict(dict), error)
if node is None:
> raise error
E parsimonious.exceptions.ParseError: Rule 'binary_operator' didn't match at '| date) < 1765324740' (line 7, column 59).
/usr/local/lib/python3.13/site-packages/parsimonious/expressions.py:158: ParseError
--------
self = <experimenter.targeting.tests.test_targeting_configs.TestTargetingConfigs testMethod=test_targeting_config_has_valid_jexl_227>
targeting_config = NimbusTargetingConfig(name='Accepted TOU on or after Dec 9, 2025', slug='accepted_tou_on_or_after_dec_9_2025', description='User accepted TOU on or after Dec 9, 2025', targeting="\n (\n ('termsofuse.acceptedDate'|preferenceValue != '0')\n &&\n ((('termsofuse.acceptedDate'|preferenceValue * 1) | date) >= 1765324740000|date)\n )\n ", desktop_telemetry='', sticky_required=False, is_first_run_required=False, application_choice_names=('DESKTOP',))
@parameterized.expand([(t,) for t in TargetingConstants.TARGETING_CONFIGS.values()])
def test_targeting_config_has_valid_jexl(self, targeting_config):
if targeting_config.targeting:
try:
JEXLParser().parse(targeting_config.targeting)
except ParseError as e:
> raise Exception(
f"JEXL Parse error in {targeting_config.name}: {e}"
) from e
E Exception: JEXL Parse error in Accepted TOU on or after Dec 9, 2025: Rule 'binary_operator' didn't match at '| date) >= 176532474' (line 5, column 59).
experimenter/targeting/tests/test_targeting_configs.py:24: Exception |
255d31d to
db19e0a
Compare
Contributor
Author
Thanks @jaredlockhart - I think they're addressed, I still see two CircleCI failures but they seem unrelated (I think you mentioned there are a couple that can be flaky and I don't have permission to get them to rerun). |
6d6bb61 to
93f1c42
Compare
f502ced to
712dad2
Compare
712dad2 to
60490b0
Compare
github-merge-queue bot
pushed a commit
that referenced
this pull request
Nov 18, 2025
) Because - We need to show a message to users who accepted the TOU before Dec 9, 2025 alerting them to a privacy notice update. This commit - Add this new targeting and comment explaining the way we'll determine accepted variant of TOU moving forward. Fixes #13804
3d3141f to
60490b0
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Because
This commit
Fixes #13804