fix: Pin down conventionalcommits to @7.0.2 (#221) #871
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: main | |
on: | |
push: | |
branches: [main] | |
pull_request: | |
branches: [main] | |
env: | |
POSTGRES_HOST: localhost | |
POSTGRES_PORT: 25432 | |
POSTGRES_USER: postgres | |
POSTGRES_PASSWORD: postgres | |
POSTGRES_EPIGRAPH_USER: dev_epigraph | |
POSTGRES_EPIGRAPH_PASSWORD: dev_epigraph | |
POSTGRES_EPIGRAPH_DB: dev_epigraphhub | |
jobs: | |
check-branch: | |
if: ${{ github.event_name == 'pull_request' }} | |
runs-on: ubuntu-latest | |
timeout-minutes: 10 | |
concurrency: | |
group: check-pr-${{ github.ref }} | |
cancel-in-progress: true | |
steps: | |
- uses: actions/checkout@v3 | |
with: | |
fetch-depth: 0 | |
- name: Check if the PR's branch is updated | |
uses: osl-incubator/[email protected] | |
with: | |
remote_branch: origin/main | |
pr_sha: ${{ github.event.pull_request.head.sha }} | |
tests: | |
runs-on: ubuntu-latest | |
strategy: | |
matrix: | |
python_version: ["3.9"] | |
concurrency: | |
group: ci-tests-${{ github.ref }} | |
cancel-in-progress: true | |
defaults: | |
run: | |
shell: bash -l {0} | |
steps: | |
- uses: actions/checkout@v3 | |
- name: Create environment variables file | |
run: | | |
cd docker | |
envsubst < .env.tpl > .env | |
- uses: conda-incubator/setup-miniconda@v3 | |
with: | |
miniconda-version: "latest" | |
environment-file: conda/dev.yaml | |
channels: conda-forge,nodefaults | |
activate-environment: epigraphhubpy | |
auto-update-conda: true | |
conda-solver: libmamba | |
python-version: "${{ matrix.python_version }}" | |
- name: Install dependencies | |
run: | | |
poetry check | |
poetry install --all-extras | |
- name: Create config file | |
run: makim config.create-file | |
- name: start up containers-sugar | |
run: | | |
containers-sugar build | |
containers-sugar start | |
makim containers.wait --service postgres | |
- name: Run tests | |
run: makim tests.unittest --extra="--disable-warnings" | |
- name: Linter | |
run: makim tests.linter | |
- name: Run safety checks | |
# https://github.com/numpy/numpy/issues/19038 | |
run: makim tests.check-safety || true | |
- name: teardown containers-sugar | |
run: containers-sugar stop | |
- name: Check if PR Title contains semantic-release tag | |
if: ${{ github.event_name == 'pull_request' && always() }} | |
run: bash scripts/ci/pr-title-linter.sh "${{ github.event.pull_request.title }}" |