Bug#974181: python3-sasview: tests fail with h5py 3.1
Drew Parsons
dparsons at debian.org
Sun Nov 29 05:36:41 GMT 2020
Package: sasview
Version: 5.0.3-1
Followup-For: Bug #974181
Still FTBFS with PR1683 and h5py 3.1, failing build-time tests:
________________________ nxcansas_writer.test_write_1d _________________________
self = <test.fileconverter.test.utest_nxcansas_writer.nxcansas_writer testMethod=test_write_1d>
def test_write_1d(self):
self.writer.write([self.data_1d], self.write_file_1d)
> data = self.loader.load(self.write_file_1d)
test/fileconverter/test/utest_nxcansas_writer.py:34:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
sas/sascalc/dataloader/loader.py:390: in load
return self.__registry.load(file, format)
sas/sascalc/dataloader/loader.py:85: in load
return self.load_using_generic_loaders(path)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
self = <sas.sascalc.dataloader.loader.Registry object at 0x7f5c040ff6a0>
path = '/home/drew/projects/sasview/build/sasview/.pybuild/cpython3_3.8_sasview/build/test/fileconverter/test/export1d.h5'
def load_using_generic_loaders(self, path):
"""
If the expected reader cannot load the file or no known loader exists,
attempt to load the file using a few defaults readers
:param path: file path
:return: List of Data1D and Data2D objects
"""
module_list = readers.get_generic_readers()
for module in module_list:
reader = module.Reader()
try:
data_list = reader.read(path)
if data_list:
return data_list
except Exception as e:
# Cycle through all generic readers
pass
# Only throw exception if all generic readers fail
> raise NoKnownLoaderException(
"Generic readers failed to load %s" % path)
E sas.sascalc.dataloader.loader_exceptions.NoKnownLoaderException: Generic readers failed to load /home/drew/projects/sasview/build/sasview/.pybuild/cpython3_3.8_sasview/build/test/fileconverter/test/expor
t1d.h5
sas/sascalc/dataloader/loader.py:117: NoKnownLoaderException
----------------------------- Captured stderr call -----------------------------
Traceback (most recent call last):
File "/home/drew/projects/sasview/build/sasview/.pybuild/cpython3_3.8_sasview/build/sas/sascalc/dataloader/loader.py", line 85, in load
return self.load_using_generic_loaders(path)
File "/home/drew/projects/sasview/build/sasview/.pybuild/cpython3_3.8_sasview/build/sas/sascalc/dataloader/loader.py", line 117, in load_using_generic_loaders
raise NoKnownLoaderException(
sas.sascalc.dataloader.loader_exceptions.NoKnownLoaderException: Generic readers failed to load /home/drew/projects/sasview/build/sasview/.pybuild/cpython3_3.8_sasview/build/test/fileconverter/test/export1d.h5
------------------------------ Captured log call -------------------------------
WARNING sas.sascalc.dataloader.file_reader_base_class:file_reader_base_class.py:168 SasView cannot load /home/drew/projects/sasview/build/sasview/.pybuild/cpython3_3.8_sasview/build/test/fileconverter/test/expo
rt1d.h5.
Invalid XML syntax
WARNING sas.sascalc.dataloader.file_reader_base_class:file_reader_base_class.py:38 Unable to decode b"\x89HDF\r\n\x1a\n\x00\x00\x00\x00\x00\x08\x08\x00\x04\x00\x10\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x0
I don't think character encoding is the problem as such. The later
error "Invalid XML syntax" might be a better clue. It's like it's
treating the .h5 file (binary) as an xml file (text-based). Is it
getting .h5 mixed up with .xdmf? (.xdmf is an xml header file reading
into a .h5 datafile)
Probably we should file the bug upstream.
-- System Information:
Debian Release: bullseye/sid
APT prefers unstable
APT policy: (500, 'unstable'), (1, 'experimental')
Architecture: amd64 (x86_64)
Foreign Architectures: i386
Kernel: Linux 5.9.0-3-amd64 (SMP w/8 CPU threads)
Kernel taint flags: TAINT_WARN
Locale: LANG=en_AU.UTF-8, LC_CTYPE=en_AU.UTF-8 (charmap=UTF-8), LANGUAGE=en_AU:en
Shell: /bin/sh linked to /usr/bin/dash
Init: systemd (via /run/systemd/system)
LSM: AppArmor: enabled
Versions of packages sasview depends on:
ii python3 3.9.0-3
ii python3-numpy 1:1.19.4-1
ii python3-pkg-resources 50.3.0-1
ii python3-sasview 5.0.3-1+b1
sasview recommends no packages.
Versions of packages sasview suggests:
ii sasview-doc 5.0.3-1
-- no debconf information
More information about the debian-science-maintainers
mailing list