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

release slang features to 1% of users #556

Merged
merged 1 commit into from
Apr 18, 2024

Conversation

OmarTawfik
Copy link
Contributor

No description provided.

OmarTawfik added a commit that referenced this pull request Apr 18, 2024
Just preparing this, in case anything goes wrong with the #556 release.
},

"semanticHighlighting": {
"percent": 0
"percent": 0.01
Copy link
Member

Choose a reason for hiding this comment

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

Can I just double check. The percentage is expressed as a decimal rather than an integer?

Copy link
Contributor

Choose a reason for hiding this comment

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

Yep, it's basically parseInt("2 random bytes", 16) / 65536 (in 0-1 range) and that's checked against these flag values:

const numberDigest = parseInt(digest, 16);
const percentile = numberDigest / 65536;
const enabled = percentile < flag.percent;

@Xanewok Xanewok merged commit 8a34201 into development Apr 18, 2024
7 checks passed
@Xanewok Xanewok deleted the slang-release-one-percent branch April 18, 2024 08:50
@Xanewok
Copy link
Contributor

Xanewok commented Apr 18, 2024

Like I mentioned, I'll merge this and keep a look on the metrics to see if we encounter any sort of problems.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
Status: Done
Development

Successfully merging this pull request may close these issues.

None yet

3 participants