Edgewall Software

Ticket #6095 (closed defect: duplicate)

Opened 11 months ago

Last modified 9 months ago

Attempting to rename priority can get a unique constraint violation

Reported by: s.dallaway@… Owned by: jonas
Priority: low Milestone:
Component: general Version: 0.10.4
Severity: minor Keywords:
Cc:

Description (last modified by eblot) (diff)

If you stupidly use the web admin module (looks neat BTW) to rename a priority to an existing name you get a unique constraint violation.

Traceback (most recent call last):
  File "C:\Program Files\Python 2.4\Lib\site-packages\trac\web\main.py", line 406, in dispatch_request
    dispatcher.dispatch(req)
  File "C:\Program Files\Python 2.4\Lib\site-packages\trac\web\main.py", line 237, in dispatch
    resp = chosen_handler.process_request(req)
  File "c:\program files\python 2.4\lib\site-packages\tracwebadmin-0.1.2dev_r5911-py2.4.egg\webadmin\web_ui.py", line 119, in process_request
    path_info)
  File "c:\program files\python 2.4\lib\site-packages\tracwebadmin-0.1.2dev_r5911-py2.4.egg\webadmin\ticket.py", line 310, in process_admin_request
    enum.update()
  File "C:\Program Files\Python 2.4\Lib\site-packages\trac\ticket\model.py", line 400, in update
    (self.name, self.value, self.type, self._old_name))
  File "C:\Program Files\Python 2.4\Lib\site-packages\trac\db\util.py", line 50, in execute
    return self.cursor.execute(sql_escape_percent(sql), args)
  File "C:\Program Files\Python 2.4\Lib\site-packages\trac\db\util.py", line 50, in execute
    return self.cursor.execute(sql_escape_percent(sql), args)
IntegrityError: duplicate key violates unique constraint "enum_pk"

Attachments

Change History

Changed 11 months ago by eblot

  • description modified (diff)

Please fill in the version field with the appropriate value.

Changed 11 months ago by Simon Dallaway <s.dallaway@…>

  • version set to 0.10.4

Changed 9 months ago by cboos

  • status changed from new to closed
  • resolution set to duplicate

Still present in trunk. This should be fixed in a more general way, see #6348.

Add/Change #6095 (Attempting to rename priority can get a unique constraint violation)

Author



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