normandy icon indicating copy to clipboard operation
normandy copied to clipboard

Filter Object: Sticky

Open jaredlockhart opened this issue 5 years ago • 0 comments

Stickyness is the idea that a client will match a certain set of criteria on first enrollment (the first time a recipe is evaluated by the Normandy Client), and a different set of criteria on subsequent evaluations by Normandy Client, so we call the recipe 'sticky'.

The theory is that the first clause matches on first enrollment, and the second clause matches on subsequent enrollments.

An example is here:

(
  !("trailhead.firstrun.didSeeAboutWelcome"|preferenceValue)
  || 
  normandy.studies.pref["pref-activity-stream-chrome-switchers-card-for-onboard-release-73-75-bug-1621101"]
)

The second clause, that the client is enrolled in the study, is automatically generated by the sticky filter object, so in this example it would take the first clause in as an argument and automatically wrap it with the second clause.

So very roughly, for each of the pref/addon study case:

sticky(A) -> (A || normandy.studies.pref["<pref study slug>"]) sticky(A) -> (A || normandy.studies.addon["<addon study slug>"])

The filter would need to figure out whether it's a pref or addon study by some means.

jaredlockhart avatar Mar 13 '20 22:03 jaredlockhart