Skip to content

Crash if dna_reference not provided #81

@nromashchenko

Description

@nromashchenko

Read2Tree version: 2.0.1

According to the help command, it's possible to call read2tree without dna reference:

> read2tree --help
2025-11-14 10:56:45 INFO      ------- Read2Tree version: 2.0.1 -------
...
  --dna_reference DNA_REFERENCE
                        [Default is None] Reference file that contains nucleotide sequences (fasta, hdf5). If not given it will usethe RESTapi and retrieve sequences from http://omabrowser.org directly. NOTE: internet connection
                        required!

and it is indeed possible:

> read2tree --tree --standalone_path marker_genes --reads sample_1.fastq sample_2.fastq --output_path ./output
...
    with open_(self.args.dna_reference, 'rt') as f:
         ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
FileNotFoundError: [Errno 2] No such file or directory: ''

I assume it's an artifact from earlier versions and it should be a required argument

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions