Skip to content

Bug 2026043 - Require Option<T> for gecko-pref variables and require null defaults by default [ci full]#7296

Merged
freshstrangemusic merged 1 commit intomainfrom
freshstrangemusic/push-ltxnnkvwmxzr
Mar 30, 2026
Merged

Bug 2026043 - Require Option<T> for gecko-pref variables and require null defaults by default [ci full]#7296
freshstrangemusic merged 1 commit intomainfrom
freshstrangemusic/push-ltxnnkvwmxzr

Conversation

@freshstrangemusic
Copy link
Copy Markdown
Member

In bug 2020683 we made the default field mutually exclusive with gecko-pref. However, this lead to another error, namely that gecko-pref was only valid for string, integer, and boolean types and null is not a valid value for these types. This issue lead to a backout in bug 2025587.

This patch re-adds the requirement of null defaults for gecko-pref variables but also adds the requirement that these variables must be Option<T>, where T is a string, boolean, or integer.

These constraints can be overridden by supplying the --lax-gecko-pref-validation flag to the fml single-file, fml generate-experimenter, and fml validate commands. This will allow Experimenter to continue to ingest manifests without error.

Once the invalid manifest is ingested into Experimenter, we can manually edit the manifest to remove the invalid feature and eventually disable this validation mode.

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.

@freshstrangemusic freshstrangemusic force-pushed the freshstrangemusic/push-ltxnnkvwmxzr branch 3 times, most recently from 1a175bc to b331361 Compare March 27, 2026 23:51
@freshstrangemusic freshstrangemusic changed the title Bug 2026043 - Require Option<T> for gecko-pref variables and require null defaults by default Bug 2026043 - Require Option<T> for gecko-pref variables and require null defaults by default [ci full] Mar 30, 2026
@freshstrangemusic freshstrangemusic force-pushed the freshstrangemusic/push-ltxnnkvwmxzr branch 3 times, most recently from ce496d2 to 5e95ed5 Compare March 30, 2026 15:23
…null defaults by default

In bug 2020683 we made the default field mutually exclusive with
gecko-pref. However, this lead to another error, namely that gecko-pref
was only valid for string, integer, and boolean types and `null` is not
a valid value for these types. This issue lead to a backout in bug 2025587.

This patch re-adds the requirement of null defaults for gecko-pref
variables but also adds the requirement that these variables must be
`Option<T>`, where `T` is a string, boolean, or integer.

These constraints *can* be overridden by supplying the
`--lax-gecko-pref-validation` flag to the `fml single-file`,
`fml generate-experimenter`, and `fml validate` commands. This will
allow Experimenter to continue to ingest manifests without error.

Once the invalid manifest is ingested into Experimenter, we can manually
edit the manifest to remove the invalid feature and eventually disable
this validation mode.
@freshstrangemusic freshstrangemusic force-pushed the freshstrangemusic/push-ltxnnkvwmxzr branch from 5e95ed5 to 4a32756 Compare March 30, 2026 15:55
@freshstrangemusic freshstrangemusic added this pull request to the merge queue Mar 30, 2026
Merged via the queue into main with commit 3661a4e Mar 30, 2026
59 checks passed
@freshstrangemusic freshstrangemusic deleted the freshstrangemusic/push-ltxnnkvwmxzr branch March 30, 2026 17:52
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants