-
Notifications
You must be signed in to change notification settings - Fork 16
Update workflow to use uv and Python 3.10 #227
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
Changes from 9 commits
c8478bd
19b2372
250dc09
120fdd8
5f3174c
cc58473
89e2d73
4ce1dd5
9a30e1d
b812943
a3efe39
6d2f9e0
edc14c6
1c70784
1689341
8826371
3de8c71
287d1f7
dd45c15
45456bc
65cf8c0
57be2ca
7b2cd4b
d385518
53975e3
d4e9c6c
277c8e3
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -24,10 +24,10 @@ jobs: | |
| runs-on: ubuntu-latest | ||
| steps: | ||
| - uses: actions/checkout@v3 | ||
| - name: Set up Python 3.9 | ||
| - name: Set up Python 3.10 | ||
| uses: actions/setup-python@v3 | ||
| with: | ||
| python-version: "3.9" | ||
| python-version: "3.10" | ||
|
|
||
| - name: Configure AWS | ||
| run: | | ||
|
|
@@ -38,11 +38,15 @@ jobs: | |
| - name: Install dependencies | ||
| run: | | ||
| python -m pip install --upgrade pip | ||
| pip install -e ./forcingprocessor | ||
| pip install pytest | ||
| pip install uv | ||
| uv venv | ||
| source .venv/bin/activate | ||
| uv pip install -e ./forcingprocessor | ||
| uv pip install pytest | ||
|
Comment on lines
+41
to
+45
|
||
|
|
||
| - name: Test with pytest | ||
| run: | | ||
| source .venv/bin/activate | ||
| cd forcingprocessor | ||
| python -m pytest -vv -k test_google_cloud_storage | ||
| python -m pytest -vv -k test_gs | ||
|
|
||
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -24,10 +24,10 @@ jobs: | |
| runs-on: ubuntu-latest | ||
| steps: | ||
| - uses: actions/checkout@v3 | ||
| - name: Set up Python 3.9 | ||
| - name: Set up Python 3.10 | ||
| uses: actions/setup-python@v3 | ||
| with: | ||
| python-version: "3.9" | ||
| python-version: "3.10" | ||
|
|
||
| - name: Configure AWS | ||
| run: | | ||
|
|
@@ -38,11 +38,15 @@ jobs: | |
| - name: Install dependencies | ||
| run: | | ||
| python -m pip install --upgrade pip | ||
| pip install -e ./forcingprocessor | ||
| pip install pytest | ||
| pip install uv | ||
| uv venv | ||
| source .venv/bin/activate | ||
| uv pip install -e ./forcingprocessor | ||
| uv pip install pytest | ||
|
Comment on lines
+41
to
+45
|
||
|
|
||
| - name: Test with pytest | ||
| run: | | ||
| source .venv/bin/activate | ||
| cd forcingprocessor | ||
| # netcdf already tested | ||
| python -m pytest -vv -k test_csv_output_type | ||
|
|
||
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -24,10 +24,10 @@ jobs: | |
| runs-on: ubuntu-latest | ||
| steps: | ||
| - uses: actions/checkout@v3 | ||
| - name: Set up Python 3.9 | ||
| - name: Set up Python 3.10 | ||
| uses: actions/setup-python@v3 | ||
| with: | ||
| python-version: "3.9" | ||
| python-version: "3.10" | ||
|
|
||
| - name: Configure AWS | ||
| run: | | ||
|
|
@@ -38,11 +38,15 @@ jobs: | |
| - name: Install dependencies | ||
| run: | | ||
| python -m pip install --upgrade pip | ||
| pip install -e ./forcingprocessor | ||
| pip install pytest | ||
| pip install uv | ||
| uv venv | ||
| source .venv/bin/activate | ||
| uv pip install -e ./forcingprocessor | ||
| uv pip install pytest | ||
|
Comment on lines
+41
to
+45
|
||
|
|
||
| - name: Test with pytest | ||
| run: | | ||
| source .venv/bin/activate | ||
| cd forcingprocessor | ||
| python -m pytest -vv tests/test_plotter.py | ||
| python -m pytest -vv -k test_plotting | ||
|
|
||
| Original file line number | Diff line number | Diff line change | ||||||||||||||||||||||||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
|
|
@@ -24,10 +24,10 @@ jobs: | |||||||||||||||||||||||||||||||||
| runs-on: ubuntu-latest | ||||||||||||||||||||||||||||||||||
| steps: | ||||||||||||||||||||||||||||||||||
| - uses: actions/checkout@v3 | ||||||||||||||||||||||||||||||||||
| - name: Set up Python 3.9 | ||||||||||||||||||||||||||||||||||
| - name: Set up Python 3.10 | ||||||||||||||||||||||||||||||||||
| uses: actions/setup-python@v3 | ||||||||||||||||||||||||||||||||||
| with: | ||||||||||||||||||||||||||||||||||
| python-version: "3.9" | ||||||||||||||||||||||||||||||||||
| python-version: "3.10" | ||||||||||||||||||||||||||||||||||
|
|
||||||||||||||||||||||||||||||||||
| - name: Configure AWS | ||||||||||||||||||||||||||||||||||
| run: | | ||||||||||||||||||||||||||||||||||
|
|
@@ -38,10 +38,14 @@ jobs: | |||||||||||||||||||||||||||||||||
| - name: Install dependencies | ||||||||||||||||||||||||||||||||||
| run: | | ||||||||||||||||||||||||||||||||||
| python -m pip install --upgrade pip | ||||||||||||||||||||||||||||||||||
| pip install -e ./forcingprocessor | ||||||||||||||||||||||||||||||||||
| pip install pytest | ||||||||||||||||||||||||||||||||||
| pip install uv | ||||||||||||||||||||||||||||||||||
| uv venv | ||||||||||||||||||||||||||||||||||
| source .venv/bin/activate | ||||||||||||||||||||||||||||||||||
| uv pip install -e ./forcingprocessor | ||||||||||||||||||||||||||||||||||
| uv pip install pytest | ||||||||||||||||||||||||||||||||||
|
|
||||||||||||||||||||||||||||||||||
| - name: Test with hf2ds | ||||||||||||||||||||||||||||||||||
| run: | | ||||||||||||||||||||||||||||||||||
| source .venv/bin/activate | ||||||||||||||||||||||||||||||||||
| cd forcingprocessor | ||||||||||||||||||||||||||||||||||
| python -m pytest -vv tests/test_hf2ds.py | ||||||||||||||||||||||||||||||||||
|
Comment on lines
+43
to
51
|
||||||||||||||||||||||||||||||||||
| source .venv/bin/activate | |
| uv pip install -e ./forcingprocessor | |
| uv pip install pytest | |
| - name: Test with hf2ds | |
| run: | | |
| source .venv/bin/activate | |
| cd forcingprocessor | |
| python -m pytest -vv tests/test_hf2ds.py | |
| uv pip install -e ./forcingprocessor | |
| uv pip install pytest | |
| - name: Test with hf2ds | |
| run: | | |
| cd forcingprocessor | |
| uv run python -m pytest -vv tests/test_hf2ds.py |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The virtual environment activation command
source .venv/bin/activatemay not persist between shell commands in GitHub Actions. Consider usinguv runinstead of manual activation, or ensure each command that needs the virtual environment includes the activation in the same step.