-
-
Notifications
You must be signed in to change notification settings - Fork 5.7k
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
Fix flaky @babel/cli test #14385
Fix flaky @babel/cli test #14385
Conversation
Build successful! You can test your changes in the REPL here: https://babeljs.io/repl/build/51553/ |
I love this PR |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This might still not solve it because it just "waits more", but 2s should be more then enough 👍
- name: 'Check for unmet constraints (fix w/ "yarn constraints --fix")' | ||
run: | | ||
yarn constraints | ||
- name: 'Check for duplicate dependencies (fix w/ "yarn dedupe")' | ||
if: steps.yarn-cache.outputs.cache-hit != 'true' |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We do we always run it now?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Good catch. I should have left a comment here. This step was previously in the prepare-yarn-cache
job including the step yarn-cache
. Not long ago it was extracted to a separate job yarn-validate
which can't access the yarn-cache
output anymore, so the condition here is always true
now. The dedupe check is around 2 seconds so we can just leave it here.
I'm merging this with a single review because it doesn't affect any source code, and it fixes a super annoying problem that makes ~30% of CI runs fail. |
There seems to be a failure for the same reason. We can consider adding a watch ready output. Or consider the following changes: await new Promise(resolve => setTimeout(resolve, 2000));
fs.writeFileSync("./file.txt", "Updated!"); let i = 0;
setInterval(() => {
fs.writeFileSync("./file.txt", `Updated${i++}!`);
}, 300); |
@babel/cli
watch test is flaky because lack of inter-process communicationTo re-run the
@babel/cli
test again and again, I have pushed some CI maintenance commits.