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.
📝 Summary
Firstly, this commits adds the building of a source distribution. When a Python package is installed, it is typically installed from a binary wheel and will fallback to the source distribution if it cannot find a matching wheel.
Additionally, I have created a new GitHub environment called
pypi
which stores a token authorising publication to Pact Python (and only Pact Python). The token is associated with my account, and will hopefully be replaced by trusted publishing soon (which bypasses tokens entirely).For the time being, I will keep the old GitHub environments in case I need to use the secrets there, but once I have confirmed the new credentials work (or that we don't need credentials at all thanks to trusted publishing), then I will remove the secrets.
🚨 Breaking Changes🔥 Motivation
The automated publishing to Pypi is unfortunately broken, likely because Pypi now enforces that 2FA be enabled. This consequently prevents a username/password pair from being used for authentication, and requires an authentication token to be generated for the account.
The current
build.yml
unfortunately makes use of the username/password pair and therefore needs to be fixed🔨 Test Plan
Wait until the next release and see 🤷♂️
🔗 Related issues/PRs