Skip to content
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

Update release process and mark unit tests as executable #1163

Merged
merged 2 commits into from
Oct 15, 2020
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
13 changes: 9 additions & 4 deletions docs/RELEASE.md
Original file line number Diff line number Diff line change
@@ -1,12 +1,16 @@
# Release process

* Ensure you have a backup of all working files and then remove files not tracked by git
`git clean -xdf`. **NOTE**: this will delete all files in the tuf tree that aren't
Copy link
Collaborator

@MVrachev MVrachev Oct 5, 2020

Choose a reason for hiding this comment

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

Does this mean that if I am to release something, this will have to delete all my venvs in the current directory (which of course are not tracked by git) if I don't back them up?

Copy link
Member Author

Choose a reason for hiding this comment

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

Yes, it does. The theory is that it's better to ensure the directory is clean and matches the git tree, so that we don't accidentally end up packaging things we don't intend to ship.

Copy link
Collaborator

Choose a reason for hiding this comment

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

Yes, it makes sense.
Just wanted to make sure I understand it right.

Copy link
Member

@lukpueh lukpueh Oct 5, 2020

Choose a reason for hiding this comment

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

@MVrachev, you could also keep your venvs in an ENV_DIR that's not under cwd. :)

Copy link
Member

Choose a reason for hiding this comment

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

@MVrachev the alternative I've used is that I never do releases from my development directory: I make a new git clone for every release. This ensures two things

  1. all files required for the release actually are in git
  2. no files from outside of git end up in the release

tracked by git
* Ensure `docs/CHANGELOG.md` contains a one-line summary of each [notable
change](https://keepachangelog.com/) since the prior release
* Update `setup.py` and `tuf/__init__.py` to the new version number vA.B.C
* Test packaging, uploading to Test PyPI and installing from a virtual environment
(ensure commands invoking `python` below are using Python 3)
Copy link
Contributor

Choose a reason for hiding this comment

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

I'm not sure we need this note (here and below) if the commands also say python3

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 it's okay to be very clear about it. But I'm fine either way.

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 opted to be very clear, just in case readers are not diligently reading each step

* Remove existing dist build dirs
* Create source dist `python setup.py sdist`
* Create wheel (with 2 and 3 support) `python setup.py bdist_wheel --universal`
* Create source dist `python3 setup.py sdist`
* Create wheel (with 2 and 3 support) `python3 setup.py bdist_wheel --universal`
* Sign the dists `gpg --detach-sign -a dist/tuf-vA.B.C.tar.gz`
* Upload to test PyPI `twine upload --repository testpypi dist/*`
* Verify the uploaded package https://testpypi.python.org/pypi/tuf/
Expand All @@ -18,9 +22,10 @@
* Create a new release on GitHub, copying the `CHANGELOG.md` entries for the
release
* Create a package for the formal release
(ensure commands invoking `python` below are using Python 3)
* Remove existing dist build dirs
* Create source dist `python setup.py sdist`
* Create wheel (with 2 and 3 support) `python setup.py bdist_wheel --universal`
* Create source dist `python3 setup.py sdist`
* Create wheel (with 2 and 3 support) `python3 setup.py bdist_wheel --universal`
* Sign source dist `gpg --detach-sign -a dist/tuf-vA.B.C.tar.gz`
* Sign wheel `gpg --detach-sign -a dist/tuf-vA.B.C-py2.py3-none-any.whl`
* Upload to test PyPI `twine upload --repository testpypi dist/*`
Expand Down
Empty file modified tests/test_api.py
100644 → 100755
Empty file.
Empty file modified tests/test_proxy_use.py
100644 → 100755
Empty file.
Empty file modified tests/test_tutorial.py
100644 → 100755
Empty file.
Empty file modified tests/test_updater.py
100644 → 100755
Empty file.