Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Test failures with Python3 and memcached #168

Closed
felixonmars opened this issue Feb 7, 2019 · 1 comment
Closed

Test failures with Python3 and memcached #168

felixonmars opened this issue Feb 7, 2019 · 1 comment

Comments

@felixonmars
Copy link

======================================================================
FAIL: tests.test_memcached.test_cache_manager
----------------------------------------------------------------------
Traceback (most recent call last):
  File "/usr/lib/python3.7/site-packages/nose/case.py", line 197, in runTest
    self.test(*self.arg)
  File "/usr/lib/python3.7/site-packages/nose/util.py", line 620, in newfunc
    return func(*arg, **kw)
  File "/build/python-beaker/src/beaker-1.10.0/beaker/util.py", line 64, in maybe
    return fn(*args, **kw)
  File "/build/python-beaker/src/beaker-1.10.0/tests/test_memcached.py", line 243, in test_cache_manager
    res = app.get('/')
  File "/usr/lib/python3.7/site-packages/webtest/app.py", line 335, in get
    expect_errors=expect_errors)
  File "/usr/lib/python3.7/site-packages/webtest/app.py", line 628, in do_request
    res = req.get_response(app, catch_exc_info=True)
  File "/usr/lib/python3.7/site-packages/webob/request.py", line 1310, in send
    application, catch_exc_info=True)
  File "/usr/lib/python3.7/site-packages/webob/request.py", line 1281, in call_application
    output.extend(app_iter)
  File "/usr/lib/python3.7/site-packages/webtest/lint.py", line 302, in next
    % (self.iterator, binary_type, v))
AssertionError: Iterator <generator object cache_manager_app at 0x7fb1c6dc5d68> returned a non-<class 'bytes'> object: 'test_key is: test value\n'

-------------------- >> begin captured logging << --------------------
beaker.container: DEBUG: set_value stored time 1549538065.74513 expire time None
--------------------- >> end captured logging << ---------------------

======================================================================
FAIL: tests.test_memcached.test_increment
----------------------------------------------------------------------
Traceback (most recent call last):
  File "/usr/lib/python3.7/site-packages/nose/case.py", line 197, in runTest
    self.test(*self.arg)
  File "/usr/lib/python3.7/site-packages/nose/util.py", line 620, in newfunc
    return func(*arg, **kw)
  File "/build/python-beaker/src/beaker-1.10.0/beaker/util.py", line 64, in maybe
    return fn(*args, **kw)
  File "/build/python-beaker/src/beaker-1.10.0/tests/test_memcached.py", line 225, in test_increment
    res = app.get('/', extra_environ={'beaker.clear':True})
  File "/usr/lib/python3.7/site-packages/webtest/app.py", line 335, in get
    expect_errors=expect_errors)
  File "/usr/lib/python3.7/site-packages/webtest/app.py", line 641, in do_request
    res.body
  File "/usr/lib/python3.7/site-packages/webob/response.py", line 521, in _body__get
    body = b''.join(app_iter)
  File "/usr/lib/python3.7/site-packages/webtest/lint.py", line 302, in next
    % (self.iterator, binary_type, v))
AssertionError: Iterator <list_iterator object at 0x7fb1c6d219b0> returned a non-<class 'bytes'> object: 'The current value is: 1'

-------------------- >> begin captured logging << --------------------
beaker.container: DEBUG: set_value stored time 1549538065.8175192 expire time None
--------------------- >> end captured logging << ---------------------

======================================================================
FAIL: tests.test_memcached.test_session
----------------------------------------------------------------------
Traceback (most recent call last):
  File "/usr/lib/python3.7/site-packages/nose/case.py", line 197, in runTest
    self.test(*self.arg)
  File "/usr/lib/python3.7/site-packages/nose/util.py", line 620, in newfunc
    return func(*arg, **kw)
  File "/build/python-beaker/src/beaker-1.10.0/beaker/util.py", line 64, in maybe
    return fn(*args, **kw)
  File "/build/python-beaker/src/beaker-1.10.0/tests/test_memcached.py", line 117, in test_session
    res = app.get('/')
  File "/usr/lib/python3.7/site-packages/webtest/app.py", line 335, in get
    expect_errors=expect_errors)
  File "/usr/lib/python3.7/site-packages/webtest/app.py", line 641, in do_request
    res.body
  File "/usr/lib/python3.7/site-packages/webob/response.py", line 521, in _body__get
    body = b''.join(app_iter)
  File "/usr/lib/python3.7/site-packages/webtest/lint.py", line 302, in next
    % (self.iterator, binary_type, v))
