bcgsc / mavis

Merging, Annotation, Validation, and Illustration of Structural variants
http://mavis.bcgsc.ca
GNU General Public License v3.0
72 stars 13 forks source link

Fix mavis config TypeError when invalid tool is given #250

Closed mattdoug604 closed 3 years ago

mattdoug604 commented 3 years ago

Instead of raising the intended KeyError, a TypeError was being raised when 'self.values()' is None. This happens when a single tool is given as input and that tool is invalid.

codecov[bot] commented 3 years ago

Codecov Report

Merging #250 (d82407e) into develop (f3c76b7) will increase coverage by 9.57%. The diff coverage is 100.00%.

Impacted file tree graph

@@             Coverage Diff             @@
##           develop     #250      +/-   ##
===========================================
+ Coverage    81.49%   91.06%   +9.57%     
===========================================
  Files           57       57              
  Lines        10319    10319              
===========================================
+ Hits          8409     9397     +988     
+ Misses        1910      922     -988     
Flag Coverage Δ
unittests 91.06% <100.00%> (+9.57%) :arrow_up:

Flags with carried forward coverage won't be shown. Click here to find out more.

Impacted Files Coverage Δ
mavis/constants.py 94.04% <100.00%> (+0.42%) :arrow_up:
mavis/annotate/fusion.py 96.02% <0.00%> (+0.33%) :arrow_up:
mavis/util.py 88.25% <0.00%> (+0.33%) :arrow_up:
mavis/config.py 88.69% <0.00%> (+0.50%) :arrow_up:
mavis/bam/cigar.py 98.14% <0.00%> (+0.61%) :arrow_up:
mavis/schedule/job.py 78.26% <0.00%> (+0.72%) :arrow_up:
mavis/cluster/main.py 90.24% <0.00%> (+0.81%) :arrow_up:
mavis/annotate/genomic.py 93.12% <0.00%> (+1.03%) :arrow_up:
mavis/breakpoint.py 94.61% <0.00%> (+1.15%) :arrow_up:
... and 20 more

Continue to review full report at Codecov.

Legend - Click here to learn more Δ = absolute <relative> (impact), ø = not affected, ? = missing data Powered by Codecov. Last update f3c76b7...d82407e. Read the comment docs.

creisle commented 3 years ago

@mattdoug604 can you also PR this branch into dev_v3 (like the other PR)

mattdoug604 commented 3 years ago

@mattdoug604 can you also PR this branch into dev_v3 (like the other PR)

Done: https://github.com/bcgsc/mavis/pull/252