Skip to content

Conversation

@JelleZijlstra
Copy link
Member

This is what I've actually been doing, but better to document it.

This is what I've actually been doing, but better to document it.
@JelleZijlstra
Copy link
Member Author

cc @AA-Turner since I think you wrote the current version of these instructions

Copy link
Collaborator

@hauntsaninja hauntsaninja left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good, feel free to merge or wait for AA-Turner :-)

- Ensure that GitHub Actions reports no errors.

- Update the version number in `pyproject.toml`.
- Update the version number in `typing_extensions/pyproject.toml` and in
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

nit: for releases I personally find it helpful to split up steps as much as possible and not use and

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think here it is fine as the step is "update the version number", there are just two places to do it.

A

- `rm -rf dist/`
- `python -m build .`

- Install the built distributions locally and test (if you were using `tox`, you already
Copy link
Collaborator

@hauntsaninja hauntsaninja Feb 14, 2022

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Might be nice to write out the commands for testing local builds

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I tend to just install it and import it... I'd rather leave this out for now in the hope that we'll switch to fully automatic releases.

@AA-Turner
Copy link
Member

I think this is fine for better release instructions.

I've started to prefer release automation -- either fully automated release on PR merge, or automatic release on pushing a tag. If there would be interest in this I could mock up a GHA script?

A

@JelleZijlstra
Copy link
Member Author

Thanks for the reviews! I'd also prefer automatic releases, since I don't exactly trust myself to do it right. (It's a lot easier with build than it was before, though.) On Black and a couple of other projects I maintain we generate releases automatically on tags, which works well. Could you tell me more about the option to release on PR merge? I haven't seen that before.

@JelleZijlstra JelleZijlstra merged commit 1cb25b8 into master Feb 14, 2022
@JelleZijlstra JelleZijlstra deleted the JelleZijlstra-patch-1 branch February 14, 2022 18:07
@AA-Turner
Copy link
Member

Could you tell me more about the option to release on PR merge?

The idea is entirely stolen from Hypothesis, although that project may have stolen it from somewhere else.

The precis is that each PR includes a changelog fragment file (RELEASE.rst or similar), which is detected by CI and used to bump the version (major/micro/patch), prepend to the changelog, and build/tag/release.

The versioning information comes from the marker file -- either a line with release level, or release level in the suffix (RELEASE.minor.md).

I have an implementation for another project that I'm happy to adapt for here -- the issue is testing, really, as you don't want to be releasing thousands of versions whilst tweaking the infrastructure. Test PyPI might be a good solution for this, though.

A

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants