Skip to content

Fix feature flag defaults#4265

Merged
fisx merged 12 commits intodevelopfrom
flag-defaults
Sep 30, 2024
Merged

Fix feature flag defaults#4265
fisx merged 12 commits intodevelopfrom
flag-defaults

Conversation

@pcapriotti
Copy link
Contributor

@pcapriotti pcapriotti commented Sep 23, 2024

This fixes the way the DbFeature is computed for mlsMigration and enforceFileDownloadLocation. Before, we were using a null cassandra value to represent both the absence of configuration and the presence of a Nothing value. The consequence was that the default would be accidentally overwritten by the Nothing value in some cases.

The fix is to use an explicit "null" value to represent Nothing. For dates, we use the POSIX timestamp origin. For the download location, we use an empty string.

Also, this PR contains a refactoring and reorganization of the test module for feature flags. It has been split into several modules, one per feature, and the various utilities have been simplified and made more uniform across features.

https://wearezeta.atlassian.net/browse/WPB-11100

Checklist

  • Add a new entry in an appropriate subdirectory of changelog.d
  • Read and follow the PR guidelines

Since an empty download location is now disallowed, we use the empty
string as a value that signifies "no download location" in the database.
@echoes-hq echoes-hq bot added echoes: unplanned Any work item that isn’t part of the product or technical roadmap. echoes/initiative: federation-and-mls-on-wire-c... Activate Federation with MLS on Wire Cloud labels Sep 23, 2024
@zebot zebot added the ok-to-test Approved for running tests in CI, overrides not-ok-to-test if both labels exist label Sep 23, 2024
@pcapriotti pcapriotti force-pushed the flag-defaults branch 2 times, most recently from deae2a1 to 1c9418b Compare September 26, 2024 14:23
@pcapriotti pcapriotti marked this pull request as ready for review September 27, 2024 07:32
@fisx fisx self-requested a review September 28, 2024 13:13
Co-authored-by: Matthias Fischmann <mf@zerobuzz.net>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

echoes/initiative: federation-and-mls-on-wire-c... Activate Federation with MLS on Wire Cloud echoes: unplanned Any work item that isn’t part of the product or technical roadmap. ok-to-test Approved for running tests in CI, overrides not-ok-to-test if both labels exist

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants