Force-disable flag in experiments via cookies#6701
Merged
dvoytenko merged 2 commits intoampproject:masterfrom Dec 15, 2016
Merged
Force-disable flag in experiments via cookies#6701dvoytenko merged 2 commits intoampproject:masterfrom
dvoytenko merged 2 commits intoampproject:masterfrom
Conversation
lannka
reviewed
Dec 15, 2016
| const experiments = getExperimentIds(win); | ||
|
|
||
| // Disabling cookie flag. | ||
| const disableFlag = experiments.indexOf('-' + experimentId) != -1; |
Contributor
There was a problem hiding this comment.
so this is for browser to manually opt-out?
Contributor
Author
There was a problem hiding this comment.
This is for a developer to manually opt-out. Basically, "We just launched feature X. Our binary config as X:1". There's no way in this scenario to override X back to 0 manually w/o redeployment. This is useful when you want to check if indeed the launch caused the problem or not.
Contributor
There was a problem hiding this comment.
Using AMP.toggleExperiment('xxx', false) can manually opt-out for the current page view. I guess that's not enough for your use case? You want it to be persistent?
Contributor
Author
There was a problem hiding this comment.
Currently it doesn't. It doesn't disable, but removes from enabled :)
erwinmombay
approved these changes
Dec 15, 2016
lannka
approved these changes
Dec 15, 2016
| const experiments = getExperimentIds(win); | ||
|
|
||
| // Disabling cookie flag. | ||
| const disableFlag = experiments.indexOf('-' + experimentId) != -1; |
Lith
pushed a commit
to Lith/amphtml
that referenced
this pull request
Dec 22, 2016
* Force-disable flag in experiments via cookies * minus prefix
Lith
pushed a commit
to Lith/amphtml
that referenced
this pull request
Dec 22, 2016
* Force-disable flag in experiments via cookies * minus prefix
torch2424
pushed a commit
to torch2424/amphtml
that referenced
this pull request
Jan 3, 2017
* Force-disable flag in experiments via cookies * minus prefix
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.
No description provided.