An error occured in context "Search/Domain" cell "1.00"
in the section containing the code:
|
001
002
003 import dbd, sys
004
005 cellhead()
006
007 params = dbd.parse_params()
008
009 domainlike = None
010 domain = None
011
012 if params.has_key("domainlike") and params.has_key("cat"):
013 domainlike = params["domainlike"]
014 cat = params["cat"]
015 elif params.has_key("domainlike"):
016 domainlike = params["domainlike"]
017 cat = 'DBD'
018 elif session.has_key("domainlike") and session.has_key("cat"):
019 domainlike = session["domainlike"]
020 cat = session["cat"]
021 elif session.has_key("domainlike"):
022 domainlike = session["domainlike"]
023 cat = 'DBD'
024 elif params.has_key("id") and params.has_key("cat"):
025 domain = params["id"]
026 cat = params["cat"]
027 elif params.has_key("id"):
028 domain = params["id"]
029 cat = 'DBD'
030 elif session.has_key("id") and session.has_key("cat"):
031 domain = session["id"]
032 cat = session["cat"]
033 elif session.has_key("id"):
034 domain = session["id"]
035 cat = 'DBD'
036 elif params.has_key("domain") and params.has_key("cat"):
037 domain = params["domain"]
038 cat = params["cat"]
039 elif params.has_key("domain"):
040 domain = params["domain"]
041 cat = 'DBD'
042 elif session.has_key("domain") and session.has_key("cat"):
043 domain = session["domain"]
044 cat = session["cat"]
045 elif session.has_key("domain"):
046 domain = session["domain"]
047 cat = 'DBD'
048 else:
049 print "Error"
050 cellbody()
051 dbd.print_error_cell("Please specify a model id and model category")
052 cellend()
053 sys.exit()
054
055 page = 0
056 limit = dbd.RECORDS_PER_PAGE
057 if params.has_key("page"):
058 page = int(params["page"])
059 if params.has_key("limit"):
060 limit = int(params["limit"])
061
062
063 if domainlike:
064 print "Binding category: %s Domain search: %s" %(cat, domainlike)
065 cellbody()
066 dbd.print_domain_table(globals.HomeURLBase, dbd.IMAGE_GEN_DIR, dbd.model_by_search_domain, cat, domainlike)
067 else:
068 for row in dbd.get_family_name_by_model(domain):
069 [family_name] = row
070 print """Binding category: %s. Domain search: %s.""" %(cat, family_name)
071 cellbody()
072 print """<blockquote><p> Each predicted transcription factor is displayed with its SUPERFAMILY (SF) as well as PFAM (PF) architecture. <br> """
073 print """ The domain architectures are represented as colored rectangles and oblongs on a black line corresponding to the polypeptide chain. <br> """
074 print """ The oblongs represent DNA-binding domains, and the rectangles represent domains with other functions. <br> """
075 print """ The numbers inside the SF rectangles represent the SF database identifier for that protein superfamily, and are linked to a description. <br> """
076 print """ The PFAM identifiers inside the boxes are also linked to descriptions of the family. <br> """
077 print """ All the domains belonging to one family have the same colored rectangle. <br> """
078 print """ Colors are reused for different families, so that two different families can be represented by the same color. </p> """
079 print """<p> The full repertoire of transcription factors may be distributed across several pages of results. <br> """
080 print """ These can be accessed by clicking on the individual page numbers, or downloading the entire set of results from the <a href="%s?Download">Download</a> section. </p><br> """ %globals.HomeURLBase
081 dbd.print_tfs_table(globals.HomeURLBase, globals.Context, dbd.IMAGE_GEN_DIR, dbd.tfs_by_model, cat, domain, limit=limit, page=page)
082
083
084 cellend()
085
086
|
Traceback (most recent call last):
File "/net/isilonP/public/rw/research/teichmann/apache/live/DBD/web.py", line 148, in gen_cell
exec _code in _globals_d, _locals_d
File "<string>", line 68, in <module>
File "/net/isilonP/public/rw/research/teichmann/apache/live/DBD/dbd.py", line 518, in get_family_name_by_model
c = get_db_cursor()
File "/net/isilonP/public/rw/research/teichmann/apache/live/DBD/dbd.py", line 68, in get_db_cursor
db = MySQLdb.connect(host="mysql-teichmann-web.ebi.ac.uk", port=4412, user="admin", passwd="z2Kd6OvN", db="DBD2")
File "/usr/lib64/python2.6/site-packages/MySQLdb/__init__.py", line 81, in Connect
return Connection(*args, **kwargs)
File "/usr/lib64/python2.6/site-packages/MySQLdb/connections.py", line 187, in __init__
super(Connection, self).__init__(*args, **kwargs2)
OperationalError: (2003, "Can't connect to MySQL server on 'mysql-teichmann-web.ebi.ac.uk' (111)")
|
|
|
|