Skip to content

Update HOWTORELEASE #2451

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

Merged
merged 1 commit into from
May 31, 2017
Merged
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
46 changes: 29 additions & 17 deletions HOWTORELEASE.rst
Original file line number Diff line number Diff line change
Expand Up @@ -3,47 +3,59 @@ How to release pytest

.. important::

pytest releases must be prepared on **linux** because the docs and examples expect
pytest releases must be prepared on **Linux** because the docs and examples expect
to be executed in that platform.

#. Install development dependencies in a virtual environment with::

pip3 install -r tasks/requirements.txt

#. Create a branch ``release-X.Y.Z`` with the version for the release. Make sure it is up to date
with the latest ``master`` (for patch releases) and with the latest ``features`` merged with
the latest ``master`` (for minor releases). Ensure your are in a clean work tree.
#. Create a branch ``release-X.Y.Z`` with the version for the release.

#. Check and finalize ``CHANGELOG.rst`` (will be automated soon).
* **patch releases**: from the latest ``master``;

#. Execute to automatically generate docs, announcements and upload a package to
* **minor releases**: from the latest ``features``; then merge with the latest ``master``;

Ensure your are in a clean work tree.

#. Generate docs, changelog, announcements and upload a package to
your ``devpi`` staging server::

invoke generate.pre_release <VERSION> <DEVPI USER> --password <DEVPI PASSWORD>

If ``--password`` is not given, it is assumed the user is already logged in. If you don't have
an account, please ask for one!
If ``--password`` is not given, it is assumed the user is already logged in ``devpi``.
If you don't have an account, please ask for one.

#. Open a PR for this branch targeting ``master``.

#. Test the package

#. Run from multiple machines::
* **Manual method**

devpi use https://devpi.net/USER/dev
devpi test pytest==VERSION
Run from multiple machines::

Alternatively, you can use `devpi-cloud-tester <https://github.com/nicoddemus/devpi-cloud-tester>`_ to test
the package on AppVeyor and Travis (follow instructions on the ``README``).
devpi use https://devpi.net/USER/dev
devpi test pytest==VERSION

#. Check that tests pass for relevant combinations with::
Check that tests pass for relevant combinations with::

devpi list pytest

or look at failures with "devpi list -f pytest".
* **CI servers**

#. Feeling confident? Publish to PyPI::
Configure a repository as per-instructions on
devpi-cloud-test_ to test the package on Travis_ and AppVeyor_.
All test environments should pass.

#. Publish to PyPI::

invoke generate.publish_release <VERSION> <DEVPI USER> <PYPI_NAME>

where PYPI_NAME is the name of pypi.python.org as configured in your ``~/.pypirc``
file `for devpi <http://doc.devpi.net/latest/quickstart-releaseprocess.html?highlight=pypirc#devpi-push-releasing-to-an-external-index>`_.


#. After a minor/major release, merge ``features`` into ``master`` and push (or open a PR).

.. _devpi-cloud-test: https://github.com/obestwalter/devpi-cloud-test
Copy link
Member

Choose a reason for hiding this comment

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

Out of curiosity, what happened to nicoddemus/devpi-cloud-tester?

Copy link
Member Author

Choose a reason for hiding this comment

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

Still there, but I'm using @obestwalter's solution now because it is more rounded up. Mine was mostly an experiment.

We might even consider moving my fork to @pytest-dev and making that the official way to test pytest's releases using devpi.

.. _AppVeyor: https://www.appveyor.com/
.. _Travis: https://travis-ci.org