Skip to content

Commit ed8aa66

Browse files
author
Joe Hamman
authored
Merge branch 'main' into loader/torch
2 parents 6104bf3 + 802bbd5 commit ed8aa66

File tree

8 files changed

+3181
-48
lines changed

8 files changed

+3181
-48
lines changed

.github/workflows/main.yaml

Lines changed: 14 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -9,27 +9,20 @@ on:
99
- cron: "0 0 * * *"
1010

1111
jobs:
12-
lint:
13-
runs-on: ubuntu-latest
14-
steps:
15-
- uses: actions/[email protected]
16-
- uses: actions/[email protected]
17-
- uses: pre-commit/[email protected]
18-
1912
test:
2013
name: ${{ matrix.python-version }}-build
2114
runs-on: ubuntu-latest
2215
strategy:
2316
matrix:
2417
python-version: [3.7, 3.8, 3.9]
2518
steps:
26-
- uses: actions/checkout@v2.3.4
19+
- uses: actions/checkout@v2.4.0
2720
- name: Setup Python
28-
uses: actions/setup-python@v2.2.2
21+
uses: actions/setup-python@v2.3.2
2922
with:
3023
python-version: ${{ matrix.python-version }}
3124
architecture: x64
32-
- uses: actions/[email protected].6
25+
- uses: actions/[email protected].7
3326
with:
3427
path: ~/.cache/pip
3528
key: ${{ runner.os }}-pip-${{ hashFiles('**/dev-requirements.txt') }}
@@ -41,7 +34,13 @@ jobs:
4134
python -m pip list
4235
- name: Running Tests
4336
run: |
44-
python -m pytest --verbose
37+
py.test --verbose --cov=. --cov-report=xml
38+
- name: Upload coverage to Codecov
39+
uses: codecov/[email protected]
40+
if: ${{ matrix.python-version }} == 3.9
41+
with:
42+
file: ./coverage.xml
43+
fail_ci_if_error: false
4544

4645
test-upstream:
4746
name: ${{ matrix.python-version }}-dev-build
@@ -50,13 +49,13 @@ jobs:
5049
matrix:
5150
python-version: [3.8, 3.9]
5251
steps:
53-
- uses: actions/checkout@v2.3.4
52+
- uses: actions/checkout@v2.4.0
5453
- name: Setup Python
55-
uses: actions/setup-python@v2.2.2
54+
uses: actions/setup-python@v2.3.2
5655
with:
5756
python-version: ${{ matrix.python-version }}
5857
architecture: x64
59-
- uses: actions/[email protected].6
58+
- uses: actions/[email protected].7
6059
with:
6160
path: ~/.cache/pip
6261
key: ${{ runner.os }}-pip-${{ hashFiles('**/dev-requirements.txt') }}
@@ -71,4 +70,4 @@ jobs:
7170
python -m pip list
7271
- name: Running Tests
7372
run: |
74-
python -m pytest --verbose
73+
py.test --verbose --cov=.

.pre-commit-config.yaml

Lines changed: 12 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,10 @@
1+
ci:
2+
autoupdate_schedule: quarterly
3+
autofix_prs: false
4+
15
repos:
26
- repo: https://github.com/pre-commit/pre-commit-hooks
3-
rev: v4.0.1
7+
rev: v4.1.0
48
hooks:
59
- id: trailing-whitespace
610
- id: end-of-file-fixer
@@ -9,27 +13,27 @@ repos:
913
- id: check-yaml
1014
- id: double-quote-string-fixer
1115

12-
- repo: https://github.com/ambv/black
13-
rev: 21.5b2
16+
- repo: https://github.com/psf/black
17+
rev: 21.12b0
1418
hooks:
1519
- id: black
1620
args: ["--line-length", "80", "--skip-string-normalization"]
1721

18-
- repo: https://gitlab.com/pycqa/flake8
19-
rev: 3.9.2
22+
- repo: https://github.com/PyCQA/flake8
23+
rev: 4.0.1
2024
hooks:
2125
- id: flake8
2226
- repo: https://github.com/asottile/seed-isort-config
2327
rev: v2.2.0
2428
hooks:
2529
- id: seed-isort-config
26-
- repo: https://github.com/pre-commit/mirrors-isort
27-
rev: v5.8.0
30+
- repo: https://github.com/PyCQA/isort
31+
rev: 5.10.1
2832
hooks:
2933
- id: isort
3034

3135
- repo: https://github.com/pre-commit/mirrors-prettier
32-
rev: v2.2.0
36+
rev: v2.5.1
3337
hooks:
3438
- id: prettier
3539
language_version: system

README.rst

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
xbatcher: Batch Generation from Xarray Datasets
22
===============================================
33

4-
|Build Status| |codecov| |docs| |license|
4+
|Build Status| |codecov| |docs| |pypi| |license|
55

66

77
Xbatcher is a small library for iterating xarray DataArrays in batches. The
@@ -19,6 +19,10 @@ such as Keras_. View the |docs| for more info.
1919
:alt: code coverage
2020
.. |docs| image:: http://readthedocs.org/projects/xbatcher/badge/?version=latest
2121
:target: http://xbatcher.readthedocs.org/en/latest/?badge=latest
22+
:alt: docs
23+
.. |pypi| image:: https://img.shields.io/pypi/v/xbatcher.svg
24+
:target: https://pypi.python.org/pypi/xbatcher
25+
:alt: pypi
2226
.. |license| image:: https://img.shields.io/github/license/mashape/apistatus.svg
2327
:target: https://github.com/pangeo-data/xbatcher
2428
:alt: license

dev-requirements.txt

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,6 @@
11
pytest
22
torch
33
coverage
4+
pytest-cov
5+
adlfs
46
-r requirements.txt

0 commit comments

Comments
 (0)