GeezerVisonThe World Wide Web, restored to 800 pixels of glory. | |||||||||||||||||||||||||||||||||||||||||||
| Home|About|Gaming cabinet|Archives|How it works|Starter sites | |||||||||||||||||||||||||||||||||||||||||||
GeezerVison is showing github.com — gh-143750: Compile OpenSSL with TSan for TSan CI by colesbury · Pull Request #143752 · python/cpython Conversation
|
| strategy: | ||
| fail-fast: false | ||
| matrix: | ||
| os: [ubuntu-24.04] | ||
| openssl_ver: [3.5.4] | ||
| runs-on: ${{ matrix.os }} |
There was a problem hiding this comment.
The reason will be displayed to describe this comment to others. Learn more.
Plz move these to inputs: and host the matrix on the calling side (in build.yml). This is the separation I was going for when I first introduced the reusable-*.yml module pattern — no matrices in modules.
Sorry, something went wrong.
There was an error while loading. Please reload this page.
There was a problem hiding this comment.
The reason will be displayed to describe this comment to others. Learn more.
This is a convenient way to define a variable that's reused a few times in the workflow. It could be an env, but it's not actually needed in the environment.
Sorry, something went wrong.
There was an error while loading. Please reload this page.
There was a problem hiding this comment.
The reason will be displayed to describe this comment to others. Learn more.
I know. I designed the modular approach with consistency in mind (which includes only allowing matrices on the top level). Having a matrix in reusable workflows sometimes has awkward side effects in a few places on GH, which I'd rather we avoid.
FWIW, you can use inputs with default values the same way — for var declarations — just a bit more verbosely. Although, I'd argue that being able to fill out descriptions for the inputs would be beneficial by making the purpose documented explicitly.
Sorry, something went wrong.
There was an error while loading. Please reload this page.
There was a problem hiding this comment.
The reason will be displayed to describe this comment to others. Learn more.
It could be an
env, but it's not actually needed in the environment.
I noticed you're setting OPENSSL_VER already so it's already in there.
And I know that for os, people in other PRs were unhappy to see it in the matrix 🤷♂️
Actually, in #136729 (comment), Hugo suggested using env.IMAGE_OS_VERSION / ${IMAGE_OS_VERSION} in the steps, making the matrix entry redundant.
Sorry, something went wrong.
There was an error while loading. Please reload this page.
There was a problem hiding this comment.
The reason will be displayed to describe this comment to others. Learn more.
Another reason for using env is that it'll trip Zizmor checks — they are probably suppressed right now but once re-enabled, we'll need to deal with the interpolation on GHA vs. Bash level.
I'll need to work on migrating everything to env vars at some point and making sure Zizmor enforces that.
Sorry, something went wrong.
There was an error while loading. Please reload this page.
| && ' (free-threading)' | ||
| || '' | ||
| }} |
There was a problem hiding this comment.
The reason will be displayed to describe this comment to others. Learn more.
This will also need to interpolate new matrix factors since the job names will be confusing if there's ever more than one job.
Sorry, something went wrong.
There was an error while loading. Please reload this page.
There was a problem hiding this comment.
The reason will be displayed to describe this comment to others. Learn more.
There's the same jobs as before. The TSan ones just now compile OpenSSL with TSan
Sorry, something went wrong.
There was an error while loading. Please reload this page.
There was a problem hiding this comment.
The reason will be displayed to describe this comment to others. Learn more.
Right, so there shouldn't be a matrix, then: #143752 (comment)
Sorry, something went wrong.
There was an error while loading. Please reload this page.
| run: | | ||
| if [ "${SANITIZER}" = "TSan" ]; then |
There was a problem hiding this comment.
The reason will be displayed to describe this comment to others. Learn more.
We can move this conditional to the GHA step so that skipping is more prominent.
| run: | | |
| if [ "${SANITIZER}" = "TSan" ]; then | |
| if: inputs.sanitizer == 'TSan' | |
| run: | |
Also drop fi and the second conditional block below too.
Sorry, something went wrong.
There was an error while loading. Please reload this page.
There was an error while loading. Please reload this page.
There was a problem hiding this comment.
The reason will be displayed to describe this comment to others. Learn more.
I merged the if blocks, but you can't lift the conditional the GHA step because you still need the:
else echo "UBSAN_OPTIONS=${SAN_LOG_OPTION}" >> "$GITHUB_ENV" fi
and the unconditional
echo "CC=clang" >> "$GITHUB_ENV" echo "CXX=clang++" >> "$GITHUB_ENV"
Sorry, something went wrong.
There was an error while loading. Please reload this page.
There was a problem hiding this comment.
The reason will be displayed to describe this comment to others. Learn more.
@colesbury what I'd recommend is splitting these into two steps so that it'd be possible to move the conditional and it'd be prominent in the log. Alternatively, it might make sense to just move CC and CXX into the declarative per-step env: since they aren't computed dynamically anyway. Though, looking more into it, it sound like they probably belong in the Install dependencies which makes clang available and is already setting up the env to use it — just like these env vars.
Sorry, something went wrong.
There was an error while loading. Please reload this page.
There was an error while loading. Please reload this page.
Co-authored-by: 🇺🇦 Sviatoslav Sydorenko (Святослав Сидоренко) <[email protected]>
|
This PR is stale because it has been open for 30 days with no activity. |
Sorry, something went wrong.
There was an error while loading. Please reload this page.
|
Completed in #153316. |
Sorry, something went wrong.
There was an error while loading. Please reload this page.
There was an error while loading. Please reload this page.
Successfully merging this pull request may close these issues.
There was an error while loading. Please reload this page.