AssertionError: Iterator <list_iterator object at 0x7fb1c6dd89e8> returned a non-<class 'bytes'> object: 'The current value is: 1, session id is 3d357f62c7a043169768678dba9655d5'


======================================================================
FAIL: tests.test_memcached.test_session_invalid
----------------------------------------------------------------------
Traceback (most recent call last):
  File "/usr/lib/python3.7/site-packages/nose/case.py", line 197, in runTest
    self.test(*self.arg)
  File "/usr/lib/python3.7/site-packages/nose/util.py", line 620, in newfunc
    return func(*arg, **kw)
  File "/build/python-beaker/src/beaker-1.10.0/beaker/util.py", line 64, in maybe
    return fn(*args, **kw)
  File "/build/python-beaker/src/beaker-1.10.0/tests/test_memcached.py", line 128, in test_session_invalid
    res = app.get('/invalid', headers=dict(Cookie='beaker.session.id=df7324911e246b70b5781c3c58328442; Path=/'))
  File "/usr/lib/python3.7/site-packages/webtest/app.py", line 335, in get
    expect_errors=expect_errors)
  File "/usr/lib/python3.7/site-packages/webtest/app.py", line 641, in do_request
    res.body
  File "/usr/lib/python3.7/site-packages/webob/response.py", line 521, in _body__get
    body = b''.join(app_iter)
  File "/usr/lib/python3.7/site-packages/webtest/lint.py", line 302, in next
    % (self.iterator, binary_type, v))
AssertionError: Iterator <list_iterator object at 0x7fb1c6deccf8> returned a non-<class 'bytes'> object: 'The current value is: 2, session id is df7324911e246b70b5781c3c58328442'


======================================================================
FAIL: tests.test_memcached.test_store_none
----------------------------------------------------------------------
Traceback (most recent call last):
  File "/usr/lib/python3.7/site-packages/nose/case.py", line 197, in runTest
    self.test(*self.arg)
  File "/usr/lib/python3.7/site-packages/nose/util.py", line 620, in newfunc
    return func(*arg, **kw)
  File "/build/python-beaker/src/beaker-1.10.0/beaker/util.py", line 64, in maybe
    return fn(*args, **kw)
  File "/build/python-beaker/src/beaker-1.10.0/tests/test_memcached.py", line 250, in test_store_none
    res = app.get('/', extra_environ={'beaker.clear':True})
  File "/usr/lib/python3.7/site-packages/webtest/app.py", line 335, in get
    expect_errors=expect_errors)
  File "/usr/lib/python3.7/site-packages/webtest/app.py", line 641, in do_request
    res.body
  File "/usr/lib/python3.7/site-packages/webob/response.py", line 521, in _body__get
    body = b''.join(app_iter)
  File "/usr/lib/python3.7/site-packages/webtest/lint.py", line 302, in next
    % (self.iterator, binary_type, v))
AssertionError: Iterator <list_iterator object at 0x7fb1c6decb00> returned a non-<class 'bytes'> object: 'The current value is: 10'

-------------------- >> begin captured logging << --------------------
beaker.container: DEBUG: set_value stored time 1549538065.8268256 expire time None
--------------------- >> end captured logging << ---------------------

----------------------------------------------------------------------
Ran 203 tests in 157.720s

FAILED (failures=5)
@amol-
Copy link
Collaborator

amol- commented Feb 20, 2019

Thanks! memcached tests were disabled on Py3 because the memcached libraries didn't support Py3, but now they do.

Fixed in 687b755 verified in https://travis-ci.org/bbangert/beaker/builds/496214506

@amol- amol- closed this as completed Feb 20, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants