Custom Query (332 matches)
Results (97 - 99 of 332)
Ticket | Resolution | Summary | Owner | Reporter |
---|---|---|---|---|
#101 | fixed | Correctly set custom field default values when creating a ticket | bas | ben@… |
Description |
Currently, all ticket custom fields are set to None instead of their proper default values when a ticket is created by email2trac. The patch below fixes the problem --- email2trac.py.in.txt (saved version) +++ (current document) @@ -682,7 +682,13 @@ # default trac value # - value = self.get_config('ticket', 'default_%s' %(name) ) + if not field.get('custom'): + value = self.get_config('ticket', 'default_%s' %(name) ) + else: + value = field.get('value') + options = field.get('options') + if value and options and value not in options: + value = options[int(value)] if self.DEBUG > 10: print 'trac.ini name %s = %s' %(name, value) |
|||
#102 | fixed | Can't update tickets from an email | bas | tim@… |
Description |
When I reply to a ticket and follow the conventions outlined in the documentation, the ticket does not update (either using commands in the subject or text in the body of the email). I see the following dump in my log: Nov 16 01:19:28 wilsonserver email2trac: TypeError?: unsupported operand type(s) for -: 'int' and 'datetime.datetime' Nov 16 01:19:28 wilsonserver email2trac: Traceback (most recent call last): Nov 16 01:19:28 wilsonserver email2trac: File "/usr/local/bin/email2trac", line 1284, in <module> tktparser.parse(sys.stdin) Nov 16 01:19:28 wilsonserver email2trac: File "/usr/local/bin/email2trac", line 845, in parse if self.ticket_update(m, spam_msg): Nov 16 01:19:28 wilsonserver email2trac: File "/usr/local/bin/email2trac", line 647, in ticket_update tkt.save_changes(self.author, body_text, when) Nov 16 01:19:28 wilsonserver email2trac: File "/usr/lib/python2.5/site-packages/Trac-0.11.2-py2.5.egg/trac/ticket/model.py", line 230, in save_changes when_ts = to_timestamp(when) Nov 16 01:19:28 wilsonserver email2trac: File "/usr/lib/python2.5/site-packages/Trac-0.11.2-py2.5.egg/trac/util/datefmt.py", line 56, in to_timestamp diff = dt - _epoc Nov 16 01:19:28 wilsonserver email2trac: TypeError?: unsupported operand type(s) for -: 'int' and 'datetime.datetime' I am using Trac 0.11.2, Fedora 7, Apache 2.2.7-1, Python 2.5-15 and email2trac-0.40 |
|||
#103 | fixed | get_param of Format/DelSp returns None | bas | debacle@… |
Description |
The following two lines in email2trac fail: format = email.Utils.collapse_rfc2231_value(part.get_param('Format')).lower() delsp = email.Utils.collapse_rfc2231_value(part.get_param('DelSp')).lower() This workaround helps, but I'm not sure, whether it is correct: format = email.Utils.collapse_rfc2231_value(part.get_param('Format') or "").lower() delsp = email.Utils.collapse_rfc2231_value(part.get_param('DelSp') or "").lower() |