Skip to content

Commit

Permalink
Fix CI issues
Browse files Browse the repository at this point in the history
- https://github.com/astronomer/astro-sdk/actions/runs/10957200761/job/30424844404\?pr\=2187
- issue that would come after, similar to what we experienced in the Ray Provider and Cosmos projects
  • Loading branch information
tatiana committed Sep 20, 2024
1 parent 33ca675 commit ac22ca8
Showing 1 changed file with 17 additions and 9 deletions.
26 changes: 17 additions & 9 deletions .github/workflows/ci-python-sdk.yaml
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
name: Build and test astro Python SDK
on:
push:
branches: [ 'main', 'release-**' ]
branches: [ 'main', 'release-**', 'fix-ci' ]
paths:
- 'python-sdk/**'
- '.github/workflows/ci-python-sdk.yaml'
Expand Down Expand Up @@ -193,10 +193,11 @@ jobs:
- run: pip3 install nox
- run: nox -s test_examples_by_dependency -- --cov=src --cov-report=xml --cov-branch
- name: Upload coverage
uses: actions/upload-artifact@v2
uses: actions/upload-artifact@v4
with:
name: coverage${{ matrix.group }}
path: ./python-sdk/.coverage
include-hidden-files: true
env:
GOOGLE_APPLICATION_CREDENTIALS_JSON: ${{ secrets.GOOGLE_APPLICATION_CREDENTIALS_JSON }}
GOOGLE_APPLICATION_CREDENTIALS: /tmp/google_credentials.json
Expand Down Expand Up @@ -258,10 +259,11 @@ jobs:
- run: pip3 install nox
- run: nox -s "test-${{ matrix.version }}(airflow='2.8')" -- tests/ --cov=src --cov-report=xml --cov-branch
- name: Upload coverage
uses: actions/upload-artifact@v2
uses: actions/upload-artifact@v4
with:
name: coverage-unit-test
path: ./python-sdk/.coverage
include-hidden-files: true

Run-load-file-Integration-Airflow-2-8:
if: >-
Expand Down Expand Up @@ -339,15 +341,17 @@ jobs:
- run: nox -s "test-3.10(airflow='2.8')" -- tests_integration/ -k "test_load_file.py and not redshift" --splits 3 --group ${{ matrix.group }} --store-durations --durations-path /tmp/durations-${{ matrix.group }} --cov=src --cov-report=xml --cov-branch
- run: cat /tmp/durations-${{ matrix.group }}
- name: Upload coverage
uses: actions/upload-artifact@v2
uses: actions/upload-artifact@v4
with:
name: coverage-${{ matrix.group }}-integration-tests
path: ./python-sdk/.coverage
include-hidden-files: true
- name: Collect pytest durations
uses: actions/upload-artifact@v2
uses: actions/upload-artifact@v4
with:
name: pytest_durations_load_file_${{ matrix.group }}
path: /tmp/durations-${{ matrix.group }}
include-hidden-files: true
env:
GOOGLE_APPLICATION_CREDENTIALS_JSON: ${{ secrets.GOOGLE_APPLICATION_CREDENTIALS_JSON }}
GOOGLE_APPLICATION_CREDENTIALS: /tmp/google_credentials.json
Expand Down Expand Up @@ -440,15 +444,17 @@ jobs:
- run: nox -s "test-3.10(airflow='2.8')" -- tests_integration/ -k "test_example_dags.py and not redshift" --splits 3 --group ${{ matrix.group }} --store-durations --durations-path /tmp/durations-${{ matrix.group }} --cov=src --cov-report=xml --cov-branch
- run: cat /tmp/durations-${{ matrix.group }}
- name: Upload coverage
uses: actions/upload-artifact@v2
uses: actions/upload-artifact@v4
with:
name: coverage-${{ matrix.group }}-integration-tests
path: ./python-sdk/.coverage
include-hidden-files: true
- name: Collect pytest durations
uses: actions/upload-artifact@v2
uses: actions/upload-artifact@v4
with:
name: pytest_durations_example_dags_${{ matrix.group }}
path: /tmp/durations-${{ matrix.group }}
include-hidden-files: true
env:
GOOGLE_APPLICATION_CREDENTIALS_JSON: ${{ secrets.GOOGLE_APPLICATION_CREDENTIALS_JSON }}
GOOGLE_APPLICATION_CREDENTIALS: /tmp/google_credentials.json
Expand Down Expand Up @@ -541,15 +547,16 @@ jobs:
- run: nox -s "test-3.10(airflow='2.8')" -- tests_integration/ -k "not test_load_file.py and not test_example_dags.py and not redshift" --splits 11 --group ${{ matrix.group }} --store-durations --durations-path /tmp/durations-${{ matrix.group }} --cov=src --cov-report=xml --cov-branch
- run: cat /tmp/durations-${{ matrix.group }}
- name: Upload coverage
uses: actions/upload-artifact@v2
uses: actions/upload-artifact@v4
with:
name: coverage-${{ matrix.group }}-integration-tests
path: ./python-sdk/.coverage
- name: Collect pytest durations
uses: actions/upload-artifact@v2
uses: actions/upload-artifact@v4
with:
name: pytest_durations_integration_tests_${{ matrix.group }}
path: /tmp/durations-${{ matrix.group }}
include-hidden-files: true
env:
GOOGLE_APPLICATION_CREDENTIALS_JSON: ${{ secrets.GOOGLE_APPLICATION_CREDENTIALS_JSON }}
GOOGLE_APPLICATION_CREDENTIALS: /tmp/google_credentials.json
Expand Down Expand Up @@ -601,6 +608,7 @@ jobs:
name: constraints-${{ matrix.python }}-${{ matrix.airflow }}
path: ./python-sdk/constraints-${{ matrix.python }}-${{ matrix.airflow }}
if-no-files-found: error
include-hidden-files: true

Code-Coverage:
if: github.event.action != 'labeled'
Expand Down

0 comments on commit ac22ca8

Please sign in to comment.