This directory contains a number of workflows for use with GitHub Actions. They specify what standards should be expected for development of this software, including pull requests. These workflows are designed to work out of the box for any research software prototype, especially those based on Qiskit.
This workflow checks that the code is formatted properly and follows the style guide by installing tox and running the lint environment (tox -e lint
).
This workflow installs the latest version of tox and runs the current repository's tests under each supported Python version on Linux and under a single Python version on macOS and Windows. This is the primary testing workflow. It runs for all code changes and additionally once per day, to ensure tests continue to pass as new versions of dependencies are released.
This workflow installs tox and modifies pyproject.toml
to use the development versions of certain Qiskit packages, using extremal-python-dependencies. For all other packages, the latest version is installed. This workflow runs on two versions of Python: the minimum supported version and the maximum supported version. Its purpose is to identify as soon as possible (i.e., before a Qiskit release) when changes in Qiskit will break the current repository. This workflow runs for all code changes, as well as on a timer once per day.
This workflow first installs the minimum supported tox version (the minversion
specified in tox.ini
) and then installs the minimum compatible version of each package listed in pyproject.toml
, using extremal-python-dependencies. The purpose of this workflow is to make sure the minimum version specifiers in these files are accurate, i.e., that the tests actually pass with these versions. This workflow uses a single Python version, typically the oldest supported version, as the minimum supported versions of each package may not be compatible with the most recent Python release.
Under the hood, this workflow uses a regular expression to change each >=
and ~=
specifier in the dependencies to instead be ==
, as pip does not support resolving the minimum versions of packages directly. Unfortunately, this means that the workflow will only install the minimum version of a package if it is explicitly listed in one of the requirements files with a minimum version. For instance, if the only listed dependency is qiskit>=1.0
, this workflow will install qiskit==1.0
along with the latest version of each transitive dependency, such as rustworkx
.
This workflow tests the coverage environment on a single version of Python by installing tox and running tox -e coverage
.
This workflow ensures that the Sphinx documentation builds successfully. It also publishes the resulting build to GitHub Pages if it is from the appropriate branch (e.g., main
).
This workflow is only triggered when the CITATION.bib
file is changed. It ensures that the file contains only ASCII characters (escaped codes are preferred, as then the bib
file will work even when inputenc
is not used). It also compiles a sample LaTeX document which includes the citation in its bibliography and uploads the resulting PDF as an artifact so it can be previewed (e.g., before merging a pull request).
This workflow is triggered by a maintainer pushing a tag that represents a release. It publishes the release to github.com and to PyPI.