mirror of
https://github.com/metabarcoding/obitools4.git
synced 2025-06-29 16:20:46 +00:00
Patch the error message stored in sequences by obimultiplex
This commit is contained in:
@ -246,7 +246,6 @@ func (match *DemultiplexMatch) ExtractBarcode(sequence *obiseq.BioSequence, inpl
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
if !match.IsDirect {
|
if !match.IsDirect {
|
||||||
sequence.ReverseComplement(true)
|
sequence.ReverseComplement(true)
|
||||||
}
|
}
|
||||||
@ -277,19 +276,19 @@ func (match *DemultiplexMatch) ExtractBarcode(sequence *obiseq.BioSequence, inpl
|
|||||||
annot["reverse_tag"] = match.ReverseTag
|
annot["reverse_tag"] = match.ReverseTag
|
||||||
}
|
}
|
||||||
|
|
||||||
if match.Error != nil {
|
if match.Error == nil {
|
||||||
annot["demultiplex_error"] = fmt.Sprintf("%v", match.Error)
|
if match.Pcr != nil {
|
||||||
}
|
annot["sample"] = match.Pcr.Sample
|
||||||
|
annot["experiment"] = match.Pcr.Experiment
|
||||||
if match.Pcr != nil {
|
for k, val := range match.Pcr.Annotations {
|
||||||
annot["sample"] = match.Pcr.Sample
|
annot[k] = val
|
||||||
annot["experiment"] = match.Pcr.Experiment
|
}
|
||||||
for k, val := range match.Pcr.Annotations {
|
} else {
|
||||||
annot[k] = val
|
annot["demultiplex_error"] = "cannot assign the sequence to a sample"
|
||||||
|
match.Error = errors.New("cannot assign the sequence to a sample")
|
||||||
}
|
}
|
||||||
} else {
|
} else {
|
||||||
annot["demultiplex_error"] = "cannot assign the sequence to a sample"
|
annot["demultiplex_error"] = fmt.Sprintf("%v", match.Error)
|
||||||
match.Error = errors.New("cannot assign the sequence to a sample")
|
|
||||||
}
|
}
|
||||||
|
|
||||||
return sequence, match.Error
|
return sequence, match.Error
|
||||||
|
Reference in New Issue
Block a user