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

tests fail when building with HTSLIB_MODE=external #665

Closed
nieder opened this issue Apr 13, 2018 · 7 comments
Closed

tests fail when building with HTSLIB_MODE=external #665

nieder opened this issue Apr 13, 2018 · 7 comments

Comments

@nieder
Copy link

nieder commented Apr 13, 2018

When building pysam-0.14.1 against my locally installed htslib-1.7, the tests fail like this:

	export HTSLIB_MODE=external HTSLIB_INCLUDE_DIR=/sw/include HTSLIB_LIBRARY_DIR=/sw/lib
	/sw/bin/python2.7 setup.py build
# pysam: cython is available - using cythonize if necessary
# pysam: htslib mode is external
# pysam: HTSLIB_CONFIGURE_OPTIONS=None
...
/sw/bin/pytest-2.7 tests
...
===================================================================================== FAILURES ======================================================================================
__________________________________________________________________________ TestRemoteFileHTTP.testFetchAll __________________________________________________________________________

self = <tabix_test.TestRemoteFileHTTP testMethod=testFetchAll>

    def setUp(self):
>       if not pysam.config.HAVE_LIBCURL or not check_url(self.url):
E       AttributeError: 'module' object has no attribute 'HAVE_LIBCURL'

tests/tabix_test.py:1049: AttributeError
___________________________________________________________________________ TestRemoteFileHTTP.testHeader ___________________________________________________________________________

self = <tabix_test.TestRemoteFileHTTP testMethod=testHeader>

    def setUp(self):
>       if not pysam.config.HAVE_LIBCURL or not check_url(self.url):
E       AttributeError: 'module' object has no attribute 'HAVE_LIBCURL'

tests/tabix_test.py:1049: AttributeError
_____________________________________________________________________ TestRemoteFileHTTPWithHeader.testFetchAll _____________________________________________________________________

self = <tabix_test.TestRemoteFileHTTPWithHeader testMethod=testFetchAll>

    def setUp(self):
>       if not pysam.config.HAVE_LIBCURL or not check_url(self.url):
E       AttributeError: 'module' object has no attribute 'HAVE_LIBCURL'

tests/tabix_test.py:1088: AttributeError
______________________________________________________________________ TestRemoteFileHTTPWithHeader.testHeader ______________________________________________________________________

self = <tabix_test.TestRemoteFileHTTPWithHeader testMethod=testHeader>

    def setUp(self):
>       if not pysam.config.HAVE_LIBCURL or not check_url(self.url):
E       AttributeError: 'module' object has no attribute 'HAVE_LIBCURL'

tests/tabix_test.py:1088: AttributeError
================================================================================= warnings summary ==================================================================================
tests/AlignmentFile_test.py::TestTruncatedBAM::testTruncatedBam2
  /sw/build.build/pysam-py27-0.14.1-1/pysam-0.14.1/tests/AlignmentFile_test.py:1397: UserWarning: no BGZF EOF marker; file may be truncated
    ignore_truncation=True)

-- Docs: http://doc.pytest.org/en/latest/warnings.html
========================================================== 4 failed, 891 passed, 15 skipped, 1 warnings in 153.23 seconds ===========================================================

My external htslib-1.7 was configured with --enable-libcurl and HAVE_LIBCURL was defined in its config.h file. If I switch the build to htslib mode = shared, then the tests all pass.

@0xaf1f
Copy link
Contributor

0xaf1f commented Apr 22, 2018

I'm seeing this as well when trying to update the Debian package.

@smoe
Copy link
Contributor

smoe commented Sep 14, 2018

Can confirm for 0.15.1.

@AndreasHeger
Copy link
Contributor

Thanks, will look into this.

@smoe
Copy link
Contributor

smoe commented Sep 15, 2018

I happily prepare a VM for you should you find any difficulty to reproduce this behaviour.

@AndreasHeger
Copy link
Contributor

AndreasHeger commented Sep 15, 2018 via email

@AndreasHeger
Copy link
Contributor

AndreasHeger commented Sep 15, 2018 via email

@jmarshall
Copy link
Member

I haven't recently run the tests with HTSLIB_MODE=external, but this should have been fixed by 2cc584b.

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

5 participants