Edgewall Software
Modify

Opened 9 years ago

Closed 8 years ago

#8597 closed defect (fixed)

Modifications to Cc list can show 'removed' in comment even if no one was removed

Reported by: ryano@… Owned by: Remy Blank
Priority: low Milestone: 0.12.1
Component: ticket system Version: 0.11.4
Severity: normal Keywords: CcField, Ticket, CC
Cc:
Release Notes:
API Changes:

Description

The following conditions cause a modification to the cc field to display removed, even if no one was removed from the cc list.

Suppose I have a cc list that ends with a trailing comma. For example: randys, kenl,

I change the list to display: randys, kenl, boyde. I then see as shown in the attached screen capture:

  • cc boyde added; removed

However, if the cc list is: randys, kenl, boyde (note that there is no trailing comman to the cc list), then changing to: randys, kenl, boyde, allano I get:

  • cc allano added

Attachments (1)

CcListBug.png (3.8 KB ) - added by Ryan J Ollos 9 years ago.
CC List Bug

Download all attachments as: .zip

Change History (14)

Changed 9 years ago by Ryan J Ollos

Attachment: CcListBug.png added

CC List Bug

comment:1 Changed 9 years ago by ryano@…

Summary: Cc list can show 'removed' even if no one was removedModifications to Cc list can show 'removed' in comment even if no one was removed

Here is the screen capture:

CC List Bug

comment:2 Changed 9 years ago by ryano@…

On further inspection I believe the removed entry results because whitespace is being removed from the Cc list.

comment:3 Changed 9 years ago by Ryan Ollos <ryano@…>

Keywords: CcField Ticket added

comment:4 Changed 9 years ago by Ryan Ollos <ryano@…>

Seems like the best way to deal with this issue would be to remove trailing commas and whitespace before setting the Cc field. That should just be a few lines of code, right? I'm just starting to learn python, but if someone points me to the file where this is handled, I'd try working on a patch.

comment:5 Changed 9 years ago by Ryan Ollos <ryano@…>

Keywords: CC added; removed

comment:6 Changed 9 years ago by Ryan Ollos <ryano@…>

One other useful bit of information: On my Trac instance, when I add a list of comma separated keywords to the Keywords field, where the list has a trailing comma, I can see the trailing whitespace and comma are removed and the text box updated when the page is submitted.

I added a list of keywords with a trailing comment to this ticket, and I don't get the same behavior. However, the keywords field on this Trac instance does seem to behave appropriately, and does not exhibit the same behavior as the CC field on my Trac instance (0.11.4). See comment:3 and comment:5.

I suspect the behavior I see with the Keywords field on my Trac instance is due to having the KeywordsSuggestPlugin installed (version on trunk patched with keywords.patch from ticket 4201).

comment:7 Changed 9 years ago by Ryan Ollos <ryano@…>

Another piece of information: I'm using the AutocompleteUserPlugin, which appends a comma and a whitespace each time you add a username using the autocomplete function. I suspect the underlying problem I'm reporting in this ticket is an issue with Trac, but since I'm using the AutocompleteUserPlugin I see the behavior all the time, whereas users on a Trac instance without the AutocompleteUserPlugin may rarely see the behavior (unless they are in the habit of appending a comma to the user list in the Cc field).

To directly edit the Cc field appears to require TICKET_EDIT_CC permissions, which all users have on my Trac instance, but it doesn't look like I have that permission for Edgewall's Trac. Perhaps someone with the requisite permissions can try to reproduce the behavior on Edgewall's Trac.

comment:8 Changed 9 years ago by Christian Boos

Cc: randys kenl added

testing…

comment:9 Changed 9 years ago by Christian Boos

Cc: boyde added
Milestone: 0.12

Mmh, okay.

comment:10 Changed 9 years ago by Christian Boos

Cc: randys kenl boyde removed

(leaving randys and kenl alone :-) )

comment:11 Changed 9 years ago by Remy Blank

Milestone: 0.120.12.1

I'll take care of this.

comment:12 Changed 8 years ago by Remy Blank

Owner: set to Remy Blank

comment:13 Changed 8 years ago by Remy Blank

Resolution: fixed
Status: newclosed

Fixed in [10013], for both ticket creation and update.

Modify Ticket

Change Properties
Set your email in Preferences
Action
as closed The owner will remain Remy Blank.
The resolution will be deleted.
to The owner will be changed from Remy Blank to the specified user.

Add Comment


E-mail address and name can be saved in the Preferences .
 
Note: See TracTickets for help on using tickets.