-
Notifications
You must be signed in to change notification settings - Fork 1
Open
Labels
Description
Running
./script/testfails on my machine using docker version:
Docker version 17.03.0-ce, build 60ccb22GLOB sdist-make: /home/belmann/projects/bioboxes-py/setup.py
py27 create: /home/belmann/projects/bioboxes-py/.tox/py27
py27 installdeps: -r/home/belmann/projects/bioboxes-py/requirements/default.txt, -r/home/belmann/projects/bioboxes-py/requirements/development.txt
py27 inst: /home/belmann/projects/bioboxes-py/.tox/dist/biobox-py-0.4.3.zip
py27 installed: appdirs==1.4.3,backports.ssl-match-hostname==3.5.0.1,biobox-py==0.4.3,docker-py==1.8.1,funcy==1.7.3,hashids==1.1.0,ipaddress==1.0.18,iso8601==0.1.11,packaging==16.8,pkginfo==1.4.1,py==1.4.32,pyparsing==2.2.0,pytest==2.9.1,requests==2.13.0,requests-toolbelt==0.7.1,ruamel.ordereddict==0.4.9,ruamel.yaml==0.11.15,six==1.10.0,twine==1.6.5,websocket-client==0.40.0
py27 runtests: PYTHONHASHSEED='4228211735'
py27 runtests: commands[0] | python -m pytest
================================================================================================ test session starts ================================================================================================
platform linux2 -- Python 2.7.12, pytest-2.9.1, py-1.4.32, pluggy-0.3.1
rootdir: /home/belmann/projects/bioboxes-py, inifile:
collected 34 items
test/test_cgroup.py .F.F
test/test_config_.py ....
test/test_container_.py ....
test/biobox_type/test_assembly_evaluation.py .
test/biobox_type/test_short_read_assembler.py .....
test/image/test_availability.py ....F
test/image/test_execute.py .
test/image/test_volumes.py ..........
===================================================================================================== FAILURES ======================================================================================================
______________________________________________________________________________________ test_collect_metric_with_dead_container ______________________________________________________________________________________
@pytest.mark.slow
def test_collect_metric_with_dead_container():
id_ = hlp.dummy_container(2)
stream = util.client().stats(id_, decode = True, stream = True)
time.sleep(1)
cgroup.collect_metric(stream)
time.sleep(1)
> assert cgroup.collect_metric(stream) == None
E assert {'blkio_stats': {'io_merged_recursive': None, 'io_queue_recursive': None, 'io_service_bytes_recursive': None, 'io_serv...time': 0}}, 'memory_stats': {}, 'network': {'rx_bytes': 0, 'rx_dropped': 0, 'rx_errors': 0, 'rx_packets': 0, ...}, ...} == None
E + where {'blkio_stats': {'io_merged_recursive': None, 'io_queue_recursive': None, 'io_service_bytes_recursive': None, 'io_serv...time': 0}}, 'memory_stats': {}, 'network': {'rx_bytes': 0, 'rx_dropped': 0, 'rx_errors': 0, 'rx_packets': 0, ...}, ...} = <function collect_metric at 0x7fa6cde36e60>(<generator object _stream_helper at 0x7fa6cd8e2460>)
E + where <function collect_metric at 0x7fa6cde36e60> = cgroup.collect_metric
test/test_cgroup.py:19: AssertionError
_______________________________________________________________________________________________ test_collect_metrics ________________________________________________________________________________________________
@pytest.mark.slow
def test_collect_metrics():
id_ = hlp.dummy_container(10, False)
stats = cgroup.collect_runtime_metrics(id_, interval = 2)
hlp.clean_up_container(id_)
cgroup_time = funcy.rpartial(funcy.get_in, ['read'])
timepoints = list(map(cgroup_time, stats))
assert len(timepoints) >= 3
assert len(timepoints) < 5
duration = cgroup.time_diff_in_seconds(timepoints[0], timepoints[-1])
assert duration >= 6
> assert duration < 10
E assert 33390 < 10
test/test_cgroup.py:45: AssertionError
______________________________________________________________________________________ test_getting_an_image_that_doesnt_exist ______________________________________________________________________________________
@pytest.mark.slow
def test_getting_an_image_that_doesnt_exist():
with pytest.raises(biobox.exception.NoImageFound):
for tag in UNKNOWN_TAGS:
> avail.get_image(tag)
test/image/test_availability.py:39:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
biobox/image/availability.py:45: in get_image
output = util.client().pull(name)
.tox/py27/local/lib/python2.7/site-packages/docker/api/image.py:200: in pull
self._raise_for_status(response)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
self = <docker.client.Client object at 0x7fa6cd937f10>, response = <Response [404]>, explanation = None
def _raise_for_status(self, response, explanation=None):
"""Raises stored :class:`APIError`, if one occurred."""
try:
response.raise_for_status()
except requests.exceptions.HTTPError as e:
if e.response.status_code == 404:
> raise errors.NotFound(e, response, explanation=explanation)
E NotFound: 404 Client Error: Not Found ("repository unknown not found: does not exist or no pull access")
.tox/py27/local/lib/python2.7/site-packages/docker/client.py:153: NotFound
======================================================================================= 3 failed, 31 passed in 34.50 seconds ========================================================================================
ERROR: InvocationError: '/home/belmann/projects/bioboxes-py/.tox/py27/bin/python -m pytest'
py3 create: /home/belmann/projects/bioboxes-py/.tox/py3
py3 installdeps: -r/home/belmann/projects/bioboxes-py/requirements/default.txt, -r/home/belmann/projects/bioboxes-py/requirements/development.txt
py3 inst: /home/belmann/projects/bioboxes-py/.tox/dist/biobox-py-0.4.3.zip
py3 installed: appdirs==1.4.3,biobox-py==0.4.3,docker-py==1.8.1,funcy==1.7.3,hashids==1.1.0,iso8601==0.1.11,packaging==16.8,pkginfo==1.4.1,py==1.4.32,pyparsing==2.2.0,pytest==2.9.1,requests==2.13.0,requests-toolbelt==0.7.1,ruamel.yaml==0.11.15,six==1.10.0,twine==1.6.5,websocket-client==0.40.0
py3 runtests: PYTHONHASHSEED='4228211735'
py3 runtests: commands[0] | python -m pytest
================================================================================================ test session starts ================================================================================================
platform linux -- Python 3.5.2, pytest-2.9.1, py-1.4.32, pluggy-0.3.1
rootdir: /home/belmann/projects/bioboxes-py, inifile:
collected 34 items
test/test_cgroup.py .F..
test/test_config_.py ....
test/test_container_.py ....
test/biobox_type/test_assembly_evaluation.py .
test/biobox_type/test_short_read_assembler.py .....
test/image/test_availability.py ....F
test/image/test_execute.py .
test/image/test_volumes.py ..........
===================================================================================================== FAILURES ======================================================================================================
______________________________________________________________________________________ test_collect_metric_with_dead_container ______________________________________________________________________________________
@pytest.mark.slow
def test_collect_metric_with_dead_container():
id_ = hlp.dummy_container(2)
stream = util.client().stats(id_, decode = True, stream = True)
time.sleep(1)
cgroup.collect_metric(stream)
time.sleep(1)
> assert cgroup.collect_metric(stream) == None
E assert {'blkio_stats': {'io_merged_recursive': None, 'io_queue_recursive': None, 'io_service_bytes_recursive': None, 'io_serv...time': 0}}, 'memory_stats': {}, 'network': {'rx_bytes': 0, 'rx_dropped': 0, 'rx_errors': 0, 'rx_packets': 0, ...}, ...} == None
E + where {'blkio_stats': {'io_merged_recursive': None, 'io_queue_recursive': None, 'io_service_bytes_recursive': None, 'io_serv...time': 0}}, 'memory_stats': {}, 'network': {'rx_bytes': 0, 'rx_dropped': 0, 'rx_errors': 0, 'rx_packets': 0, ...}, ...} = <function collect_metric at 0x7fb6dbd32048>(<generator object Client._stream_helper at 0x7fb6db5d3af0>)
E + where <function collect_metric at 0x7fb6dbd32048> = cgroup.collect_metric
test/test_cgroup.py:19: AssertionError
______________________________________________________________________________________ test_getting_an_image_that_doesnt_exist ______________________________________________________________________________________
@pytest.mark.slow
def test_getting_an_image_that_doesnt_exist():
with pytest.raises(biobox.exception.NoImageFound):
for tag in UNKNOWN_TAGS:
> avail.get_image(tag)
test/image/test_availability.py:39:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
biobox/image/availability.py:45: in get_image
output = util.client().pull(name)
.tox/py3/lib/python3.5/site-packages/docker/api/image.py:200: in pull
self._raise_for_status(response)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
self = <docker.client.Client object at 0x7fb6db4b73c8>, response = <Response [404]>, explanation = None
def _raise_for_status(self, response, explanation=None):
"""Raises stored :class:`APIError`, if one occurred."""
try:
response.raise_for_status()
except requests.exceptions.HTTPError as e:
if e.response.status_code == 404:
> raise errors.NotFound(e, response, explanation=explanation)
E docker.errors.NotFound: 404 Client Error: Not Found ("b'repository unknown not found: does not exist or no pull access'")
.tox/py3/lib/python3.5/site-packages/docker/client.py:153: NotFound
======================================================================================= 2 failed, 32 passed in 33.86 seconds ========================================================================================
ERROR: InvocationError: '/home/belmann/projects/bioboxes-py/.tox/py3/bin/python -m pytest'
______________________________________________________________________________________________________ summary ______________________________________________________________________________________________________
ERROR: py27: commands failed
ERROR: py3: commands failed
Makefile:47: recipe for target 'test' failed
make: *** [test] Error 1
exit 2