Mercurial > repos > earlhaminst > gafa
diff GAFA.py @ 7:b9f1bcf5ee59 draft default tip
planemo upload for repository https://github.com/TGAC/earlham-galaxytools/tree/master/tools/GAFA/ commit fa875eea77a9471acada2b7b8882a0467994c960
author | earlhaminst |
---|---|
date | Wed, 25 Apr 2018 10:59:55 -0400 |
parents | 117fc7414307 |
children |
line wrap: on
line diff
--- a/GAFA.py Tue Mar 20 11:06:51 2018 -0400 +++ b/GAFA.py Wed Apr 25 10:59:55 2018 -0400 @@ -7,6 +7,7 @@ import sqlite3 version = "0.3.0" +compatible_version = ['0.3.0', '0.4.0'] Sequence = collections.namedtuple('Sequence', ['header', 'sequence']) @@ -54,7 +55,7 @@ cur.execute('SELECT version FROM meta') result = cur.fetchone() input_meta_version = result[0] - if input_meta_version != '0.3.0': + if input_meta_version not in compatible_version: raise Exception("Incompatible input meta version '%s'" % input_meta_version) cur.execute('UPDATE meta SET version=?', (version, )) @@ -68,6 +69,7 @@ protein_id VARCHAR KEY NOT NULL REFERENCES transcript(protein_id), protein_alignment VARCHAR NOT NULL, PRIMARY KEY (gene_family_id, protein_id))''') + conn.commit()