From 9d3413c568887c538fb30951ac180004ededaad2 Mon Sep 17 00:00:00 2001 From: Jeff Klenzing Date: Fri, 1 Dec 2023 10:29:00 -0500 Subject: [PATCH 01/11] MAINT: update workflows --- .github/workflows/main.yml | 15 ++++++++++++++- .github/workflows/pysat_rc.yml | 19 +++++++++++++++---- 2 files changed, 29 insertions(+), 5 deletions(-) diff --git a/.github/workflows/main.yml b/.github/workflows/main.yml index 99cfc2e..2de4c12 100644 --- a/.github/workflows/main.yml +++ b/.github/workflows/main.yml @@ -17,7 +17,7 @@ jobs: test_config: ["latest"] include: - python-version: "3.9" - numpy_ver: "1.21" + numpy_ver: "1.22" os: ubuntu-latest test_config: "NEP29" - python-version: "3.6.8" @@ -69,4 +69,17 @@ jobs: - name: Publish results to coveralls env: GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} + COVERALLS_PARALLEL: true run: coveralls --rcfile=pyproject.toml --service=github + + finish: + name: Finish Coverage Analysis + needs: build + runs-on: ubuntu-latest + steps: + - name: Coveralls Finished + env: + GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} + run: | + pip install --upgrade coveralls + coveralls --service=github --finish diff --git a/.github/workflows/pysat_rc.yml b/.github/workflows/pysat_rc.yml index 00e16a0..30f8647 100644 --- a/.github/workflows/pysat_rc.yml +++ b/.github/workflows/pysat_rc.yml @@ -11,7 +11,7 @@ jobs: fail-fast: false matrix: os: [ubuntu-latest, macos-latest, windows-latest] - python-version: ["3.10"] + python-version: ["3.11"] name: Python ${{ matrix.python-version }} on ${{ matrix.os }} runs-on: ${{ matrix.os }} @@ -26,9 +26,7 @@ jobs: run: pip install --no-deps --pre -i https://test.pypi.org/simple/ --extra-index-url https://pypi.org/simple/ pysat - name: Install standard dependencies - run: | - pip install -r requirements.txt - pip install -r test_requirements.txt + run: pip install .[test] - name: Set up pysat run: | @@ -41,4 +39,17 @@ jobs: - name: Publish results to coveralls env: GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} + COVERALLS_PARALLEL: true run: coveralls --rcfile=pyproject.toml --service=github + + finish: + name: Finish Coverage Analysis + needs: build + runs-on: ubuntu-latest + steps: + - name: Coveralls Finished + env: + GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} + run: | + pip install --upgrade coveralls + coveralls --service=github --finish From 2e3965d4c19d01e7d9072e78b169ef8af92b01d4 Mon Sep 17 00:00:00 2001 From: Jeff Klenzing Date: Fri, 1 Dec 2023 10:32:03 -0500 Subject: [PATCH 02/11] DOC: update changelog --- CHANGELOG.md | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/CHANGELOG.md b/CHANGELOG.md index 192e083..8bb8e8e 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -2,6 +2,10 @@ All notable changes to this project will be documented in this file. This project adheres to [Semantic Versioning](http://semver.org/). +## [0.0.5] - 202X-XX-XX +* Maintenance + * Update GitHub Actions standards + ## [0.0.4] - 2023-08-11 * Bug fixes * Update metadata transfer for COSMIC GPS From 62087c8597bdaf519460b10d98e0c9d9a1ec3dfa Mon Sep 17 00:00:00 2001 From: Jeff Klenzing Date: Fri, 1 Dec 2023 10:48:52 -0500 Subject: [PATCH 03/11] MAINT: version cap for sphinx rtd theme --- pyproject.toml | 2 +- test_requirements.txt | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/pyproject.toml b/pyproject.toml index 446dbd2..23f72d2 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -61,7 +61,7 @@ doc = [ "numpydoc", "sphinx < 7.0", "sphinx-autoapi", - "sphinx_rtd_theme >= 1.2.2" + "sphinx_rtd_theme >= 1.2.2, <2.0.0" ] [project.urls] diff --git a/test_requirements.txt b/test_requirements.txt index 97d94a7..e9de40c 100644 --- a/test_requirements.txt +++ b/test_requirements.txt @@ -10,4 +10,4 @@ pytest-cov pytest-ordering sphinx sphinx-autoapi -sphinx_rtd_theme +sphinx_rtd_theme<2.0.0 From af8d25731994cd4571a49f6edf5b5af609122543 Mon Sep 17 00:00:00 2001 From: Jeff Klenzing Date: Fri, 1 Dec 2023 11:07:08 -0500 Subject: [PATCH 04/11] MAINT: pysat 3.2.0 compat --- pysatCDAAC/instruments/cosmic_gps.py | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/pysatCDAAC/instruments/cosmic_gps.py b/pysatCDAAC/instruments/cosmic_gps.py index f72f5b8..5c327ae 100644 --- a/pysatCDAAC/instruments/cosmic_gps.py +++ b/pysatCDAAC/instruments/cosmic_gps.py @@ -266,7 +266,9 @@ def list_files(tag=None, inst_id=None, data_path=None, format_str=None): stored = futils.parse_fixed_width_filenames(files, format_str) # Process info - if len(stored['year']) > 0: + # Check on length for backward compat with pysat 3.1.0 + # TODO(#51): Can be removed after 3.2.0 release and minimum version is set. + if stored['year'] is not None and len(stored['year']) > 0: year = np.array(stored['year']) day = np.array(stored['day']) hour = np.array(stored['hour']) From 1c682e72a816de79d58916dbd236c71795cd4aaf Mon Sep 17 00:00:00 2001 From: Jeff Klenzing Date: Tue, 20 Feb 2024 10:53:26 -0500 Subject: [PATCH 05/11] MAINT: turn off new tests for gps --- pysatCDAAC/instruments/cosmic_gps.py | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/pysatCDAAC/instruments/cosmic_gps.py b/pysatCDAAC/instruments/cosmic_gps.py index 5c327ae..8edc5ab 100644 --- a/pysatCDAAC/instruments/cosmic_gps.py +++ b/pysatCDAAC/instruments/cosmic_gps.py @@ -108,7 +108,10 @@ # ---------------------------------------------------------------------------- # Instrument test attributes -_test_dates = {'': {}.fromkeys(list(tags.keys()), dt.datetime(2014, 5, 1))} +_test_dates = {'': {tag: dt.datetime(2014, 5, 1) for tag in inst_ids['']}} + +# TODO(#TBD): Remove when compliant with multi-day load tests +_new_tests = {'': {tag: False for tag in inst_ids['']}} # ---------------------------------------------------------------------------- # Instrument methods From 7ffde7c4722d5a092eca953c24cfb79340c2263e Mon Sep 17 00:00:00 2001 From: Jeff Klenzing Date: Tue, 20 Feb 2024 11:20:31 -0500 Subject: [PATCH 06/11] MAINT: set version limit for pysat --- README.md | 14 +++++++------- docs/installation.rst | 8 ++++---- pyproject.toml | 2 +- 3 files changed, 12 insertions(+), 12 deletions(-) diff --git a/README.md b/README.md index 759558c..5a1c029 100644 --- a/README.md +++ b/README.md @@ -15,13 +15,13 @@ pysatCDAAC uses common Python modules, as well as modules developed by and for the Space Physics community. This module officially supports Python 3.7+. -| Common modules | Community modules | -| -------------- | ----------------- | -| netCDF4 | pysat>=3.0.4 | -| numpy | | -| pandas | | -| requests | | -| xarray | | +| Common modules | Community modules | +| -------------- | ------------------- | +| netCDF4 | pysat>=3.0.4,<3.2.0 | +| numpy | | +| pandas | | +| requests | | +| xarray | | # Installation diff --git a/docs/installation.rst b/docs/installation.rst index 9384557..0aa7021 100644 --- a/docs/installation.rst +++ b/docs/installation.rst @@ -16,15 +16,15 @@ pysatCDAAC uses common Python modules, as well as modules developed by and for the Space Physics community. This module officially supports Python 3.6+ and pysat 3.0.4+. - ================== ================= + ================== ==================== Common modules Community modules - ================== ================= - netCDF4 pysat>=3.0.4 + ================== ==================== + netCDF4 pysat>=3.0.4,<3.2.0 numpy pandas requests xarray - ================== ================= + ================== ==================== Installation Options diff --git a/pyproject.toml b/pyproject.toml index 23f72d2..45e7f45 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -39,7 +39,7 @@ dependencies = [ "netCDF4", "numpy", "pandas", - "pysat >= 3.0.4", + "pysat >= 3.0.4, <3.2.0", "requests", "xarray" ] From d1bafd1c442f34847f179d471cbbaeb39091d461 Mon Sep 17 00:00:00 2001 From: Jeff Klenzing Date: Tue, 20 Feb 2024 11:22:43 -0500 Subject: [PATCH 07/11] DOC: add issue to TBD --- pysatCDAAC/instruments/cosmic_gps.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pysatCDAAC/instruments/cosmic_gps.py b/pysatCDAAC/instruments/cosmic_gps.py index 8edc5ab..6c940c6 100644 --- a/pysatCDAAC/instruments/cosmic_gps.py +++ b/pysatCDAAC/instruments/cosmic_gps.py @@ -110,7 +110,7 @@ _test_dates = {'': {tag: dt.datetime(2014, 5, 1) for tag in inst_ids['']}} -# TODO(#TBD): Remove when compliant with multi-day load tests +# TODO(#51): Remove when compliant with multi-day load tests _new_tests = {'': {tag: False for tag in inst_ids['']}} # ---------------------------------------------------------------------------- From 37a3b89733bda6f7c6f6863695d8d6d0e0e53897 Mon Sep 17 00:00:00 2001 From: Jeff Klenzing Date: Tue, 20 Feb 2024 11:22:54 -0500 Subject: [PATCH 08/11] TST: verbose tests --- .github/workflows/pysat_rc.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/pysat_rc.yml b/.github/workflows/pysat_rc.yml index 30f8647..df66507 100644 --- a/.github/workflows/pysat_rc.yml +++ b/.github/workflows/pysat_rc.yml @@ -34,7 +34,7 @@ jobs: python -c "import pysat; pysat.params['data_dirs'] = 'pysatData'" - name: Test with pytest - run: pytest + run: pytest -v - name: Publish results to coveralls env: From 11e3bf6364e4bdd3333abc3b65116a9906824b18 Mon Sep 17 00:00:00 2001 From: Jeff Klenzing Date: Tue, 20 Feb 2024 11:24:38 -0500 Subject: [PATCH 09/11] MAINT: update GA versions --- .github/workflows/docs.yml | 4 ++-- .github/workflows/main.yml | 4 ++-- .github/workflows/pip_rc_install.yml | 4 ++-- .github/workflows/pysat_rc.yml | 4 ++-- 4 files changed, 8 insertions(+), 8 deletions(-) diff --git a/.github/workflows/docs.yml b/.github/workflows/docs.yml index a966471..249af8a 100644 --- a/.github/workflows/docs.yml +++ b/.github/workflows/docs.yml @@ -16,9 +16,9 @@ jobs: name: steps: - - uses: actions/checkout@v3 + - uses: actions/checkout@v4 - name: Set up Python ${{ matrix.python-version }} - uses: actions/setup-python@v4 + uses: actions/setup-python@v5 with: python-version: ${{ matrix.python-version }} diff --git a/.github/workflows/main.yml b/.github/workflows/main.yml index 2de4c12..868e5ea 100644 --- a/.github/workflows/main.yml +++ b/.github/workflows/main.yml @@ -28,9 +28,9 @@ jobs: name: Python ${{ matrix.python-version }} on ${{ matrix.os }} with numpy ${{ matrix.numpy_ver }} runs-on: ${{ matrix.os }} steps: - - uses: actions/checkout@v3 + - uses: actions/checkout@v4 - name: Set up Python ${{ matrix.python-version }} - uses: actions/setup-python@v4 + uses: actions/setup-python@v5 with: python-version: ${{ matrix.python-version }} diff --git a/.github/workflows/pip_rc_install.yml b/.github/workflows/pip_rc_install.yml index a72fff6..ff09596 100644 --- a/.github/workflows/pip_rc_install.yml +++ b/.github/workflows/pip_rc_install.yml @@ -17,9 +17,9 @@ jobs: name: Python ${{ matrix.python-version }} on ${{ matrix.os }} runs-on: ${{ matrix.os }} steps: - - uses: actions/checkout@v3 + - uses: actions/checkout@v4 - name: Set up Python ${{ matrix.python-version }} - uses: actions/setup-python@v4 + uses: actions/setup-python@v5 with: python-version: ${{ matrix.python-version }} diff --git a/.github/workflows/pysat_rc.yml b/.github/workflows/pysat_rc.yml index df66507..6d620cc 100644 --- a/.github/workflows/pysat_rc.yml +++ b/.github/workflows/pysat_rc.yml @@ -16,9 +16,9 @@ jobs: name: Python ${{ matrix.python-version }} on ${{ matrix.os }} runs-on: ${{ matrix.os }} steps: - - uses: actions/checkout@v3 + - uses: actions/checkout@v4 - name: Set up Python ${{ matrix.python-version }} - uses: actions/setup-python@v4 + uses: actions/setup-python@v5 with: python-version: ${{ matrix.python-version }} From 7aaf5eb056ed2046b60f6670ed6755072e92ca63 Mon Sep 17 00:00:00 2001 From: Jeff Klenzing <19592220+jklenzing@users.noreply.github.com> Date: Tue, 20 Feb 2024 12:22:55 -0500 Subject: [PATCH 10/11] Apply suggestions from code review Co-authored-by: Angeline Burrell --- .github/workflows/pysat_rc.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/pysat_rc.yml b/.github/workflows/pysat_rc.yml index 6d620cc..f8d9015 100644 --- a/.github/workflows/pysat_rc.yml +++ b/.github/workflows/pysat_rc.yml @@ -10,7 +10,7 @@ jobs: strategy: fail-fast: false matrix: - os: [ubuntu-latest, macos-latest, windows-latest] + os: ["ubuntu-latest", "macos-latest", "windows-latest"] python-version: ["3.11"] name: Python ${{ matrix.python-version }} on ${{ matrix.os }} @@ -25,7 +25,7 @@ jobs: - name: Install pysat RC run: pip install --no-deps --pre -i https://test.pypi.org/simple/ --extra-index-url https://pypi.org/simple/ pysat - - name: Install standard dependencies + - name: Install standard dependencies and package run: pip install .[test] - name: Set up pysat From b3c12e3862eead147f2ca8ace4b89a1d074f95d0 Mon Sep 17 00:00:00 2001 From: Jeff Klenzing <19592220+jklenzing@users.noreply.github.com> Date: Thu, 28 Mar 2024 11:13:19 -0400 Subject: [PATCH 11/11] Update NEP29 tests --- .github/workflows/main.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/main.yml b/.github/workflows/main.yml index 868e5ea..def9679 100644 --- a/.github/workflows/main.yml +++ b/.github/workflows/main.yml @@ -17,7 +17,7 @@ jobs: test_config: ["latest"] include: - python-version: "3.9" - numpy_ver: "1.22" + numpy_ver: "1.23" os: ubuntu-latest test_config: "NEP29" - python-version: "3.6.8"