You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I've just installed the OSIRIS pipeline and ran into the following error on the tests. I think it just has to do with which files are listed in sky.xml vs which ones are most recently used as reference files on the repo.
Not a huge deal, hope this helps. run_odrp works fine and I'll let you know if I run into any other issues.
Also of minor note, the Ureka python is deprecated (see here; http://ssb.stsci.edu/ureka/), but with AstroPy I didn't need it anyway.
Lastly, it seems that just a few print statements and the urllib might be keeping the code from being python3 compatible. You might consider if it is worth bothering to put in a few control statements for python versions or maybe even a few try/except sections to make the drp more universal.
tests/test_checkskylines/test_checkskylines.py E
tests/test_emission_line/test_emission_line.py .
======================================================== ERRORS ========================================================
____________________________________________ ERROR at setup of test_skyline ____________________________________________
request = <SubRequest 'drf_queue' for <Function 'test_skyline'>>
@pytest.fixture(scope="module")
def drf_queue(request):
"""Fixture for preparing the queue."""
queue_directory = os.path.dirname(str(request.fspath))
setup_test_data(queue_directory)
tests/drptestbones/fixtures.py:17:
tests/drptestbones/fetchdata.py:33: in setup_test_data
get_calib_file(file_to_fetch)
def get_calib_file(file_name, refresh=False):
"""
Fetch a file for the specified test from a URL.
The mapping between test name, file name, and URL is in the file
map_file_urls.txt.
"""
# Get directories.
dir_testbones = os.path.dirname(os.path.abspath(inspect.getfile(inspect.currentframe())))
dir_tests = os.path.dirname(dir_testbones)
dir_calib = dir_tests + '/calib/'
# Get the file name where we will deposit the file.
file_save_name = dir_calib + file_name
if os.path.exists(file_save_name) and not refresh:
return
# Read the map
map_file = dir_testbones + '/map_file_urls.txt'
data_map = Table.read(map_file, format='ascii.commented_header')
# Search for the requested filename
idx = np.where((data_map['test_name'] == 'calib') & (data_map['file_name'] == file_name))[0]
if len(idx) > 1:
print 'Found duplicate entries in map_file: {0:s}. '.format(map_file)
print 'Using the first one. Duplicates are:'
print data_map[idx]
if len(idx) == 0:
From Mate Adamkovics:
Hi Jim,
I've just installed the OSIRIS pipeline and ran into the following error on the tests. I think it just has to do with which files are listed in sky.xml vs which ones are most recently used as reference files on the repo.
Not a huge deal, hope this helps. run_odrp works fine and I'll let you know if I run into any other issues.
Also of minor note, the Ureka python is deprecated (see here; http://ssb.stsci.edu/ureka/), but with AstroPy I didn't need it anyway.
Lastly, it seems that just a few print statements and the urllib might be keeping the code from being python3 compatible. You might consider if it is worth bothering to put in a few control statements for python versions or maybe even a few try/except sections to make the drp more universal.
Just some thoughts! Hope all is well and thanks.
-Mate
haze:/Applications/OsirisDRP$ /Library/Frameworks/Python.framework/Versions/2.7/bin/py.test
======================================================================================= test session starts ========================================================================================
platform darwin -- Python 2.7.9, pytest-3.0.5, py-1.4.32, pluggy-0.4.0
rootdir: /Applications/OsirisDRP, inifile:
collected 2 items
tests/test_checkskylines/test_checkskylines.py E
tests/test_emission_line/test_emission_line.py .
======================================================== ERRORS ========================================================
____________________________________________ ERROR at setup of test_skyline ____________________________________________
request = <SubRequest 'drf_queue' for <Function 'test_skyline'>>
tests/drptestbones/fixtures.py:17:
tests/drptestbones/fetchdata.py:33: in setup_test_data
get_calib_file(file_to_fetch)
file_name = 's160416_c006___infl_Kbb_035.fits', refresh = False
E KeyError: 's160416_c006___infl_Kbb_035.fits'
tests/drptestbones/fetchdata.py:126: KeyError
========================================== 1 passed, 1 error in 41.18 seconds ==========================================
think it's just a matter of filen
The text was updated successfully, but these errors were encountered: