-
-
Notifications
You must be signed in to change notification settings - Fork 1.1k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge branch 'main' into nanoseconds-resolution
- Loading branch information
Showing
117 changed files
with
7,591 additions
and
1,745 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -53,15 +53,15 @@ jobs: | |
echo "TODAY=$(date +'%Y-%m-%d')" >> $GITHUB_ENV | ||
- name: Setup micromamba | ||
uses: mamba-org/provision-with-micromamba@v15 | ||
uses: mamba-org/setup-micromamba@v1 | ||
with: | ||
environment-file: ${{env.CONDA_ENV_FILE}} | ||
environment-name: xarray-tests | ||
extra-specs: | | ||
create-args: >- | ||
python=${{env.PYTHON_VERSION}} | ||
conda | ||
cache-env: true | ||
cache-env-key: "${{runner.os}}-${{runner.arch}}-py${{env.PYTHON_VERSION}}-${{env.TODAY}}-${{hashFiles(env.CONDA_ENV_FILE)}}" | ||
cache-environment: true | ||
cache-environment-key: "${{runner.os}}-${{runner.arch}}-py${{env.PYTHON_VERSION}}-${{env.TODAY}}-${{hashFiles(env.CONDA_ENV_FILE)}}" | ||
|
||
- name: Install xarray | ||
run: | | ||
|
@@ -100,15 +100,15 @@ jobs: | |
run: | | ||
echo "TODAY=$(date +'%Y-%m-%d')" >> $GITHUB_ENV | ||
- name: Setup micromamba | ||
uses: mamba-org/provision-with-micromamba@v15 | ||
uses: mamba-org/setup-micromamba@v1 | ||
with: | ||
environment-file: ${{env.CONDA_ENV_FILE}} | ||
environment-name: xarray-tests | ||
extra-specs: | | ||
create-args: >- | ||
python=${{env.PYTHON_VERSION}} | ||
conda | ||
cache-env: true | ||
cache-env-key: "${{runner.os}}-${{runner.arch}}-py${{env.PYTHON_VERSION}}-${{env.TODAY}}-${{hashFiles(env.CONDA_ENV_FILE)}}" | ||
cache-environment: true | ||
cache-environment-key: "${{runner.os}}-${{runner.arch}}-py${{env.PYTHON_VERSION}}-${{env.TODAY}}-${{hashFiles(env.CONDA_ENV_FILE)}}" | ||
- name: Install xarray | ||
run: | | ||
python -m pip install --no-deps -e . | ||
|
@@ -126,7 +126,7 @@ jobs: | |
python -m mypy --install-types --non-interactive --cobertura-xml-report mypy_report | ||
- name: Upload mypy coverage to Codecov | ||
uses: codecov/[email protected].3 | ||
uses: codecov/[email protected].4 | ||
with: | ||
file: mypy_report/cobertura.xml | ||
flags: mypy | ||
|
@@ -154,15 +154,15 @@ jobs: | |
run: | | ||
echo "TODAY=$(date +'%Y-%m-%d')" >> $GITHUB_ENV | ||
- name: Setup micromamba | ||
uses: mamba-org/provision-with-micromamba@v15 | ||
uses: mamba-org/setup-micromamba@v1 | ||
with: | ||
environment-file: ${{env.CONDA_ENV_FILE}} | ||
environment-name: xarray-tests | ||
extra-specs: | | ||
create-args: >- | ||
python=${{env.PYTHON_VERSION}} | ||
conda | ||
cache-env: true | ||
cache-env-key: "${{runner.os}}-${{runner.arch}}-py${{env.PYTHON_VERSION}}-${{env.TODAY}}-${{hashFiles(env.CONDA_ENV_FILE)}}" | ||
cache-environment: true | ||
cache-environment-key: "${{runner.os}}-${{runner.arch}}-py${{env.PYTHON_VERSION}}-${{env.TODAY}}-${{hashFiles(env.CONDA_ENV_FILE)}}" | ||
- name: Install xarray | ||
run: | | ||
python -m pip install --no-deps -e . | ||
|
@@ -180,7 +180,7 @@ jobs: | |
python -m mypy --install-types --non-interactive --cobertura-xml-report mypy_report | ||
- name: Upload mypy coverage to Codecov | ||
uses: codecov/[email protected].3 | ||
uses: codecov/[email protected].4 | ||
with: | ||
file: mypy_report/cobertura.xml | ||
flags: mypy39 | ||
|
@@ -210,16 +210,14 @@ jobs: | |
fetch-depth: 0 # Fetch all history for all branches and tags. | ||
|
||
- name: Setup micromamba | ||
uses: mamba-org/provision-with-micromamba@v15 | ||
uses: mamba-org/setup-micromamba@v1 | ||
with: | ||
environment-name: xarray-tests | ||
environment-file: false | ||
extra-specs: | | ||
create-args: >- | ||
python=3.10 | ||
pyyaml | ||
conda | ||
python-dateutil | ||
channels: conda-forge | ||
- name: minimum versions policy | ||
run: | | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -92,13 +92,13 @@ jobs: | |
echo "PYTHON_VERSION=${{ matrix.python-version }}" >> $GITHUB_ENV | ||
- name: Setup micromamba | ||
uses: mamba-org/provision-with-micromamba@v15 | ||
uses: mamba-org/setup-micromamba@v1 | ||
with: | ||
environment-file: ${{ env.CONDA_ENV_FILE }} | ||
environment-name: xarray-tests | ||
cache-env: true | ||
cache-env-key: "${{runner.os}}-${{runner.arch}}-py${{matrix.python-version}}-${{env.TODAY}}-${{hashFiles(env.CONDA_ENV_FILE)}}" | ||
extra-specs: | | ||
cache-environment: true | ||
cache-environment-key: "${{runner.os}}-${{runner.arch}}-py${{matrix.python-version}}-${{env.TODAY}}-${{hashFiles(env.CONDA_ENV_FILE)}}" | ||
create-args: >- | ||
python=${{matrix.python-version}} | ||
conda | ||
|
@@ -139,7 +139,7 @@ jobs: | |
path: pytest.xml | ||
|
||
- name: Upload code coverage to Codecov | ||
uses: codecov/[email protected].3 | ||
uses: codecov/[email protected].4 | ||
with: | ||
file: ./coverage.xml | ||
flags: unittests | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,44 @@ | ||
name: Upload nightly wheels | ||
on: | ||
workflow_dispatch: | ||
schedule: | ||
- cron: "0 0 * * *" | ||
jobs: | ||
cron: | ||
runs-on: ubuntu-latest | ||
if: github.repository == 'pydata/xarray' | ||
steps: | ||
- uses: actions/checkout@v3 | ||
with: | ||
fetch-depth: 0 | ||
- uses: actions/setup-python@v4 | ||
with: | ||
python-version: "3.11" | ||
|
||
- name: Install dependencies | ||
run: | | ||
python -m pip install --upgrade pip | ||
python -m pip install build twine | ||
- name: Build tarball and wheels | ||
run: | | ||
git clean -xdf | ||
git restore -SW . | ||
python -m build | ||
- name: Check built artifacts | ||
run: | | ||
python -m twine check --strict dist/* | ||
pwd | ||
if [ -f dist/xarray-0.0.0.tar.gz ]; then | ||
echo "❌ INVALID VERSION NUMBER" | ||
exit 1 | ||
else | ||
echo "✅ Looks good" | ||
fi | ||
- name: Upload wheel | ||
uses: scientific-python/upload-nightly-action@main | ||
with: | ||
anaconda_nightly_upload_token: ${{ secrets.ANACONDA_NIGHTLY }} | ||
artifacts_path: dist |
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -70,12 +70,26 @@ jobs: | |
python -m pip install dist/xarray*.whl | ||
python -m xarray.util.print_versions | ||
upload-to-test-pypi: | ||
needs: test-built-dist | ||
if: github.event_name == 'push' | ||
runs-on: ubuntu-latest | ||
|
||
environment: | ||
name: pypi | ||
url: https://test.pypi.org/p/xarray | ||
permissions: | ||
id-token: write | ||
|
||
steps: | ||
- uses: actions/download-artifact@v3 | ||
with: | ||
name: releases | ||
path: dist | ||
- name: Publish package to TestPyPI | ||
if: github.event_name == 'push' | ||
uses: pypa/[email protected].5 | ||
uses: pypa/[email protected].10 | ||
with: | ||
user: __token__ | ||
password: ${{ secrets.TESTPYPI_TOKEN }} | ||
repository_url: https://test.pypi.org/legacy/ | ||
verbose: true | ||
|
||
|
@@ -84,14 +98,19 @@ jobs: | |
needs: test-built-dist | ||
if: github.event_name == 'release' | ||
runs-on: ubuntu-latest | ||
|
||
environment: | ||
name: pypi | ||
url: https://pypi.org/p/xarray | ||
permissions: | ||
id-token: write | ||
|
||
steps: | ||
- uses: actions/download-artifact@v3 | ||
with: | ||
name: releases | ||
path: dist | ||
- name: Publish package to PyPI | ||
uses: pypa/[email protected].5 | ||
uses: pypa/[email protected].10 | ||
with: | ||
user: __token__ | ||
password: ${{ secrets.PYPI_TOKEN }} | ||
verbose: true |
Oops, something went wrong.