1212from BCBio import GFF
1313
1414from Bio import SeqIO
15- from Bio .Alphabet import IUPAC
1615from Bio .Seq import Seq
1716from Bio .SeqFeature import FeatureLocation as BioFeatureLocation
1817from Bio .SeqFeature import SeqFeature
@@ -85,7 +84,7 @@ def export_gff3(self, organism_id):
8584
8685 for org in res :
8786 # TODO: can we do this properly?
88- seq = Seq ("A" * 1 , IUPAC . unambiguous_dna )
87+ seq = Seq ("A" * 1 )
8988
9089 # Annotation features
9190 features = self .session .query (self .model .feature , self .model .featureloc ) \
@@ -230,7 +229,7 @@ def export_gbk(self, organism_id):
230229
231230 sys .stderr .write ("Processing %s sequences\n " % res .count ())
232231 for org in res :
233- seq = Seq ('' , IUPAC . unambiguous_dna )
232+ seq = Seq ('' )
234233
235234 record_features = []
236235 features = self .ci .session .query (self .model .feature , self .model .featureloc ) \
@@ -245,7 +244,7 @@ def export_gbk(self, organism_id):
245244 # Sequence containing feature
246245 if feature .residues :
247246 # This seems bad? What if multiple things have seqs?
248- seq = Seq (feature .residues , IUPAC . unambiguous_dna )
247+ seq = Seq (feature .residues )
249248 else :
250249 qualifiers = {
251250 self .ci .get_cvterm_name (prop .type_id ): prop .value for prop in
@@ -266,6 +265,7 @@ def export_gbk(self, organism_id):
266265 seq , id = org .common_name ,
267266 name = org .common_name ,
268267 description = "%s %s" % (org .genus , org .species ),
268+ annotations = {"molecule_type" : "DNA" },
269269 )
270270 record .features = record_features
271271
0 commit comments