-
Notifications
You must be signed in to change notification settings - Fork 20
Fixing consumer test pipe #363
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
Fixing consumer test pipe #363
Conversation
The pipe into 'tee' has made it so only the exit code of the 'tee' action was recorded / interpreted by github. This meant that any fail inside the consumer test was ignored and it only failed if the 'tee' action would fail.
License Check Results🚀 The license check job ran with the Bazel command: bazel run //src:license-checkStatus: Click to expand output |
|
The created documentation from the pull request is available at: docu-html |
.github/workflows/consumer_test.yml
Outdated
| run: | | ||
| .venv_docs/bin/python -m pytest -s -v src/tests/ --repo="$CONSUMER" --junitxml="reports/${{ matrix.consumer }}.xml" | tee "reports/${{ matrix.consumer }}.log" | ||
| run: "set -o pipefail \n.venv_docs/bin/python -m pytest -s -v src/tests/ --repo=\"$CONSUMER\" --junitxml=\"reports/${{ matrix.consumer }}.xml\" | tee \"reports/${{ matrix.consumer }}.log\"\n#magic___^_^___line\n" |
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.
I don't quite get what is going on here. But please make it multiline.
Can you add a comment explaining the magic.
| run: "set -o pipefail \n.venv_docs/bin/python -m pytest -s -v src/tests/ --repo=\"$CONSUMER\" --junitxml=\"reports/${{ matrix.consumer }}.xml\" | tee \"reports/${{ matrix.consumer }}.log\"\n#magic___^_^___line\n" | |
| run: | | |
| set -o pipefail | |
| .venv_docs/bin/python -m pytest -s -v src/tests/ --repo="$CONSUMER" --junitxml="reports/${{ matrix.consumer }}.xml" | tee "reports/${{ matrix.consumer }}.log\"\n#magic___^_^___line" |
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.
It was the formatting automation that made it like this q_q.
I change it.
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.
So the formating is so weird here.
I don't know why the bazel run //src:format.fix command insits on this being a single line like:
run: "set -o pipefail \n.venv_docs/bin/python -m pytest -s -v src/tests/ --repo=\"$CONSUMER\" --junitxml=\"reports/${{ matrix.consumer }}.xml\" | tee \"reports/${{ matrix.consumer }}.log\"\n"Even when I specify it as a valid multi line like so:
run: |
set -o pipefail
.venv_docs/bin/python -m pytest -s -v src/tests/ --repo="$CONSUMER" --junitxml="reports/${{ matrix.consumer }}.xml" | tee "reports/${{ matrix.consumer }}.log"Any idea why this is happening?
And I can't pass the formating check if we use the single line.
But as you said i find this much less readable. Is there maybe a setting we can change?
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.
Nvm seems that it is fixed.
The pipe into 'tee' has made it so only the exit code of the 'tee' action was recorded / interpreted by github. This meant that any fail inside the consumer test was ignored and it only failed if the 'tee' action would fail.
📌 Description
🚨 Impact Analysis
✅ Checklist