Open Bug 1889199 Opened 1 year ago Updated 9 months ago

Allow preferring specific TranslationModelRecord versions for local testing

Categories

(Firefox :: Translations, enhancement)

enhancement

Tracking

()

People

(Reporter: nordzilla, Unassigned)

References

(Blocks 1 open bug)

Details

Attachments

(2 obsolete files)

Description

When we release new versions of Translations models in Remote Settings, our algorithm automatically defaults to taking the maximum compatible version.

This makes it hard to test an older version in a side-by-side comparison once a newer model version is released, since the algorithm always chooses the highest record version.

We should implement an easy way for developers to specify a preferred model record version in order to do a side-by-side comparison once the version is released.


Steps to implement

Rework the getMaxVersionRecords() algorithm to check a pref for a preferred record version.


Tests to implement

Ensure all test cases pass for the existing algorithm.
Add new test cases that consider the preferred version.

Refactors the isBetterRecordVersion() function to take the
entire record, instead of just the version. This refactor
does not change any logic, but makes changes more
straightforward in the following patch.

Reworks the isBetterRecordVersion() function to check
a user preference for a preferred record version,
which developers can set explicitly in order to test
an older record version if desired.

Depends on D206400

Attachment #9394599 - Attachment description: WIP: Bug 1889199 - Refactor Translations isBetterRecordVersion → Bug 1889199 - Refactor Translations isBetterRecordVersion r=#translations-reviewers!
Attachment #9394600 - Attachment description: WIP: Bug 1889199 - Consider preferred translation model record versions → Bug 1889199 - Consider preferred translation model record versions r=#translations-reviewers!
Attachment #9394599 - Attachment is obsolete: true
Attachment #9394600 - Attachment is obsolete: true
Assignee: enordin → nobody
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: