Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Waits for the manifests to be written before running the second loops #5871

Merged
merged 2 commits into from
Oct 26, 2023

Conversation

arcanis
Copy link
Member

@arcanis arcanis commented Oct 25, 2023

What's the problem this PR addresses?

I forgot to add a Promise.all, so the package.json files could end up corrupted when the constraints engine had to perform multiple iterations of the loop.

Fixes #5853

How did you fix it?

Adds Promise.all before running subsequent iterations.

Checklist

  • I have set the packages that need to be released for my changes to be effective.
  • I will check that all automated PR checks pass before the PR gets reviewed.

@merceyz
Copy link
Member

merceyz commented Oct 25, 2023

Do we have any tests that could possibly hit this? If we don't, could you add one?

@arcanis
Copy link
Member Author

arcanis commented Oct 25, 2023

Since it involves parallel/sequential execution, I don't think I can write one that will fail 100% of the time.

@merceyz
Copy link
Member

merceyz commented Oct 25, 2023

That's fine and also why I wrote "possibly hit this", a small chance of catching a regression is better than none at all.

@arcanis arcanis merged commit 2ded191 into master Oct 26, 2023
15 checks passed
@arcanis arcanis deleted the mael/constraints-fix-await branch October 26, 2023 09:48
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

[Bug?]: yarn constraints --fix leads to malformed package.jsons
2 participants