mirror of
https://github.com/metabarcoding/obitools4.git
synced 2025-06-29 16:20:46 +00:00
Adds the --silent-warning options to the obitools commands and removes the --pared-with option from some of the obitols commands.
This commit is contained in:
@ -4,6 +4,7 @@ import (
|
||||
"fmt"
|
||||
"strconv"
|
||||
|
||||
"git.metabarcoding.org/obitools/obitools4/obitools4/pkg/obilog"
|
||||
"git.metabarcoding.org/obitools/obitools4/obitools4/pkg/obiutils"
|
||||
log "github.com/sirupsen/logrus"
|
||||
)
|
||||
@ -136,7 +137,12 @@ func (s *BioSequence) SetAttribute(key string, value interface{}) {
|
||||
}
|
||||
|
||||
if key == "sequence" {
|
||||
s.SetSequence(value.([]byte))
|
||||
data, err := obiutils.InterfaceToString(value)
|
||||
if err != nil {
|
||||
obilog.Warnf("%s: cannot convert value %v to sequence", s.Id(), value)
|
||||
return
|
||||
}
|
||||
s.SetSequence([]byte(data))
|
||||
return
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user