phac-nml / biohansel

Rapidly subtype microbial genomes using single-nucleotide variant (SNV) subtyping schemes
Apache License 2.0
25 stars 7 forks source link

Fix to include metadata when installing with pip/conda #109

Closed DarianHole closed 5 years ago

DarianHole commented 5 years ago

Currently, the metadata tables associated with the schemes are not also being included when installing biohansel.

Small change to the setup file to make sure they are copied over with the scheme fasta files

Additional documentation change to the help (-h) statement for Metadata (-M) flag to say which tabular files will work with it (ie .tsv and .tab)

peterk87 commented 5 years ago

Hi @DarianHole and @glabbe

How about changing this line (https://github.com/phac-nml/biohansel/blob/development/bio_hansel/metadata.py#L39) to:

dfmd = FILE_EXT_TO_PD_READ_FUNC.get(file_ext, pd.read_table)(path)

to default to reading a metadata file as a tab-delimited table.

What do you think?

DarianHole commented 5 years ago

@peterk87 That seems like a good idea for an improvement. Most of the files that biohansel is working with are tab delimited and it would make it more consistent. We'll see what @glabbe says.

Here, I just noticed (after doing work on my own setup.py file) that the metadata for typhi was not being downloaded when installing it through conda.

glabbe commented 5 years ago

Sounds good to me @peterk87 and @DarianHole , we can specify to users in the documentation that metadata tables need to be tab-delimited