You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The list of imports are collected in a set() (I believe) and so their ordering is not stable. We should either sort them when emitting code or use a stable method of making them unique (e.g. a dict()). Having the code change every time it is regenerated makes for undesirable diff churn when generated code is checked into a repo and regularly regenerated as part of automated tooling.
The text was updated successfully, but these errors were encountered:
dbushong
changed the title
Generated code is not stable
Generated code import ordering is random
Feb 13, 2024
The list of imports are collected in a
set()
(I believe) and so their ordering is not stable. We should either sort them when emitting code or use a stable method of making them unique (e.g. adict()
). Having the code change every time it is regenerated makes for undesirable diff churn when generated code is checked into a repo and regularly regenerated as part of automated tooling.The text was updated successfully, but these errors were encountered: