Project

General

Profile

« Previous | Next » 

Revision 2725

sql.py: DbConn.print_notices(): Fixed bug where it should not do anything for a MySQL connection, because that doesn't store notices the way Postgres does

View differences:

lib/sql.py
279 279
        else: raise NotImplementedError("Can't mogrify query")
280 280
    
281 281
    def print_notices(self):
282
        for msg in self.db.notices:
283
            if msg not in self._notices_seen:
284
                self._notices_seen.add(msg)
285
                self.log_debug(msg, level=2)
282
        if hasattr(self.db, 'notices'):
283
            for msg in self.db.notices:
284
                if msg not in self._notices_seen:
285
                    self._notices_seen.add(msg)
286
                    self.log_debug(msg, level=2)
286 287
    
287 288
    def run_query(self, query, params=None, cacheable=False, log_level=2,
288 289
        debug_msg_ref=None):

Also available in: Unified diff