Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 577852 - dev-python/subunit-1.2.0 fails test suite due to missing sqlite3
Summary: dev-python/subunit-1.2.0 fails test suite due to missing sqlite3
Status: RESOLVED FIXED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: [OLD] Development (show other bugs)
Hardware: All Linux
: Normal normal (vote)
Assignee: bazaar+obsolete
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2016-03-20 17:15 UTC by gentoo_usr
Modified: 2016-12-26 08:00 UTC (History)
2 users (show)

See Also:
Package list:
Runtime testing required: ---


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description gentoo_usr 2016-03-20 17:15:05 UTC
Emering dev-python/subunit-1.2.0 fails its test suite:

[...]
 * python3_4: running distutils-r1_run_phase python_test
Tests running...
======================================================================
ERROR: subunit.tests.test_test_protocol2.TestByteStreamToStreamResult.test_hypothesis_decoding
----------------------------------------------------------------------
Traceback (most recent call last):
  File "/var/tmp/portage/dev-python/subunit-1.2.0/work/subunit-1.2.0-abi_x86_64.amd64/python/subunit/tests/test_test_protocol2.py", line 449, in test_hypothesis_decoding
    def test_hypothesis_decoding(self, code_bytes):
  File "/usr/lib64/python3.4/site-packages/hypothesis/core.py", line 619, in wrapped_test
    if settings.database:
  File "/usr/lib64/python3.4/site-packages/hypothesis/_settings.py", line 259, in database
    from hypothesis.database import ExampleDatabase
  File "/usr/lib64/python3.4/site-packages/hypothesis/database/__init__.py", line 19, in <module>
    from hypothesis.database.backend import SQLiteBackend
  File "/usr/lib64/python3.4/site-packages/hypothesis/database/backend.py", line 19, in <module>
    import sqlite3
ImportError: No module named 'sqlite3'

[...]

Reason seems to be that dev-lang/python-3.4 was installed with USE flag 'sqlite' disabled. Indeed, subunit-1.2.0 passes the test for python, which has USE flag 'sqlite' enabled.

Suggested solution:
Add 'test? ( dev-lang/python[sqlite] )' to DEPEND.

Note: This probably also affects subunit-1.1.0, but this is untested.
Comment 1 Mike Gilbert gentoo-dev 2016-03-24 17:51:09 UTC
> Add 'test? ( dev-lang/python[sqlite] )' to DEPEND.

We will need to use a python-utils-r1 eclass function to generate proper deps for each version of python.
Comment 2 gentoo_usr 2016-12-26 07:30:18 UTC
Hypothesis was missing a dependency on sqlite, this should be fixed in 3.6.0 in this PR:

https://github.com/gentoo/gentoo/pull/2737
Comment 3 Amy Liffey gentoo-dev 2016-12-26 08:00:17 UTC
Thank you !