Changeset 1834:91f840200ae3 in orange-bioinformatics for server_update/updateGO.py


Ignore:
Timestamp:
07/03/13 14:47:13 (10 months ago)
Author:
Flashpoint <vid.flashpoint@…>
Branch:
default
Message:

Changed the exception value from KEGG.OrganismNotFound to obiTaxonomy.UnknownSpeciesIdentifier

File:
1 edited

Legend:

Unmodified
Added
Removed
  • server_update/updateGO.py

    r1833 r1834  
    5959 
    6060    if u.IsUpdatable(obiGO.Update.UpdateAnnotation, (org,)): 
    61         print "JA" 
    6261        u.UpdateAnnotation(org) 
    6362        filename = os.path.join(tmpDir, "gene_association." + org + ".tar.gz") 
     
    7776#            orgName = org 
    7877        orgName = obiTaxonomy.name(commonOrgs[org]) 
     78        taxid = obiTaxonomy.taxname_to_taxid(orgName) 
    7979#            print "unknown organism name translation for:", org 
    8080        print "Uploading", "gene_association." + org + ".tar.gz" 
    8181        sf_server.upload("GO", "gene_association." + org + ".tar.gz", filename, title = "GO Annotations for " + orgName, 
    8282                           tags=["gene", "annotation", "ontology", "GO", orgName, "#uncompressed:%i" % uncompressedSize(filename), 
    83                                  "#organism:"+orgName, "#version:%i" % obiGO.Annotations.version] + (["essential"] if org in essentialOrgs else [])+ obiTaxonomy.shortname(org)) 
     83                                 "#organism:"+orgName, "#version:%i" % obiGO.Annotations.version] + (["essential"] if org in essentialOrgs else []) + obiTaxonomy.shortname(taxid)) 
    8484        sf_server.unprotect("GO", "gene_association." + org + ".tar.gz") 
    8585         
Note: See TracChangeset for help on using the changeset viewer.