Edgewall Software

Ticket #5783 (closed defect: fixed)

Opened 2 years ago

Last modified 17 months ago

mysql connection drop issue, w/ patch

Reported by: amax@… Owned by: cboos
Priority: high Milestone: 0.10.5
Component: general Version: 0.10.4
Severity: normal Keywords: mysql
Cc:

Description

Hi,

We experienced a login defect with the AccountManagerPlugin, whose cause was eventually traced down to db/mysql_backend.py. Because the bug is in trac core, and not the plugin, we are recreating the ticket here. A patch that I believe fixes the issue is here:

 http://trac-hacks.org/attachment/ticket/1493/mysql-autologoutbug.patch

The original ticket is here:

 http://trac-hacks.org/ticket/1493

It is related to an older bug:

http://trac.edgewall.org/ticket/4802

In MySQLConnection.rollback(), the return value of self.cnx.ping() is checked (cnx is a MySQLdb connection object, IIRC). I believe this is faulty; ping() does not have a defined return value - see  http://groups.google.com/group/trac-dev/browse_thread/thread/9c8adb7cf6993500 . While in practice the existing version works for some (or many), the patch above seems to work more universally.

As a data point, we have been using the above patch in our trac here (~10 developers) for over two months now, and it has been holding up well in our heterogenous environment.

Attachments

Change History

Changed 20 months ago by cboos

  • keywords mysql added
  • owner changed from jonas to cboos
  • status changed from new to assigned
  • milestone set to 0.10.5

oops, I thought I fixed that already, but apparently not.

Changed 17 months ago by cboos

  • priority changed from normal to high

Similar error reported in #6806, and the proposed patch appears to work.

Changed 17 months ago by cboos

  • status changed from assigned to closed
  • resolution set to fixed

Patch applied in r6506 (trunk) and r6507 (0.10.5). Thanks!

Add/Change #5783 (mysql connection drop issue, w/ patch)

Author


E-mail address and user name can be saved in the Preferences.


Change Properties
<Author field>
Action
as closed
Next status will be 'reopened'
to The owner will change from cboos. Next status will be 'closed'
 
Note: See TracTickets for help on using tickets.