diff --git a/.github/workflows/cron-tests.yml b/.github/workflows/cron-tests.yml index f27d44e1..a9296b51 100644 --- a/.github/workflows/cron-tests.yml +++ b/.github/workflows/cron-tests.yml @@ -28,11 +28,11 @@ jobs: python: '3.11' tox_env: 'linkcheck' - os: ubuntu-latest - python: '3.11' - tox_env: 'py310-test-datadeps-devdeps' + python: '3.12' + tox_env: 'py312-test-devdeps' - os: ubuntu-latest - python: '3.11' - tox_env: 'py310-test-datadeps-predeps' + python: '3.12' + tox_env: 'py312-test-predeps' steps: - name: Check out repository @@ -47,12 +47,6 @@ jobs: run: | python -m pip install --upgrade pip python -m pip install tox - - name: Print Python, pip, setuptools, and tox versions - run: | - python -c "import sys; print(f'Python {sys.version}')" - python -c "import pip; print(f'pip {pip.__version__}')" - python -c "import setuptools; print(f'setuptools {setuptools.__version__}')" - python -c "import tox; print(f'tox {tox.__version__}')" - name: Test with tox run: | tox -e ${{ matrix.tox_env }} diff --git a/.github/workflows/tox-tests.yml b/.github/workflows/tox-tests.yml index d4a69e69..7dbc35cf 100644 --- a/.github/workflows/tox-tests.yml +++ b/.github/workflows/tox-tests.yml @@ -33,18 +33,18 @@ jobs: include: - os: ubuntu-latest python: '3.10' - tox_env: 'py310-test' - - os: ubuntu-latest - python: '3.11' - tox_env: 'py311-test-cov' - - os: macos-latest - python: '3.11' - tox_env: 'py311-test-devdeps' + tox_env: 'py310-test-cov' - os: ubuntu-latest python: '3.11' tox_env: 'py311-test' - os: ubuntu-latest - python: '3.11' + python: '3.12' + tox_env: 'py312-test' + - os: macos-latest + python: '3.12' + tox_env: 'py312-test-devdeps' + - os: ubuntu-latest + python: '3.12' tox_env: 'codestyle' - os: ubuntu-latest python: '3.10' @@ -63,12 +63,6 @@ jobs: run: | python -m pip install --upgrade pip python -m pip install tox - - name: Print Python, pip, setuptools, and tox versions - run: | - python -c "import sys; print(f'Python {sys.version}')" - python -c "import pip; print(f'pip {pip.__version__}')" - python -c "import setuptools; print(f'setuptools {setuptools.__version__}')" - python -c "import tox; print(f'tox {tox.__version__}')" - name: Test with tox run: | tox -e ${{ matrix.tox_env }} diff --git a/pyproject.toml b/pyproject.toml index e169ae33..8c29294a 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -11,3 +11,7 @@ requires = ["setuptools", "cython"] build-backend = 'setuptools.build_meta' + +[tool.pytest.ini_options] + +filterwarnings = ["ignore::DeprecationWarning:datetime",] diff --git a/tox.ini b/tox.ini index 496bf5d0..b34a2710 100644 --- a/tox.ini +++ b/tox.ini @@ -1,12 +1,10 @@ [tox] envlist = - py{310,311}-test{,-devdeps}{,-cov} - py{310,311}-test-numpy{120,121,122,123} - py{310,311}-test-astropy{lts,rc} + py{310,311,312}-test{,-devdeps,-predeps}{,-cov} build_docs codestyle requires = - setuptools >= 30.3.0 + setuptools pip >= 19.3.1 isolated_build = true @@ -16,7 +14,8 @@ isolated_build = true passenv = HOME,WINDIR,LC_ALL,LC_CTYPE,CC,CI setenv = - devdeps: PIP_EXTRA_INDEX_URL = https://pypi.anaconda.org/scientific-python-nightly-wheels/simple + devdeps: PIP_EXTRA_INDEX_URL = https://pypi.anaconda.org/astropy/simple https://pypi.anaconda.org/scientific-python-nightly-wheels/simple + py312: PIP_EXTRA_INDEX_URL = https://pypi.anaconda.org/astropy/simple # Run the tests in a temporary directory to make sure that we don't import # this package from the source tree @@ -35,13 +34,12 @@ description = devdeps: with the latest developer version of key dependencies oldestdeps: with the oldest supported version of key dependencies cov: enable remote data and measure test coverage - numpy122: with numpy 1.22.* - numpy123: with numpy 1.23.* - astropylts: with the latest astropy LTS # The following provides some specific pinnings for key packages deps = + numpy120: numpy==1.20.* + numpy121: numpy==1.21.* numpy122: numpy==1.22.* numpy123: numpy==1.23.* @@ -49,22 +47,31 @@ deps = astropylts: astropy==5.1.* devdeps: numpy>=0.0.dev0 - devdeps: git+https://github.com/astropy/astropy.git#egg=astropy + devdeps: scipy>=0.0.dev0 + devdeps: astropy>=0.0.dev0 devdeps: git+https://github.com/astropy/specutils.git#egg=specutils + devdeps: git+https://github.com/astropy/photutils.git#egg=photutils - oldestdeps: numpy==1.22 + oldestdeps: numpy==1.22.4 oldestdeps: astropy==5.1 oldestdeps: scipy==1.9.0 oldestdeps: matplotlib==3.5 oldestdeps: photutils==1.0.0 oldestdeps: specutils==1.9.1 + # Currently need dev astropy with python 3.12 as well + py312: astropy>=0.0.dev0 + # The following indicates which extras_require from setup.cfg will be installed extras = test: test build_docs: docs commands = + # Force numpy-dev after matplotlib downgrades it (https://github.com/matplotlib/matplotlib/issues/26847) + devdeps: python -m pip install --pre --upgrade --extra-index-url https://pypi.anaconda.org/scientific-python-nightly-wheels/simple numpy + # Maybe we also have to do this for scipy? + devdeps: python -m pip install --pre --upgrade --extra-index-url https://pypi.anaconda.org/scientific-python-nightly-wheels/simple scipy pip freeze !cov: pytest --pyargs specreduce {toxinidir}/docs {posargs} cov: pytest --pyargs specreduce {toxinidir}/docs --cov specreduce --cov-config={toxinidir}/setup.cfg --remote-data {posargs}