You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
* Update of the Developer documention
for describing the procedure to release a new version
* Release procedure corrected according to MJGaughran's remarks.
* Corrected typo
* Clarified the specification of numpy versions used in GitJub actions
* Added the ## Main modifications section
* corrected typo
* the version ensuring the requirements necessary to **run** PyAT is set in the
135
+
``dependencies`` item of the ``[project]`` section of ``pyproject.toml``
136
+
* The version required to **build** PyAT is set in the ``requires`` item of the
137
+
``[build-system]`` section of ``pyproject.toml``. It depends on the python version
138
+
and must be higher or equal to the "run" version.
139
+
* To avoid ABI compatibility issues, the pre-compiled binaries are built with the
140
+
earliest possible version of numpy for the given Python version. This ensures that
141
+
the user's libraries are more recent than the one AT has been compiled with. For
142
+
that, a copy of ``pyproject.toml`` named ``githubproject.toml`` is used for
143
+
compilation. In this copy, the numpy version specifications are set using ``~=``
144
+
instead of minimum (``>=``). Apart from these lines, the 2 files
145
+
should be strictly identical.
146
+
147
+
Prepare the "Release notes"
148
+
~~~~~~~~~~~~~~~~~~~~~~~~~~~
149
+
A draft can be obtained by creating a new tag on GitHub. Click "Draft a new release"
150
+
in the releases page, choose a new tag in the form ``pyat-x.y.z`` with the correct
151
+
incremented version number. The ``pyat-`` prefix is necessary to identify python releases.
152
+
Select the master branch as target. In the description area, choose the current
153
+
release in the "previous tag" pull-down, and press "Generate release notes".
154
+
155
+
The generated notes can now be copied and edited. You can then either cancel or
156
+
save the release as a draft while editing the release notes.
157
+
158
+
The ``## What's changed`` section should be split into ``## Bug fixes`` and
159
+
``## New features``. It must be filtered to keep only the python changes, ignoring
160
+
the Matlab ones. The tags on each pull request are there to help in this filtering.
161
+
162
+
The release notes should start with a ``## Main modifications`` section summarising
163
+
the important points of the new release.
164
+
165
+
They must end with a section pointing out ``## Incompatibilities`` and mentioning the
166
+
necessary actions before upgrading to this release.
167
+
168
+
Open a Pull Request for the new release
169
+
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
170
+
171
+
The goal is to make all contributors aware of the new release, to check that no pending
172
+
modifications are worth being included and to review the release notes.
173
+
174
+
There should be no code modifications except updates of version informations in the
175
+
documentation. Once the pull request is approved and merged, the release may be built.
176
+
177
+
178
+
Build the release
179
+
~~~~~~~~~~~~~~~~~
180
+
181
+
Now either go back to the draft release saved above, or start again the procedure,
182
+
but now finalising with the ``Publish`` button.
123
183
124
184
If all goes well, there will be a build of "Build and upload wheels and sdist"
125
185
associated with the tag ``pyat-x.y.z``: on the `Github Actions page <https://github.com/atcollab/at/actions/workflows/build-python-wheels.yml>`_. This build will have
126
186
'tar.gz' and 'wheels' downloads available.
127
187
188
+
Upload the release to ``pip``
189
+
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
190
+
128
191
* Download the tar.gz and wheels files and unzip them into a directory ``<dir>``
129
192
* Manually install at least one wheel to make sure that it has built correctly
130
-
* Install Twine for uploading the files to PyPI. One way to do this is to create a new virtualenv::
193
+
* Install Twine for uploading the files to PyPI. One way is to use
194
+
`pipx <https://pypa.github.io/pipx/>`_. Once pipx installed, use::
131
195
132
-
$ python3 -m venv venv
133
-
$ source venv/bin/activate
134
-
$ pip install twine
196
+
$ pipx install twine # or:
197
+
$ pipx upgrade twine
135
198
136
199
* Use Twine to upload the files to PyPI. You will be prompted for your PyPI credentials::
137
200
@@ -145,4 +208,4 @@ associated with the tag ``pyat-x.y.z``: on the `Github Actions page <https://git
145
208
Note that 46 different files were uploaded for pyat-0.0.4 covering different
146
209
platforms and architectures.
147
210
148
-
The configuration for this is in .github/workflows/build-python-wheels.yml.
211
+
The configuration for this is in ``.github/workflows/build-python-wheels.yml``.
0 commit comments