Made conversion on enum fields to List[str] optional #471
Workflow file for this run
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Code CI | |
on: | |
push: | |
pull_request: | |
jobs: | |
build: | |
strategy: | |
fail-fast: false | |
matrix: | |
os: ["ubuntu-latest"] # can add windows-latest, macos-latest | |
python: ["3.7", "3.8", "3.9"] | |
include: | |
# Tag the Python3.7 runner as the one to publish wheels | |
- os: "ubuntu-latest" | |
python: "3.7" | |
publish: true | |
name: ${{ matrix.os }}/${{ matrix.python }} | |
runs-on: ${{ matrix.os }} | |
steps: | |
- name: Checkout Source | |
uses: actions/checkout@v2 | |
- name: Set up Python ${{ matrix.python }} | |
uses: actions/setup-python@v2 | |
with: | |
python-version: ${{ matrix.python }} | |
- name: Install Python Dependencies | |
run: | | |
pip install pipenv twine build | |
pipenv install --dev --deploy --python $(python -c 'import sys; print(sys.executable)') && pipenv graph | |
- name: Create Sdist and Wheel | |
if: matrix.publish | |
# Set SOURCE_DATE_EPOCH from git commit for reproducible build | |
# https://reproducible-builds.org/ | |
# Set group writable and umask to do the same to match inside DLS | |
run: | | |
chmod -R g+w . | |
umask 0002 | |
SOURCE_DATE_EPOCH=$(git log -1 --pretty=%ct) python -m build --sdist --wheel | |
- name: Run Tests | |
run: pipenv run tests | |
- name: Upload coverage to Codecov | |
uses: codecov/codecov-action@v1 | |
with: | |
name: ${{ matrix.os }}/${{ matrix.python }} | |
files: cov.xml | |
- name: Upload Wheel and Sdist as artifacts | |
if: matrix.publish | |
uses: actions/upload-artifact@v2 | |
with: | |
name: dist | |
path: dist/* | |
- name: Publish Sdist and Wheel to PyPI | |
# Only once when on a tag | |
if: matrix.publish && startsWith(github.ref, 'refs/tags') | |
env: | |
TWINE_USERNAME: __token__ | |
TWINE_PASSWORD: ${{ secrets.pypi_token }} | |
run: twine upload dist/* |