Skip to content

Safety for Fluent string dependencies #1626

@jonathanolson

Description

@jonathanolson

I noted in slack to @jessegreenberg that fluent strings being able to depend on others can create a problem for common strings (or even... sim-specific strings between release branches):

Case 1:

  • Sim Y is published (common code repo has string A)
  • Common code introduces string B
  • Sim X is published (common code repo has string A and string B)
  • Translator translates sim X (having string A refer to string B, since they are in the same repo and both available in sim X) - that sim works.
  • Something causes rebuild of sim Y --- it breaks! (string A refers to string B, which doesn't exist in its release branch). Presumably hard build failure.

Case 2:

  • Sim Y is published (strings A and B exist, but sim Y ONLY uses string A)
  • Sim X is published (uses both strings)
  • Translator translates sim X (having string A refer to string B, since they are in the same repo and both available in sim X) - that sim works.
  • Something causes rebuild of sim Y --- it potentially builds but without string B in the runtime, meaning it gets deployed, and now sim Y is runtime-broken because string A refers to string B which wouldn't be included.

As part of scenerystack/scenerystack#55, I'm not yet handling the string dependencies, but it would be similar.

I believe essentially each build would need to run fluent dependency tracking for every locale (instead of just English, as is done now), to create the set of strings that will be included.

Once this is a bit more figured out, I'll need to adjust SceneryStack to run this (and to include dependencies in every FluentConstant/FluentPattern).

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions