Modify ↓
#223 closed defect (fixed)
Incorrectly sets the number of comments
Reported by: | stas.agarkov@… | Owned by: | bas |
---|---|---|---|
Priority: | major | Milestone: | |
Component: | email2trac | Version: | 1.6.0 |
Keywords: | Cc: |
Description
email2trac incorrectly sets the number of comments, because it is based on a number of changes to the table ticket_change. trac uses the TicketModule?.grouped_changelog_entries, which returns a list of changes, in which simultaneous changes are grouped into one that is as it appears in the trac. Your code:
## How many changes has this ticket # cnum = len(tkt.get_changelog())
Right code:
# How many changes has this ticket from trac.ticket.web_ui import TicketModule grouped = TicketModule(self.env).grouped_changelog_entries(tkt, self.db) cnum = sum(1 for e in grouped) + 1
Attachments (0)
Change History (2)
comment:1 Changed 13 years ago by bas
- Resolution set to fixed
- Status changed from new to closed
comment:2 Changed 13 years ago by bas
Thanks for the patch
Note: See
TracTickets for help on using
tickets.
(In [486]) Fixed the calculation of number of ticket changes, closes #223