fix: Analytics only for 3.10 version

api-breakage
Morty Space 4 years ago
parent f111227caf
commit 0f855f5e0b
  1. 7
      .github/workflows/test.yml

@ -16,7 +16,7 @@ jobs:
strategy: strategy:
max-parallel: 1 max-parallel: 1
matrix: matrix:
python-version: ['3.7', '3.8', '3.9', '3.10'] python-version: ['3.10', '3.9', '3.8', '3.7']
runs-on: ubuntu-latest runs-on: ubuntu-latest
steps: steps:
- name: Download code - name: Download code
@ -47,6 +47,7 @@ jobs:
if: steps.poetry-install.outputs.cache-hit != 'true' if: steps.poetry-install.outputs.cache-hit != 'true'
run: rm -rf ./.venv/ && poetry install run: rm -rf ./.venv/ && poetry install
- name: Download cache for pre-commit - name: Download cache for pre-commit
if: matrix.python-version == '3.10'
id: pre-commit-install id: pre-commit-install
uses: actions/cache@v2 uses: actions/cache@v2
with: with:
@ -54,12 +55,14 @@ jobs:
key: py-${{ matrix.python-version }}-pre-commit-install-${{ hashFiles('.pre-commit-config.yaml') }} key: py-${{ matrix.python-version }}-pre-commit-install-${{ hashFiles('.pre-commit-config.yaml') }}
restore-keys: pre-commit-install restore-keys: pre-commit-install
- name: Verify commit - name: Verify commit
if: matrix.python-version == '3.10'
run: poetry run pre-commit run -a run: poetry run pre-commit run -a
- name: Auto-generate missing pairs - name: Auto-generate missing pairs
run: | run: |
. activate.sh && poetry run python generatestructs.py . activate.sh && poetry run python generatestructs.py
poetry run python generatestructs.py poetry run python generatestructs.py
- name: Commit & Push changes - name: Commit & Push changes
if: matrix.python-version == '3.10'
uses: actions-js/push@v1.3 uses: actions-js/push@v1.3
with: with:
author_email: "morty.space@gmail.com" author_email: "morty.space@gmail.com"
@ -68,6 +71,7 @@ jobs:
message: "[BOT] Updated API pairs and coins" message: "[BOT] Updated API pairs and coins"
github_token: ${{ secrets.GITHUB_TOKEN }} github_token: ${{ secrets.GITHUB_TOKEN }}
- name: Prepare codeclimate - name: Prepare codeclimate
if: matrix.python-version == '3.10'
run: | run: |
curl -L https://codeclimate.com/downloads/test-reporter/test-reporter-latest-linux-amd64 > ./cc-test-reporter curl -L https://codeclimate.com/downloads/test-reporter/test-reporter-latest-linux-amd64 > ./cc-test-reporter
chmod +x ./cc-test-reporter chmod +x ./cc-test-reporter
@ -78,6 +82,7 @@ jobs:
timeout-minutes: 5 timeout-minutes: 5
run: . activate.sh && poetry run pytest -v --cov . --cov-report xml:coverage.xml run: . activate.sh && poetry run pytest -v --cov . --cov-report xml:coverage.xml
- name: Send codeclimate analytics - name: Send codeclimate analytics
if: matrix.python-version == '3.10'
run: ./cc-test-reporter after-build -r ${{ secrets.CC_TEST_REPORTER_ID }} --exit-code $? run: ./cc-test-reporter after-build -r ${{ secrets.CC_TEST_REPORTER_ID }} --exit-code $?
release: release:
runs-on: ubuntu-latest runs-on: ubuntu-latest

Loading…
Cancel
Save