This repository was archived by the owner on Jun 2, 2026. It is now read-only.
File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change 1414 version : ' ${{ github.run_number }}.0.0'
1515 repository : testpypi
1616 secrets :
17- twine_username : __token__
18- twine_password : ${{ secrets.TESTPYPI_TOKEN }}
17+ twine_token : ${{ secrets.TESTPYPI_TOKEN }}
18+ CODECOV_TOKEN : ${{ secrets.CODECOV_TOKEN }}
Original file line number Diff line number Diff line change 1212 # so easy to forget bumping the version to match the tag, just override it!
1313 version : ${{ github.ref_name }}
1414 secrets :
15- twine_username : __token__
16- twine_password : ${{ secrets.PYPI_TOKEN }}
15+ twine_token : ${{ secrets.PYPI_TOKEN }}
16+ CODECOV_TOKEN : ${{ secrets.CODECOV_TOKEN }}
Original file line number Diff line number Diff line change 1010 default : pypi
1111 type : string
1212 secrets :
13- twine_username :
13+ twine_token :
1414 required : true
15- twine_password :
15+ CODECOV_TOKEN :
16+ required : false
17+ workflow_dispatch :
18+ inputs :
19+ version :
20+ description : ' Version to publish (for example: 1.2.3)'
21+ type : string
1622 required : true
23+ repository :
24+ description : ' Package index repository'
25+ type : choice
26+ options :
27+ - pypi
28+ - testpypi
29+ default : pypi
1730
1831run-name : publish to ${{ inputs.repository }}
1932
2033jobs :
2134 test :
2235 uses : ./.github/workflows/test.yml
36+ secrets :
37+ CODECOV_TOKEN : ${{ secrets.CODECOV_TOKEN }}
2338
2439 publish :
2540 name : publish to ${{ inputs.repository }}
@@ -36,21 +51,18 @@ jobs:
3651
3752 - name : Install dependencies
3853 run : |
39- pip install pipenv
40- pipenv requirements --dev > reqs.txt
41- pip install -r reqs.txt
54+ pip install uv
55+ uv sync --dev
4256 - name : force right version
4357 run : |
4458 .github/change_version.py --set '${{ inputs.version }}'
4559 - name : Build
46- run : pyproject-build
60+ run : uv run pyproject-build
4761 - name : Publish
4862 env :
49- TWINE_USERNAME : ${{ secrets.twine_username }}
50- TWINE_PASSWORD : ${{ secrets.twine_password }}
51- run : |
52- pyproject-build
53- twine upload --repository ${{ inputs.repository }} dist/*
63+ TWINE_USERNAME : __token__
64+ TWINE_PASSWORD : ${{ secrets.twine_token }}
65+ run : uv run twine upload --verbose --repository ${{ inputs.repository }} dist/*
5466 - name : highlight
5567 run : |
5668 INDEX=""
Original file line number Diff line number Diff line change @@ -2,6 +2,9 @@ name: 🧪 tests
22
33on :
44 workflow_call :
5+ secrets :
6+ CODECOV_TOKEN :
7+ required : false
58 push :
69 branches-ignore :
710 # these are already tested by publish-dev
2326
2427 - name : Install dependencies
2528 run : |
26- pip install pipenv
27- pipenv requirements --dev > reqs.txt
28- pip install -r reqs.txt
29+ pip install uv
30+ uv sync --dev
2931
3032 - name : Lint check
3133 run : |
@@ -47,20 +49,18 @@ jobs:
4749
4850 - name : Install dependencies
4951 run : |
50- pip install pipenv
51- pipenv requirements --dev > reqs.txt
52- pip install -r reqs.txt
52+ pip install uv
53+ uv sync --dev
5354
5455 - name : Run unit tests
5556 run : |
5657 make test
5758
5859 - name : Upload results to Codecov
59- uses : codecov/codecov-action@v4
60-
61- - name : Upload test results to Codecov
62- if : ${{ !cancelled() }}
63- uses : codecov/test-results-action@v1
60+ uses : codecov/codecov-action@v5
61+ with :
62+ token : ${{ secrets.CODECOV_TOKEN }}
63+ report_type : test_results
6464
6565 integration-test :
6666 runs-on : ubuntu-latest
7575
7676 - name : Install dependencies
7777 run : |
78- pip install pipenv
79- pipenv requirements --dev > reqs.txt
80- pip install -r reqs.txt
78+ pip install uv
79+ uv sync --dev
8180
8281 - name : Run e2e tests
8382 run : |
Original file line number Diff line number Diff line change 11## Build
22
3- This project uses a ` Pipfile ` , so set up the virtualenv by running
3+ This project uses ` uv ` , so set up the virtualenv by running
44
55```
6- pipenv install --dev
6+ uv sync --dev
77```
88
99Use ` make test ` to make sure all tests pass before pushing.
@@ -12,4 +12,4 @@ Use `make lint` to make sure lint check passes before pushing.
1212
1313## Guidelines
1414
15- ...
15+ ...
Original file line number Diff line number Diff line change 11lint :
2- ruff format
3- ruff check --fix
4- pyproject-pipenv --fix
2+ uv run ruff format
3+ uv run ruff check --fix
54
65lint-check :
7- ruff format --diff
8- ruff check
9- pyproject-pipenv
6+ uv run ruff format --diff
7+ uv run ruff check
108
119test :
1210 if [ -n " $( GITHUB_RUN_ID) " ]; then \
13- python -m pytest --cov --cov-report=xml --junitxml=junit.xml -o junit_family=legacy; \
11+ uv run pytest --cov --cov-report=xml --junitxml=junit.xml -o junit_family=legacy; \
1412 else \
15- python -m pytest --cov; \
13+ uv run pytest --cov; \
1614 fi
1715
1816test-e2e : export DD_INTEGRATION_TESTS=1
1917test-e2e :
20- python -m pytest tests/integration
18+ uv run pytest tests/integration
2119
2220testpub :
2321 rm -fr dist
24- pyproject-build
25- twine upload --repository testpypi dist/*
22+ uv run pyproject-build
23+ uv run twine upload --repository testpypi dist/*
2624
2725schema :
2826 ./support/openapi/fetch_openapi.py
Load Diff This file was deleted.
You can’t perform that action at this time.
0 commit comments