arvestad / alv

A console-based alignment viewer
GNU General Public License v3.0
107 stars 13 forks source link

Bug: self.order error when specifying sort order #24

Closed davised closed 1 year ago

davised commented 1 year ago

Hi there,

When I specify a sort order, e.g.:

$ alv --majority -so Q4FMG0-SAR11_0811,R1CU91-SSSP,R1FPX1-SSSF,A0A1D8PNR5-SSSQ-Calbicans,B7GCM1-SSSP-Ptricornutum,H3GR42-SSSP-Pram,H3GQU1-PUTP-Pram,O06493-OpuE-BSU06660,P07117-PutP-Ecoli,P16256-PanF-Ecoli,P94392-PutP-BSU03220,R1B455-PUTP-Ehux result.fasta
Traceback (most recent call last):
  File "/home/cgrb/davised/.local/bin/alv", line 261, in <module>
    main()
  File "/home/cgrb/davised/.local/bin/alv", line 231, in main
    terminal = AlignmentShellTerminal(args)
  File "/home/cgrb/davised/.local/lib/python3.7/site-packages/alv/alignmentterminal.py", line 184, in __init__
    if len(self.order) == 0:
AttributeError: 'AlignmentShellTerminal' object has no attribute 'order'

I get this error. This is caused because self.order hasn't been set yet. PR coming in a moment.