Dear Franz and others,
Thanks for the suggestion. My issue was different, so I had to figure out a solution for myself. The main problem for me was that the upgrade progress for attachments (db28.py) is connected to a database version. Because my database was already upgraded, the upgrade assumes my attachments are correct and skips it.
My solution was to start the upgrade manually from a python script:
#!/usr/bin/python
from __future__ import with_statement
import sys
from trac.env import open_environment
from trac.upgrades.db28 import do_upgrade
env = open_environment(sys.argv[1])
print 'Fixing attachments for environment', env.project_name, 'at', sys.argv[1]
with env.db_transaction as db:
cursor = db.cursor()
do_upgrade(env, None, cursor)
db.commit()
And then apply it to my broken environment:
> python fix.py /path/to/broken/environment
I hope sharing this fragment will help others.
With regards,
Morpheus Kennistechnologie BV
<URL: http://www.mssm.nl >
postbus 69
3500 CD Utrecht
KVK 30 26 04 30