Closed Kmoran1512 closed 11 months ago
Hi @Kmoran1512, concept names in FathomNet may have leading/trailing whitespace; the comma_list
function was implemented this way to avoid ambiguity of the concept specification in that case.
As an alternative to providing a list of concepts on the command line, you can use the --concepts-file
option in lieu of --concepts
, and point it to to a file with one concept per line, like
Bathochordaeus charon
Bathochordaeus mcnutti
Bathochordaeus stygius
e.g.
fathomnet-generate --output /path/to/output --concepts-file concepts.txt -v --taxa fathomnet
Okay, if there is a chance for leading/trailing white space the current paradigm makes sense. Thanks for the response (and for the note about the concept file)!
The fathomnet generate api only allows for strict comma separated lists without spaces. It is standard in in CSVs to not have trailing spaces after commas. When writing, trailing commas are included for better legibility. I would like to suggest adding a strip to parsing comma separated lists as it doesn't lose any functionality and could support more legible lists.
fathomnet-py/fathomnet/scripts/fathomnet_generate.py
:Is there a reason not to include this? Are there any cases in which leading or trailing spaces are important?