[No QA] Make schema validations async#9814
Conversation
aldo-expensify
left a comment
There was a problem hiding this comment.
Cool update, it runs much faster, but I think there is something to correct.
The exit code is wrong sometimes... if you only remove the "on" and "name" of cla.yml, you can see it detects the invalid file, but the exit code is 0. If you do this same change in main, the exit code is 1.
If I mess up even more the file, like removing the jobs key without removing the descendants, then I get an exit code 1
|
Thanks for testing |
|
This is updated now, seems to work as expected |
| for PID in ${ASYNC_PROCESSES[*]}; do | ||
| if ! wait $PID; then | ||
| EXIT_CODE=$? | ||
| wait $PID | ||
| RESULT=$? | ||
| if [[ $RESULT != 0 ]]; then | ||
| EXIT_CODE=$RESULT | ||
| fi | ||
| done |
There was a problem hiding this comment.
I think this is what fixed the bug, right?
There was a problem hiding this comment.
Yeah. When you have an if statement that in-and-of-itself is a command and so it changes the value of $?.
|
✋ This PR was not deployed to staging yet because QA is ongoing. It will be automatically deployed to staging after the next production release. |
|
This is working well |
|
🚀 Deployed to staging by @aldo-expensify in version: 1.1.83-1 🚀
|
|
🚀 Deployed to production by @chiragsalian in version: 1.1.84-13 🚀
|



Details
This is just a minor way to speed up PR checks.
Fixed Issues
$ n/a
Tests
npm inpm run gh-actions-validate. Verify that the script runs successfully.npm run gh-actions-validate. Verify that the script catches the error, reports it successfully, and exits with a non-zero status code.npm tun gh-actions-validate. Verify that the script catches the error, reports it successfully, and exists with a non-zero status code.