Skip to content

Commit

Permalink
Merge branch 'main' into index-repr
Browse files Browse the repository at this point in the history
  • Loading branch information
keewis committed Oct 4, 2022
2 parents 4292ab4 + 58ab594 commit 1d3db68
Show file tree
Hide file tree
Showing 90 changed files with 4,198 additions and 1,222 deletions.
7 changes: 0 additions & 7 deletions .coveragerc

This file was deleted.

86 changes: 86 additions & 0 deletions .github/labeler.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,86 @@
Automation:
- .github/*
- .github/**/*

CI:
- ci/*
- ci/**/*

dependencies:
- requirements.txt
- ci/requirements/*

topic-arrays:
- xarray/core/duck_array_ops.py

topic-backends:
- xarray/backends/*
- xarray/backends/**/*

topic-cftime:
- xarray/coding/*time*

topic-CF conventions:
- xarray/conventions.py

topic-combine:
- xarray/core/combine.py

topic-dask:
- xarray/core/dask*
- xarray/core/parallel.py

topic-DataTree:
- xarray/core/datatree*

# topic-documentation:
# - ['doc/*', '!doc/whats-new.rst']
# - doc/**/*

topic-faq:
- doc/howdoi.rst

topic-groupby:
- xarray/core/groupby.py

topic-html-repr:
- xarray/core/formatting_html.py

topic-hypothesis:
- xarray/properties/*
- xarray/testing/strategies/*

topic-indexing:
- xarray/core/indexes.py
- xarray/core/indexing.py

run-benchmark:
- asv_bench/benchmarks/*
- asv_bench/benchmarks/**/*

topic-performance:
- asv_bench/benchmarks/*
- asv_bench/benchmarks/**/*

topic-plotting:
- xarray/plot/*
- xarray/plot/**/*

topic-rolling:
- xarray/core/rolling.py
- xarray/core/rolling_exp.py

topic-testing:
- conftest.py
- xarray/testing.py
- xarray/testing/*

topic-typing:
- xarray/core/types.py

topic-zarr:
- xarray/backends/zarr.py

io:
- xarray/backends/*
- xarray/backends/**/*
18 changes: 9 additions & 9 deletions .github/workflows/benchmarks.yml
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,7 @@ jobs:
runs-on: ubuntu-20.04
env:
ASV_DIR: "./asv_bench"
CONDA_ENV_FILE: ci/requirements/environment.yml

steps:
# We need the full repo to avoid this issue
Expand All @@ -20,17 +21,16 @@ jobs:
with:
fetch-depth: 0

- name: Setup Miniconda
uses: conda-incubator/setup-miniconda@v2
- name: Set up conda environment
uses: mamba-org/provision-with-micromamba@v12
with:
# installer-url: https://github.com/conda-forge/miniforge/releases/latest/download/Mambaforge-Linux-x86_64.sh
installer-url: https://github.com/conda-forge/miniforge/releases/latest/download/Miniforge3-Linux-x86_64.sh
environment-file: ${{env.CONDA_ENV_FILE}}
environment-name: xarray-tests
cache-env: true
cache-env-key: "${{runner.os}}-${{runner.arch}}-py${{env.PYTHON_VERSION}}-${{env.TODAY}}-${{hashFiles(env.CONDA_ENV_FILE)}}-benchmark"
extra-specs: |
asv
- name: Setup some dependencies
shell: bash -l {0}
run: |
pip install asv
sudo apt-get update -y
- name: Run benchmarks
shell: bash -l {0}
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/ci.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -129,7 +129,7 @@ jobs:
path: pytest.xml

- name: Upload code coverage to Codecov
uses: codecov/[email protected].0
uses: codecov/[email protected].1
with:
file: ./coverage.xml
flags: unittests
Expand Down
14 changes: 14 additions & 0 deletions .github/workflows/label-all.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
name: "Issue and PR Labeler"
on:
pull_request:
types: [opened]
issues:
types: [opened, reopened]
jobs:
label-all-on-open:
runs-on: ubuntu-latest
steps:
- uses: andymckay/[email protected]
with:
add-labels: "needs triage"
ignore-if-labeled: false
12 changes: 12 additions & 0 deletions .github/workflows/label-prs.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
name: "PR Labeler"
on:
- pull_request_target

