Illumina / Nirvana

The nimble & robust variant annotator
https://illumina.github.io/NirvanaDocumentation/
GNU General Public License v3.0
167 stars 44 forks source link

App crash if the chromosome name in -q is not present in the index #99

Closed Griffan closed 1 year ago

Griffan commented 1 year ago

https://github.com/Illumina/Nirvana/blob/05f88047f4c9e79e54ed6b6482549258596bb146/Jasix/QueryProcessor.cs#L94

If the chromosome name doesn't present in the index, the program will crash with error message: " ERROR: Value cannot be null. (Parameter 'key')

Stack trace: at System.Collections.Generic.Dictionary2.FindValue(TKey key) at Jasix.QueryProcessor.ProcessQuery(IEnumerable1 queryStrings, Boolean printHeader) in /home/ubuntu/fan_attempt/post_production/annotation/Nirvana/Jasix/QueryProcessor.cs:line 94 at Jasix.JasixMain.ProgramExecution() in /home/ubuntu/fan_attempt/post_production/annotation/Nirvana/Jasix/JasixMain.cs:line 129 at CommandLine.Builders.ConsoleAppErrors.Execute(Func`1 executeMethod) in /home/ubuntu/fan_attempt/post_production/annotation/Nirvana/CommandLine/Builders/ConsoleAppBuilder.cs:line 162 "

It would be better to just output an empty json file without crashing.

rajatshuvro commented 1 year ago

Thanks for bringing it to our attention. I have created a ticket for that https://nirvana-annotator.atlassian.net/browse/NIR-1376.

Best Rajat