| <class '_mysql_exceptions.OperationalError'> | Python 2.6.6: /usr/bin/python Wed May 22 20:40:11 2013 |
A problem occurred in a Python script. Here is the sequence of function calls leading up to the error, in the order they occurred.
| /home/toolfact/cgi-bin/gencur_tut.py in |
| 484 else: |
| 485 edit_code = edit = 0 |
| 486 print generateplan(data['pid'][0],data['subject'][0],data['cor'][0], edit, edit_code) |
| 487 elif data['page'][0] == 'dosearch': |
| 488 output = '' |
| generateplan = <function generateplan>, data = {'cor': ['McREL'], 'page': ['plan'], 'pid': ['152'], 'subject': ['2189']}, edit = 0, edit_code = 0 |
| /home/toolfact/cgi-bin/gencur_tut.py in generateplan(pid='152', sub='2189', cor='McREL', edit=0, edit_code=0) |
| 195 f.close() |
| 196 |
| 197 curdata = db.getwholerow("lesson_plans", "id = %i" % int(pid)) |
| 198 for i in curdata.keys(): |
| 199 if curdata[i] == None: curdata[i] = '' |
| curdata undefined, global db = <common.DatabaseObjectNew.Database_Object instance>, db.getwholerow = <bound method Database_Object.getwholerow of <common.DatabaseObjectNew.Database_Object instance>>, builtin int = <type 'int'>, pid = '152' |
| /home/common/common/DatabaseObjectNew.py in getwholerow(self=<common.DatabaseObjectNew.Database_Object instance>, table='lesson_plans', query='id = 152') |
| 197 # Return an entire row (a dictionary with field names mapped to values) given a table and query (both strings). |
| 198 def getwholerow(self,table,query): |
| 199 fields = self.show_all_columns(table) |
| 200 data = self.getrows(table,'*',query) |
| 201 if not data: return {} |
| fields undefined, self = <common.DatabaseObjectNew.Database_Object instance>, self.show_all_columns = <bound method Database_Object.show_all_columns o...mmon.DatabaseObjectNew.Database_Object instance>>, table = 'lesson_plans' |
| /home/common/common/DatabaseObjectNew.py in show_all_columns(self=<common.DatabaseObjectNew.Database_Object instance>, table='lesson_plans') |
| 185 |
| 186 def show_all_columns(self, table): |
| 187 self.make_connection() |
| 188 showall_query = 'SHOW COLUMNS FROM %s' % table |
| 189 if showall_query not in self.cache: |
| self = <common.DatabaseObjectNew.Database_Object instance>, self.make_connection = <bound method Database_Object.make_connection of...mmon.DatabaseObjectNew.Database_Object instance>> |
| /home/common/common/DatabaseObjectNew.py in make_connection(self=<common.DatabaseObjectNew.Database_Object instance>) |
| 59 """This will either make a connection (non-persistent) or do nothing if we're already connected (persistent) SH 9/10/2010""" |
| 60 if not self.persistent: |
| 61 self.db = MySQLdb.connect(host = self.host, passwd=self.passwd, user=self.user, db=self.dbname) |
| 62 self.cursor = self.db.cursor() |
| 63 |
| self = <common.DatabaseObjectNew.Database_Object instance>, self.db undefined, global MySQLdb = <module 'MySQLdb' from '/usr/lib64/python2.6/site-packages/MySQLdb/__init__.pyc'>, MySQLdb.connect = <function Connect>, host undefined, self.host = 'ussom-dwishdb01', passwd undefined, self.passwd = 't00ter', user undefined, self.user = 'tutorials', db undefined, self.dbname = 'tutorials' |
| /usr/lib64/python2.6/site-packages/MySQLdb/__init__.py in Connect(*args=(), **kwargs={'db': 'tutorials', 'host': 'ussom-dwishdb01', 'passwd': 't00ter', 'user': 'tutorials'}) |
| 79 """Factory function for connections.Connection.""" |
| 80 from connections import Connection |
| 81 return Connection(*args, **kwargs) |
| 82 |
| 83 connect = Connection = Connect |
| Connection = <class 'MySQLdb.connections.Connection'>, args = (), kwargs = {'db': 'tutorials', 'host': 'ussom-dwishdb01', 'passwd': 't00ter', 'user': 'tutorials'} |
| /usr/lib64/python2.6/site-packages/MySQLdb/connections.py in __init__(self=<_mysql.connection closed at 11326d0>, *args=(), **kwargs={'db': 'tutorials', 'host': 'ussom-dwishdb01', 'passwd': 't00ter', 'user': 'tutorials'}) |
| 185 kwargs2['client_flag'] = client_flag |
| 186 |
| 187 super(Connection, self).__init__(*args, **kwargs2) |
| 188 |
| 189 self.encoders = dict([ (k, v) for k, v in conv.items() |
| builtin super = <type 'super'>, global Connection = <class 'MySQLdb.connections.Connection'>, self = <_mysql.connection closed at 11326d0>, ).__init__ = <bound method Connection.__init__ of <_mysql.connection closed at 11326d0>>, args = (), kwargs2 = {'client_flag': 196608, 'conv': {0: <class 'decimal.Decimal'>, 1: <type 'int'>, 2: <type 'int'>, 3: <type 'long'>, 4: <type 'float'>, 5: <type 'float'>, 7: <function mysql_timestamp_converter>, 8: <type 'long'>, 9: <type 'int'>, 10: <function Date_or_None>, ...}, 'db': 'tutorials', 'host': 'ussom-dwishdb01', 'passwd': 't00ter', 'user': 'tutorials'} |
<class '_mysql_exceptions.OperationalError'>: (2003, "Can't connect to MySQL server on 'ussom-dwishdb01' (99)")
args =
(2003, "Can't connect to MySQL server on 'ussom-dwishdb01' (99)")
message =
''