Install setuptools before t-encrypt version resolution#304
Merged
Conversation
oleksandrSydorenkoJ
requested review from
kladkogex and
olehnikolaiev
as code owners
July 16, 2026 17:30
Contributor
There was a problem hiding this comment.
Pull request overview
Updates the publish workflow to ensure Python packaging tooling is available before resolving the t-encrypt package version, preventing failures on newer runners (e.g., Python 3.13 where setuptools may not be preinstalled).
Changes:
- Install/upgrade
pipandsetuptoolsbefore running the version-resolution step in the publish workflow.
Comments suppressed due to low confidence (1)
.github/workflows/publish.yml:140
- This step mixes
python3andpythoninvocations in the same workflow. On GitHub-hosted runners this is usually the same interpreter, but it’s not guaranteed; using a single interpreter (python) ensures thepip install(setuptools) and the version resolution run against the exact same Python configured byactions/setup-python.
run: |
lib_path="${PWD}/build_t_encrypt_python/threshold_encryption/libt_encrypt_python.so"
echo "T_ENCRYPT_LIB_PATH=${lib_path}" >> "$GITHUB_ENV"
python3 -m pip install --upgrade pip setuptools
# Calculate Python package version
cd python
BASE_VERSION=$(python3 setup_t_encrypt.py --version)
PropzSaladaz
approved these changes
Jul 16, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to subscribe to this conversation on GitHub.
Already have an account?
Sign in.
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What:
Fix the
t-encryptPython wheel build so the bundled nativelibencrypt.sois built against OpenSSL 3 and validated before publish.Why:
The previously published wheel could depend on
libcrypto.so.1.1, which is not available in some Ubuntu environments and causesimport t_encryptto fail at runtime.The wheel also bundles a native Linux
.so, so it must be platform-tagged and must not be published aspy3-none-any.How:
OPENSSL_GIT_REFsupport indeps/build.sh, while keeping the default OpenSSL version unchanged.OPENSSL_GIT_REF=openssl-3.0.15only for the Pythont-encryptwheel build.git checkout --detach "$OPENSSL_GIT_REF"instead ofeval.t-encryptdistribution as binary so wheels containinglibencrypt.soare platform-specific.py3-none-any;auditwheel show;t_encrypt/libencrypt.sois bundled;libssl.so.1.1orlibcrypto.so.1.1.t-encryptwheel artifact and validate that same artifact on Ubuntu 22.04 and Ubuntu 24.04.setuptoolsbefore reading the package version because Python 3.13 runners do not guarantee it is available by default.Checklist: