Modify ↓
Opened 14 years ago
Closed 14 years ago
#8909 closed enhancement (fixed)
needs updates for 0.13dev
| Reported by: | jayen | Owned by: | Russ Tyndall |
|---|---|---|---|
| Priority: | normal | Component: | NeverNotifyUpdaterPlugin |
| Severity: | normal | Keywords: | |
| Cc: | Trac Release: | 0.12 |
Description
this is a patch my friend sent me:
Index: 0.12/nevernotifyupdaterplugin/api.py
===================================================================
--- 0.12/nevernotifyupdaterplugin/api.py (revision 10321)
+++ 0.12/nevernotifyupdaterplugin/api.py (working copy)
@@ -28,20 +28,21 @@
domain = ''
if defaultDomain: domain = '@'+defaultDomain
- cursor = self.db.cursor()
- # Suppress the updater from the recipients
- updater = None
- up_em = None
- cursor.execute("SELECT author FROM ticket_change WHERE ticket=%s "
- "ORDER BY time DESC LIMIT 1", (tktid,))
- for updater, in cursor: break
- else:
- cursor.execute("SELECT reporter FROM ticket WHERE id=%s",
- (tktid,))
- for updater, in cursor: break
+ with self.env.db_query as db:
+ cursor = db.cursor()
+ # Suppress the updater from the recipients
+ updater = None
+ up_em = None
+ cursor.execute("SELECT author FROM ticket_change WHERE ticket=%s "
+ "ORDER BY time DESC LIMIT 1", (tktid,))
+ for updater, in cursor: break
+ else:
+ cursor.execute("SELECT reporter FROM ticket WHERE id=%s",
+ (tktid,))
+ for updater, in cursor: break
- cursor.execute("SELECT value FROM session_attribute WHERE name='email' and sid=%s;",(updater,))
- for up_em, in cursor: break
+ cursor.execute("SELECT value FROM session_attribute WHERE name='email' and sid=%s;",(updater,))
+ for up_em, in cursor: break
def finder(r):
if not r:
Attachments (0)
Change History (4)
comment:1 Changed 14 years ago by
comment:2 follow-up: 3 Changed 14 years ago by
| Resolution: | → fixed |
|---|---|
| Status: | new → closed |
I think i got it all applied correctly, please let me know if you have more troubles. I am still running trac12
http://trac-hacks.org/browser/nevernotifyupdaterplugin/0.13
comment:3 Changed 14 years ago by
| Resolution: | fixed |
|---|---|
| Status: | closed → reopened |
Replying to bobbysmith007:
I think i got it all applied correctly, please let me know if you have more troubles. I am still running trac12
http://trac-hacks.org/browser/nevernotifyupdaterplugin/0.13
Dear bobbysmith007, I think the latest revision of the plugin nevernotifyupdater contains an error in line 35, from "self" is not necessary. Please please revise and update patches
comment:4 Changed 14 years ago by
| Resolution: | → fixed |
|---|---|
| Status: | reopened → closed |
Note: See
TracTickets for help on using
tickets.



sorry for the delayed response, I didnt see this ticket
Thanks for the patch, I will get it pushed up in a minute