Skip to content

Conversation

@ohall-m
Copy link

@ohall-m ohall-m commented Dec 8, 2025

This patch begins storing a PreviousGeckoPrefState on ExperimentEnrollment when it is of type EnrollmentStatus::Enrolled for managing the original value of gecko prefs used in an experiment.

It also introduces PreviousState::GeckoPref to hold Gecko original preference values for Gecko pref based experiments.

The public APIs it opens are registerPreviousGeckoPrefStates and getPreviousGeckoPrefState.

The goal of this patch is to appropriately store the original Gecko preference value to help when exiting an experiment.

Current idea is that it will be set similarly as unenrollForGeckoPref in this patch D257390, but for the positive case. Bug 2003370 will use this to properly consume these values when appropriate.

Pull Request checklist

  • Breaking changes: This PR follows our breaking change policy
    • This PR follows the breaking change policy:
      • This PR has no breaking API changes, or
      • There are corresponding PRs for our consumer applications that resolve the breaking changes and have been approved
  • Quality: This PR builds and tests run cleanly
    • Note:
      • For changes that need extra cross-platform testing, consider adding [ci full] to the PR title.
      • If this pull request includes a breaking change, consider cutting a new release after merging.
  • Tests: This PR includes thorough tests or an explanation of why it does not
  • Changelog: This PR includes a changelog entry in CHANGELOG.md or an explanation of why it does not need one
    • Any breaking changes to Swift or Kotlin binding APIs are noted explicitly
  • Dependencies: This PR follows our dependency management guidelines
    • Any new dependencies are accompanied by a summary of the due diligence applied in selecting them.

@ohall-m ohall-m force-pushed the 1997373 branch 5 times, most recently from ae5eaf6 to 181a21d Compare December 8, 2025 23:56
@ohall-m
Copy link
Author

ohall-m commented Dec 9, 2025

Hi @jeddai and @freshstrangemusic ,

Please take a look at this when you have a chance! I don't have the right repo access to request in the Reviewers panel.

@jeddai jeddai added nimbus Nimbus, the experimentation platform. rust Pull requests that update Rust code labels Dec 9, 2025
Copy link
Author

@ohall-m ohall-m left a comment

Choose a reason for hiding this comment

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

Thanks for all the thoughtful comments! Really appreciate all of the rust explanations especially.

I have a couple of ToDos I marked in the comments that I'm still working through. I'm submitting the comments on what has changed to help keep the changes organized for now.

@ohall-m
Copy link
Author

ohall-m commented Dec 10, 2025

First draft comments should be addressed now, thanks!

@mergify mergify bot dismissed freshstrangemusic’s stale review December 19, 2025 20:55

The pull request has been modified, dismissing previous reviews.

@ohall-m ohall-m marked this pull request as draft January 5, 2026 21:08
@ohall-m ohall-m force-pushed the 1997373 branch 2 times, most recently from e255f19 to 75aac28 Compare January 5, 2026 21:29
@ohall-m ohall-m marked this pull request as ready for review January 5, 2026 21:55
@ohall-m ohall-m force-pushed the 1997373 branch 2 times, most recently from 3aca4a2 to 0200d98 Compare January 6, 2026 19:03
@mergify
Copy link
Contributor

mergify bot commented Jan 7, 2026

⚠️ The sha of the head commit of this PR conflicts with #7135. Mergify cannot evaluate rules on this PR. ⚠️

…ation

This patch begins storing a `Vec<PreviousGeckoPrefState>` on `ExperimentEnrollment` when it is of type `EnrollmentStatus::Enrolled`
for managing the original value of gecko prefs used in an experiment.

The public APIs it opens are `registerPreviousGeckoPrefStates` and `getPreviousGeckoPrefStates`.
@ohall-m
Copy link
Author

ohall-m commented Jan 8, 2026

Thanks, updated!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

nimbus Nimbus, the experimentation platform. rust Pull requests that update Rust code

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants