Edgewall Software

Changes between Version 9 and Version 10 of TracFaq


Ignore:
Timestamp:
Mar 3, 2014, 10:28:27 PM (10 years ago)
Author:
anonymous
Comment:

"Attachment missing after upgrade" qualifies as a FAQ

Legend:

Unmodified
Added
Removed
Modified
  • TracFaq

    v9 v10  
    5656**A:** You most certainly forgot to stop and restart your server during an upgrade. The zip importer  mechanism keeps an internal cache which has trouble detecting replaced files, so a restart is needed (see TracUpgrade#ZipImportError). Do it now.
    5757
     58=== Upgrade troubleshooting
     59
    5860==== Q: Trac /about says 1.0, but the style looks pre-1.0
    5961
     
    7173
    7274
     75==== Q: Attachments are missing after upgrade
     76
     77**A:** Most likely db28.py failed. See #11370. Please report any additional information on the MailingList.
     78
     79You can try to create a `rundb28.py` script:
     80{{{#!python
     81#!/usr/bin/python
     82from __future__ import with_statement
     83import sys
     84from trac.env import open_environment
     85from trac.upgrades.db28 import do_upgrade
     86
     87env = open_environment(sys.argv[1])
     88print 'Fixing attachments for environment', env.project_name, 'at', sys.argv[1]
     89with env.db_transaction as db:
     90        cursor = db.cursor()
     91        do_upgrade(env, None, cursor)
     92        db.commit()
     93}}}
     94
     95And then apply it to the broken environment:
     96{{{
     97> python rundb28.py /path/to/broken/environment
     98}}}
    7399
    74100== Trac development