StingraySoftware / stingray

Anything can happen in the next half hour (including spectral timing made easy)!

Home Page:https://stingray.science/stingray

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Error running Stingray test suite

mckinley-brumback opened this issue · comments

After building a new conda stingray environment via the following:

conda create -n stingray1139 python=3.9
conda install -c conda-forge stingray
pip install hendrics numba emcee statsmodels netcdf4 matplotlib
conda install -c conda-forge pytest-astropy

I ran the stingray test suite with:

python -c 'import stingray; stingray.test()'

The test suite started, but quickly broke out with an error about deprecated language in Astropy. The full terminal output is attached (stingray_test_errors.txt). Run on a MacBook Pro 2019 with OS 10.15 (Catalina).
stingray_test_errors.txt

I'd be happy to work on this issue.

In the error log it can be seen that this was an error in the pytest_astropy_header package:

INTERNALERROR>   File "/Users/mbrumback/miniconda3/envs/stingray1139/lib/python3.9/site-packages/pytest_astropy_header/display.py", line 149, in pytest_report_header
INTERNALERROR>     with ignore_warnings(DeprecationWarning):
INTERNALERROR>   File "/Users/mbrumback/miniconda3/envs/stingray1139/lib/python3.9/site-packages/astropy/utils/decorators.py", line 122, in deprecated_func
INTERNALERROR>     warnings.warn(message, category, stacklevel=2)
INTERNALERROR> astropy.utils.exceptions.AstropyDeprecationWarning: The ignore_warnings class is deprecated and may be removed in a future version.
INTERNALERROR>         Use pytest.mark.filterwarnings instead.

These deprecated functions were removed in this commit.

The commit was included in pytest-astropy-header releases 0.2.0 onwards.

I successfully ran stingray.test with the pytest-astropy-header 0.2.0, 0.2.1 and 0.2.2.

I think we can close this issue.