rhpvorderman / sequali

Fast sequencing data quality metrics
GNU Affero General Public License v3.0
11 stars 0 forks source link

IndexError with single input read #80

Closed marcelm closed 10 months ago

marcelm commented 10 months ago
$ cat test.fastq
@readid ch=165 start_time=2020-01-01T00:00:00Z
A
+
=
$ sequali test.fastq
Processing test.fastq: 100%|██████████████████████████████████████████████████████████████████████████████████████████████████████████████| 53.0/53.0 [00:00<00:00, 86.1kiB/s]
Traceback (most recent call last):
  File ".../.venv/bin/sequali", line 8, in <module>
    sys.exit(main())
  File ".../.venv/lib/python3.10/site-packages/sequali/__main__.py", line 154, in main
    report_modules = calculate_stats(
  File ".../.venv/lib/python3.10/site-packages/sequali/report_modules.py", line 1605, in calculate_stats
    NanoStatsReport.from_nanostats(nanostats)
  File ".../.venv/lib/python3.10/site-packages/sequali/report_modules.py", line 1282, in from_nanostats
    time_active_slots_sets[timeslot].add(channel_id)
IndexError: list index out of range
rhpvorderman commented 10 months ago

Thank you for reporting this and #81. I have added these cases to the integration testing. I also added similar illumina cases. This triggered a nice SIGABRT in the illumina case, which could be very easily debugged thanks to libasan. (That library is awesome!)

Since bug fixes are high priority I will make a new release right away. A colleague of mine requested a flag to changeout the adapter file which is very useful for some projects, so that will become available as well.

Thanks again for your feedback. It is much appreciated!

marcelm commented 10 months ago

Thanks!