jobs:
label:
runs-on: ubuntu-latest
steps:
- uses: actions/labeler@main
with:
repo-token: "${{ secrets.GITHUB_TOKEN }}"
sync-labels: false
10 changes: 5 additions & 5 deletions .github/workflows/pypi-release.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -23,17 +23,17 @@ jobs:
- name: Install dependencies
run: |
python -m pip install --upgrade pip
python -m pip install setuptools setuptools-scm wheel twine check-manifest
python -m pip install build twine
- name: Build tarball and wheels
run: |
git clean -xdf
git restore -SW .
python -m build --sdist --wheel .
python -m build
- name: Check built artifacts
run: |
python -m twine check dist/*
python -m twine check --strict dist/*
pwd
if [ -f dist/xarray-0.0.0.tar.gz ]; then
echo "❌ INVALID VERSION NUMBER"
Expand Down Expand Up @@ -72,7 +72,7 @@ jobs:
- name: Publish package to TestPyPI
if: github.event_name == 'push'
uses: pypa/[email protected].0
uses: pypa/[email protected].1
with:
user: __token__
password: ${{ secrets.TESTPYPI_TOKEN }}
Expand All @@ -90,7 +90,7 @@ jobs:
name: releases
path: dist
- name: Publish package to PyPI
uses: pypa/[email protected].0
uses: pypa/[email protected].1
with:
user: __token__
password: ${{ secrets.PYPI_TOKEN }}
Expand Down
9 changes: 4 additions & 5 deletions .github/workflows/testpypi-release.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ jobs:
- name: Install dependencies
run: |
python -m pip install --upgrade pip
python -m pip install build setuptools setuptools-scm wheel twine check-manifest
python -m pip install build twine
python -m pip install tomli tomli_w
- name: Disable local versions
Expand All @@ -35,12 +35,11 @@ jobs:
- name: Build tarball and wheels
run: |
git clean -xdf
python -m build --sdist --wheel .
python -m build
- name: Check built artifacts
run: |
python -m twine check dist/*
pwd
python -m twine check --strict dist/*
if [ -f dist/xarray-0.0.0.tar.gz ]; then
echo "❌ INVALID VERSION NUMBER"
exit 1
Expand Down Expand Up @@ -79,7 +78,7 @@ jobs:
- name: Publish package to TestPyPI
if: github.event_name == 'push'
uses: pypa/[email protected].0
uses: pypa/[email protected].1
with:
user: __token__
password: ${{ secrets.TESTPYPI_TOKEN }}
Expand Down
14 changes: 7 additions & 7 deletions .pre-commit-config.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -9,8 +9,8 @@ repos:
- id: debug-statements
- id: mixed-line-ending
# This wants to go before isort & flake8
- repo: https://github.com/myint/autoflake
rev: "v1.4"
- repo: https://github.com/PyCQA/autoflake
rev: "v1.6.1"
hooks:
- id: autoflake # isort should run before black as black sometimes tweaks the isort output
args: ["--in-place", "--ignore-init-module-imports"]
Expand All @@ -19,25 +19,25 @@ repos:
hooks:
- id: isort
- repo: https://github.com/asottile/pyupgrade
rev: v2.37.1
rev: v2.38.2
hooks:
- id: pyupgrade
args:
- "--py38-plus"
# https://github.com/python/black#version-control-integration
- repo: https://github.com/psf/black
rev: 22.6.0
rev: 22.8.0
hooks:
- id: black
- id: black-jupyter
- repo: https://github.com/keewis/blackdoc
rev: v0.3.4
rev: v0.3.7
hooks:
- id: blackdoc
exclude: "generate_reductions.py"
additional_dependencies: ["black==22.3.0"]
- repo: https://github.com/PyCQA/flake8
rev: 4.0.1
rev: 5.0.4
hooks:
- id: flake8
# - repo: https://github.com/Carreau/velin
Expand All @@ -46,7 +46,7 @@ repos:
# - id: velin
# args: ["--write", "--compact"]
- repo: https://github.com/pre-commit/mirrors-mypy
rev: v0.961
rev: v0.981
hooks:
- id: mypy
# Copied from setup.cfg
Expand Down
5 changes: 4 additions & 1 deletion CITATION.cff
Original file line number Diff line number Diff line change
Expand Up @@ -76,8 +76,11 @@ authors:
given-names: "Phillip J."
orcid: "https://orcid.org/0000-0001-5971-4241"
title: "xarray"
abstract: "N-D labeled arrays and datasets in Python."
license: Apache-2.0
doi: 10.5281/zenodo.598201
url: "https://github.com/pydata/xarray"
url: "https://xarray.dev/"
repository-code: "https://github.com/pydata/xarray"
preferred-citation:
type: article
authors:
Expand Down
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -68,7 +68,7 @@ notebook](https://mybinder.org/v2/gh/pydata/xarray/main?urlpath=lab/tree/doc/exa

You can find information about contributing to xarray at our
[Contributing
page](https://docs.xarray.dev/en/latest/contributing.html#).
page](https://docs.xarray.dev/en/stable/contributing.html).

## Get in touch

Expand Down
2 changes: 1 addition & 1 deletion ci/requirements/environment-windows.yml
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@ dependencies:
- pip
- pre-commit
- pseudonetcdf
# - pydap # https://github.com/pydap/pydap/pull/210
- pydap
# - pynio # Not available on Windows
- pytest
- pytest-cov
Expand Down
2 changes: 1 addition & 1 deletion ci/requirements/environment.yml
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@ dependencies:
- pooch
- pre-commit
- pseudonetcdf
# - pydap # https://github.com/pydap/pydap/pull/210
- pydap
# - pynio: not compatible with netCDF4>1.5.3; only tested in py37-bare-minimum
- pytest
- pytest-cov
Expand Down
4 changes: 2 additions & 2 deletions ci/requirements/min-all-deps.yml
Original file line number Diff line number Diff line change
Expand Up @@ -15,8 +15,8 @@ dependencies:
- cfgrib=0.9
- cftime=1.4
- coveralls
- dask-core=2021.04
- distributed=2021.04
- dask-core=2021.08.0
- distributed=2021.08.0
- flox=0.5
- h5netcdf=0.11
- h5py=3.1
Expand Down
Loading

0 comments on commit 1d3db68

Please sign in to comment.