Skip to content

Conversation

@lldelisle
Copy link

I got an error when using bigwigAverage:

Traceback (most recent call last):
  File "/data/galaxy/galaxy/var/dependencies/_conda/envs/mulled-v1-9dd4e5433cf4f47ee04cca722ff3869495cfcd627aecb78c70b6dcb65b45e293/bin/bigwigAverage", line 12, in <module>
    main(args)
  File "/data/galaxy/galaxy/var/dependencies/_conda/envs/mulled-v1-9dd4e5433cf4f47ee04cca722ff3869495cfcd627aecb78c70b6dcb65b45e293/lib/python3.8/site-packages/deeptools/bigwigAverage.py", line 140, in main
    writeBedGraph_bam_and_bw.writeBedGraph(
  File "/data/galaxy/galaxy/var/dependencies/_conda/envs/mulled-v1-9dd4e5433cf4f47ee04cca722ff3869495cfcd627aecb78c70b6dcb65b45e293/lib/python3.8/site-packages/deeptools/writeBedGraph_bam_and_bw.py", line 209, in writeBedGraph
    res = mapReduce.mapReduce((tileSize, fragmentLength, bamOrBwFileList,
  File "/data/galaxy/galaxy/var/dependencies/_conda/envs/mulled-v1-9dd4e5433cf4f47ee04cca722ff3869495cfcd627aecb78c70b6dcb65b45e293/lib/python3.8/site-packages/deeptools/mapReduce.py", line 146, in mapReduce
    res = list(map(func, TASKS))
  File "/data/galaxy/galaxy/var/dependencies/_conda/envs/mulled-v1-9dd4e5433cf4f47ee04cca722ff3869495cfcd627aecb78c70b6dcb65b45e293/lib/python3.8/site-packages/deeptools/writeBedGraph_bam_and_bw.py", line 42, in writeBedGraph_wrapper
    return writeBedGraph_worker(*args)
  File "/data/galaxy/galaxy/var/dependencies/_conda/envs/mulled-v1-9dd4e5433cf4f47ee04cca722ff3869495cfcd627aecb78c70b6dcb65b45e293/lib/python3.8/site-packages/deeptools/writeBedGraph_bam_and_bw.py", line 74, in writeBedGraph_worker
    getCoverageFromBigwig(
  File "/data/galaxy/galaxy/var/dependencies/_conda/envs/mulled-v1-9dd4e5433cf4f47ee04cca722ff3869495cfcd627aecb78c70b6dcb65b45e293/lib/python3.8/site-packages/deeptools/writeBedGraph_bam_and_bw.py", line 25, in getCoverageFromBigwig
    coverage = np.asarray(bigwigHandle.values(chrom, start, end))
RuntimeError: Invalid interval bounds!

I think it is because in the code there is a except ValueError instead of RuntimeError. The switch in pyBigwig occured in deeptools/pyBigWig@17f8dab which has been merged in version 0.2.1...

  • Does the PR contain new feature?
  • Does the PR contain bugfix?
  • Does the PR contain documentation changes?
  • Does the PR contain changes to the galaxy wrapper?

@lldelisle lldelisle changed the title Fix error handling Fix error handling = = Sep 26, 2023
@lldelisle lldelisle changed the title Fix error handling = = Fix error handling + cases where with bigwigAverage with more than 2 bigwigs Sep 26, 2023
@lldelisle
Copy link
Author

The test that fails has been solved by #1258 .
Do you want me to merge develop or (to save energy) you accept the PR like this?
Do you think it would be possible to do a release quickly with this bug fix?

@WardDeb
Copy link
Member

WardDeb commented Sep 27, 2023

We'll merge like this,
I'll add the PR for mpl version as well and then tag a new release today still. Thanks @lldelisle !

@WardDeb WardDeb merged commit d56b016 into deeptools:develop Sep 27, 2023
@lldelisle lldelisle deleted the fix_error_handling branch September 27, 2023 07:40
@lldelisle
Copy link
Author

Thanks.

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

Successfully merging this pull request may close these issues.

2 participants