Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

ci: enable upload codecov statistics #9

Merged
merged 3 commits into from
Mar 22, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
24 changes: 24 additions & 0 deletions .azure/gpu-tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -65,8 +65,14 @@ jobs:
# drop pt from requirements so not to interfere with the existing one
bash .azure/remove-torch-lines.sh requirements/base.txt
cat requirements/base.txt

# double check on test requirements
pip install -r requirements/test.txt

# https://docs.codecov.com/docs/codecov-uploader
curl -Os https://uploader.codecov.io/latest/linux/codecov
chmod +x codecov

# install this package
python setup.py develop
displayName: 'Install package & ...'
Expand All @@ -85,6 +91,12 @@ jobs:
--durations=250 \
--numprocesses=9 \
--ignore=thunder/tests/distributed --ignore=thunder/tests/test_networks.py
# compile coverage results
python -m coverage report
python -m coverage xml
# upload to codecov
./codecov --token=$(CODECOV_TOKEN) --commit=$(Build.SourceVersion) \
--flags=gpu,pytest,regular --name="GPU-coverage" --env=linux,azure
condition: ne(variables['testing'], 'distributed')
displayName: 'Testing: regular'

Expand All @@ -95,6 +107,12 @@ jobs:
thunder/tests/test_networks.py \
-m "not standalone" \
-v --random-order-seed=42 --durations=0 --numprocesses=3
# compile coverage results
python -m coverage report
python -m coverage xml
# upload to codecov
./codecov --token=$(CODECOV_TOKEN) --commit=$(Build.SourceVersion) \
--flags=gpu,pytest,networks --name="GPU-coverage" --env=linux,azure
condition: ne(variables['testing'], 'distributed')
displayName: 'Testing: networks'

Expand All @@ -108,6 +126,12 @@ jobs:
- bash: |
# run all found tests in given past as standalone
bash scripts/run_standalone_tests.sh "thunder/tests/distributed"
# compile coverage results
python -m coverage report
python -m coverage xml
# upload to codecov
./codecov --token=$(CODECOV_TOKEN) --commit=$(Build.SourceVersion) \
--flags=gpu,pytest,distributed --name="GPU-coverage" --env=linux,azure
condition: eq(variables['testing'], 'distributed')
displayName: 'Testing: distributed'

Expand Down
18 changes: 9 additions & 9 deletions .github/workflows/ci-testing.yml
Original file line number Diff line number Diff line change
Expand Up @@ -114,15 +114,15 @@ jobs:
coverage report
coverage xml

#- name: Upload coverage to Codecov
# uses: codecov/codecov-action@v3
# with:
# token: ${{ secrets.CODECOV_TOKEN }}
# file: ./coverage.xml
# flags: unittests
# env_vars: OS,PYTHON
# name: codecov-umbrella
# fail_ci_if_error: false
- name: Upload coverage to Codecov
uses: codecov/codecov-action@v3
with:
token: ${{ secrets.CODECOV_TOKEN }}
file: ./coverage.xml
flags: unittests
env_vars: OS,PYTHON
name: codecov-umbrella
fail_ci_if_error: false


testing-guardian:
Expand Down
Loading