Skip to content

Force deterministic order for 'outdated' command - #681

Merged
joshspicer merged 1 commit into
mainfrom
joshspicer/deterministic-order-outdated
Nov 14, 2023
Merged

joshspicer merged 1 commit into
mainfrom
joshspicer/deterministic-order-outdated

Conversation

@joshspicer

@joshspicer joshspicer commented Nov 14, 2023 •

Copy link
Copy Markdown
Contributor

Currently the position of each Feature in the outdated command is non-deterministic due to the Promise.all. This isn't too big a deal for a user, but it's more intuitive to have the output be consistent between runs.

It's also a generally helpful assumption that the positions will are consistent (ie: writing units tests, which is how I noticed this).

This change mirrors the position of each Feature in the config (the input) before outputting.

@joshspicer
joshspicer requested a review from a team as a code owner November 14, 2023 01:50

@chrmarti Christof Marti (chrmarti) left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Makes sense, thanks!

@joshspicer
joshspicer merged commit 53ee019 into main Nov 14, 2023
@joshspicer
joshspicer deleted the joshspicer/deterministic-order-outdated branch November 14, 2023 13:39
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

2 participants