Bug fix classification group_info error when not using `--node`
Running pantools group_info tmp_DB hm.csv
gave an unexpected error:
Sep 13, 2022 9:16:28 AM org.hibernate.validator.internal.util.Version <clinit>
INFO: HV000001: Hibernate Validator null
Reporting all information from selected homology groups
Gathering functions from homology groups: 12/12java.lang.NullPointerException
at nl.wur.bif.pantools.pangenome.Classification.homology_group_info(Classification.java:1173)
at nl.wur.bif.pantools.cli.GroupInfo.call(GroupInfo.java:58)
at nl.wur.bif.pantools.cli.GroupInfo.call(GroupInfo.java:22)
at picocli.CommandLine.executeUserObject(CommandLine.java:1953)
at picocli.CommandLine.access$1300(CommandLine.java:145)
at picocli.CommandLine$RunLast.executeUserObjectOfLastSubcommandWithSameParent(CommandLine.java:2358)
at picocli.CommandLine$RunLast.handle(CommandLine.java:2352)
at picocli.CommandLine$RunLast.handle(CommandLine.java:2314)
at picocli.CommandLine$AbstractParseResultHandler.execute(CommandLine.java:2179)
at picocli.CommandLine$RunLast.execute(CommandLine.java:2316)
at nl.wur.bif.pantools.pantools.Pantools.executionStrategy(Pantools.java:172)
at picocli.CommandLine.execute(CommandLine.java:2078)
at nl.wur.bif.pantools.pantools.Pantools.main(Pantools.java:139)
This seems to be caused by not always checking whether Mode.contains("K-MER")
; therefore, this merge request checks that before writing to nodeBuilder.
tl;dr: prevent NullPointerException for nodeBuilder by checking whether Mode contains 'K-MER'