NIST: query has different results when running directly vs in tests
- Dominant language
- Python
- Stars
- 791
- Forks
- 451
- Avg merge
- 1d 3h
- Merged PRs (30d)
- 4
Description
The following passes in the test suite without issues (`pytest astroquery/nist/tests/test_nist_remote.py::TestNist::test_query -R`), but has different result when running directly in a python session. Not sure the reason yet, but it can be investigated along with #2920
```
from astropy import units as u
from astroquery.nist import Nist
result = Nist.query(4000 * u.AA, 7000 * u.AA)
assert set(result['TP'].filled()) == set(['T8637', 'T7771', 'N/A'])
```
Note the extra `'T7651'` in the local results:
```
>>> set(result['TP'].filled())
{np.str_('N/A'), np.str_('T7651'), np.str_('T7771'), np.str_('T8637')}
```
Contributor guide
Research direction
Start with astroquery/nist/tests/test_nist_remote.py::TestNist::test_query and compare its pytest result with an interactive Nist.query(4000 * u.AA, 7000 * u.AA) call. Investigate why the local result includes T7651 while the test does not, alongside issue #2920; done means the cause and expected behavior are established.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- python
- Domain
- api, testing
- Issue type
- Bug
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Needs clarification
- Newbie friendliness
- 25/100