[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Placement of *.so files to be found by Python modules (Was: ont-fast5-api)



Hi,

there is a problem with ont-fast5-api[0]

On Wed, May 26, 2021 at 03:22:21AM +0530, Nilesh Patra wrote:                                                                                                                            
> However, one problem - I'm being verbose so we are in loop:
> 
> - This package had .so files vendored in ont_fast5_api/vbz_plugin/* -- this is a violation, and hence you repacked it - see this[1]
> - The so files it had, are basically the shared object files that libvbz-hdf-plugin vendors, and that was why we packaged it
> - *Now*, we need to somehow tell this package to find the .so files at the right location
> 
> I did not manage to do that, so I simply ended up symlinking the .so vendored by libvbz-hdf-plugin in that directory. This looks like a bad workaround,
> and hence if you have some way to fixup paths, please have a look.
> The bad change I'm talking about is this one[2]

I can confirm if I disable Nilesh's patch[2] than the build time
tests are failing like:

======================================================================
ERROR: test_add_read_from_multi (test.test_compress_fast5.TestVbzConvert)
----------------------------------------------------------------------
Traceback (most recent call last):
  File "/build/ont-fast5-api-3.1.5+dfsg/.pybuild/cpython3_3.9_ont_fast5_api/build/ont_fast5_api/fast5_read.py", line 104, in add_raw_data
    self.handle[self.raw_dataset_group_name].create_dataset('Signal', data=data, dtype='i2',
  File "/usr/lib/python3/dist-packages/h5py/_debian_h5py_serial/_hl/group.py", line 136, in create_dataset
    dsid = dataset.make_new_dset(self, shape, dtype, data, **kwds)
  File "/usr/lib/python3/dist-packages/h5py/_debian_h5py_serial/_hl/dataset.py", line 137, in make_new_dset
    dcpl = filters.fill_dcpl(
  File "/usr/lib/python3/dist-packages/h5py/_debian_h5py_serial/_hl/filters.py", line 234, in fill_dcpl
    raise ValueError("Unknown compression filter number: %s" % compression)
ValueError: Unknown compression filter number: 32020

The above exception was the direct cause of the following exception:

Traceback (most recent call last):
  File "/build/ont-fast5-api-3.1.5+dfsg/.pybuild/cpython3_3.9_ont_fast5_api/build/test/test_compress_fast5.py", line 98, in test_add_read_from_multi
    output_f5.add_existing_read(input_read, target_compression)
  File "/build/ont-fast5-api-3.1.5+dfsg/.pybuild/cpython3_3.9_ont_fast5_api/build/ont_fast5_api/multi_fast5.py", line 80, in add_existing_read
    self._add_read_from_multi(read_to_add, target_compression)
  File "/build/ont-fast5-api-3.1.5+dfsg/.pybuild/cpython3_3.9_ont_fast5_api/build/ont_fast5_api/multi_fast5.py", line 97, in _add_read_from_multi
    output_read.add_raw_data(raw_data, raw_attrs, compression=target_compression)
  File "/build/ont-fast5-api-3.1.5+dfsg/.pybuild/cpython3_3.9_ont_fast5_api/build/ont_fast5_api/fast5_read.py", line 107, in add_raw_data
    raise_missing_vbz_error_read(e)
  File "/build/ont-fast5-api-3.1.5+dfsg/.pybuild/cpython3_3.9_ont_fast5_api/build/ont_fast5_api/compression_settings.py", line 73, in raise_missing_vbz_error_read
    raise IOError(VBZ_ERROR_MESSAGE.format(register_plugin())) from err
OSError: Failed to read compressed raw data. VBZ compression filter (id=32020) may be missing from expected path: '/build/ont-fast5-api-3.1.5+dfsg/.pybuild/cpython3_3.9_ont_fast5_api/build/ont_fast5_api/vbz_plugin'

======================================================================
ERROR: test_compress_read_from_single (test.test_compress_fast5.TestVbzConvert)
----------------------------------------------------------------------
...


I wonder if there is some trick to point the code to the proper
location of the plugins.  Just a warning:  The plugins are currently
in new[3] as well as its precondition libstreamvbyte[4].

Kind regards

      Andreas.


[0] https://salsa.debian.org/med-team/ont-fast5-api
> [1]: https://salsa.debian.org/med-team/ont-fast5-api/-/commit/097a79d489062b82c6b3abfc45a970bee59893de
> [2]: https://salsa.debian.org/med-team/ont-fast5-api/-/commit/eb74a43929768ab0455f549919df2c5a6607525d
[3] https://ftp-master.debian.org/new/libvbz-hdf-plugin_1.0.1-1.html
[4] https://ftp-master.debian.org/new/libstreamvbyte_0.4.1-1.html




-- 
http://fam-tille.de


Reply to: