2

I use TRAC for project tracking and SVN for version control.
For their independent purposes, they work correctly.

I can check in and out code fine, and I can create tickets in TRAC fine.

Inside of TRAC, I had Browse Source set up to point to the SVN repo, and for months it worked fine. Then, suddenly it no longer picked up new updates.

A couple things happened around the same time, and its not clear which if any of these things caused the problem: - I created a new branch in the repo - The SVN and TRAC insances are on the same server, but the domain names went from being a single name, to being separate names.

After some digging, it was suggested to try to resync TRAC. When I do so, I get this error:

Traceback (most recent call last):
  File "/usr/bin/trac-admin", line 7, in ?
    sys.exit(
  File "/usr/lib/python2.4/site-packages/Trac-0.11.5-py2.4.egg/trac/admin/console.py", line 1314, in run
    return admin.onecmd(command)
  File "/usr/lib/python2.4/site-packages/Trac-0.11.5-py2.4.egg/trac/admin/console.py", line 133, in onecmd
    rv = cmd.Cmd.onecmd(self, line) or 0
  File "/usr/lib/python2.4/cmd.py", line 219, in onecmd
    return func(arg)
  File "/usr/lib/python2.4/site-packages/Trac-0.11.5-py2.4.egg/trac/admin/console.py", line 675, in do_resync
    repos = env.get_repository().sync(self._resync_feedback)
  File "/usr/lib/python2.4/site-packages/Trac-0.11.5-py2.4.egg/trac/versioncontrol/cache.py", line 214, in sync
    (str(next_youngest),
  File "/usr/lib/python2.4/site-packages/Trac-0.11.5-py2.4.egg/trac/db/util.py", line 59, in execute
    return self.cursor.execute(sql_escape_percent(sql), args)
  File "/usr/lib/python2.4/site-packages/MySQLdb/cursors.py", line 163, in execute
    self.errorhandler(self, exc, value)
  File "/usr/lib/python2.4/site-packages/MySQLdb/connections.py", line 35, in defaulterrorhandler
    raise errorclass, errorvalue
_mysql_exceptions.IntegrityError: (1062, "Duplicate entry '341-branches/delivery/apps/backend/modules/starcareCustomer-A' for key 1")

Revision 340 is the last revision that it displays inside of TRAC. I checked the database and it's not clear why this error is coming up.

Geoff Maddock
  • 1,700
  • 3
  • 26
  • 47
  • This is what i get for typing out a whole question. I immediately resolved this based on another tip. Changing the collation of the path column in the node_change table in the trac DB fixed the issue, I was able to resync and can see the updates in TRAC now. – Geoff Maddock Jul 25 '11 at 22:57
  • If you figured out how to solve it, post the solution as an answer. I'm sure somebody else with the same problem will stumble across this page in the future and they'll be glad you posted the information. – bta Jul 25 '11 at 23:45
  • I will, when it lets me, but i can't currently. – Geoff Maddock Jul 26 '11 at 00:36
  • Well, we're getting this today, the fact that this ends with "I fixed it" and no resolution details is really frustrating! – Mikey Hogarth Dec 10 '14 at 12:12
  • The answer I used is there. "Changing the collation of the 'path' column to utf8 in the 'node_change' table in the trac DB fixed the issue." – Geoff Maddock Dec 11 '14 at 21:04

1 Answers1

3

I immediately resolved this based on another tip. Changing the collation of the 'path' column to utf8 in the 'node_change' table in the trac DB fixed the issue. I was able to resync and can see the updates in TRAC now.

Geoff Maddock
  • 1,700
  • 3
  • 26
  • 47