Changes between Version 6 and Version 7 of TracUpgrade
- Timestamp:
- Jun 20, 2020, 9:43:52 PM (4 years ago)
Legend:
- Unmodified
- Added
- Removed
- Modified
-
TracUpgrade
v6 v7 20 20 21 21 {{{#!sh 22 easy_install --upgrade Trac ==1.222 easy_install --upgrade Trac 23 23 }}} 24 24 … … 42 42 This command will not have any effect if the environment is already up-to-date. 43 43 44 Note that a backup of your database will be performed automatically prior to the upgrade. 45 This feature is relatively new for PostgreSQL or MySQL databases, so if it fails, you will have to backup the database manually. Then, to perform the actual upgrade: 46 {{{#!sh 47 trac-admin /path/to/projenv upgrade --no-backup 48 }}} 44 Note that a backup of your database will be performed automatically prior to the upgrade. The backup will be saved in the location specified by `[trac]` `backup_dir`. 49 45 50 46 === 4. Update the Trac Documentation === #UpdatetheTracDocumentation … … 59 55 === 5. Refresh static resources 60 56 61 If you have set up a web server to give out static resources directly (accessed using the `/chrome/` URL) then you will need to refresh them using the same command:57 If you have configured your web server to serve static resources directly (accessed using the `/chrome/` URL) then you will need to refresh them using the [TracInstall#MappingStaticResources same command]: 62 58 {{{#!sh 63 59 trac-admin /path/to/env deploy /deploy/path 64 60 }}} 65 61 66 This will extract static resources and CGI scripts (`trac.wsgi`, etc) from new Trac version and its plugins into `/deploy/path`. 67 68 Some web browsers (IE, Opera) cache CSS and Javascript files aggressively, so you may need to instruct your users to manually erase the contents of their browser's cache, a forced refreshed (`<F5>`) should be enough. 62 This will extract static resources and CGI scripts (`trac.wsgi`, etc) from the new Trac version and plugins into `/deploy/path`. 63 64 {{{#!div style="border: 1pt dotted; margin: 1em" 65 **Note:** Some web browsers (IE, Opera) cache CSS and Javascript files, so you should instruct your users to manually erase the contents of their browser's cache. A forced refreshed (SHIFT + <F5>) should be enough. 69 66 {{{#!comment 70 67 Remove above note once #9936 is fixed. 68 }}} 71 69 }}} 72 70 … … 94 92 ===== New workflow actions #NewWorkflowActions 95 93 96 The ticket creation step is controlled with a workflow action. The default workflow has `create` and `create_and_assign` actions. The `create` action will always be added when upgrading the database. The `create_and_assign` action will be added if the workflow has an //assigned// state. You may want to edit your workflow after upgrading the database to customize the actions available on the //New Ticket// page.94 The ticket creation step is controlled with a [TracWorkflow#TicketCreateAction workflow action]. The default workflow has `create` and `create_and_assign` actions. The `create` action will always be added when upgrading the database. The `create_and_assign` action will be added if the workflow has an //assigned// state. You may want to edit your workflow after upgrading the database to customize the actions available on the //New Ticket// page. 97 95 98 96 ===== New permissions policy for read-only wiki pages … … 119 117 120 118 * [https://trac-hacks.org/wiki/BatchModifyPlugin BatchModifyPlugin] 121 * [https://trac-hacks.org/wiki/GitPlugin GitPlugin]119 * [https://trac-hacks.org/wiki/GitPlugin GitPlugin] 122 120 * [https://trac-hacks.org/wiki/OverrideEditPlugin OverrideEditPlugin] 123 121 … … 161 159 162 160 * [https://trac-hacks.org/wiki/AutoQueryPlugin AutoQueryPlugin] 163 * [https://trac-hacks.org/wiki/AdminConsoleProviderPatch AdminConsoleProviderPatch]161 * [https://trac-hacks.org/wiki/AdminConsoleProviderPatch AdminConsoleProviderPatch] 164 162 * [https://trac-hacks.org/wiki/AnchorMacro AnchorMacro]: see WikiFormatting#SettingAnchors 165 163 * [https://trac-hacks.org/wiki/TicketChangePlugin TicketChangePlugin]: see [TracPermissions#TicketSystem TICKET_EDIT_COMMENT permission] … … 248 246 }}} 249 247 250 There are some significant caveats in this, such as accepting a ticket sets it to 'assigned' state, and assigning a ticket sets it to 'new' state. So you will probably want to migrate to "basic" workflow; [trac:source: trunk/contrib/workflow/migrate_original_to_basic.py contrib/workflow/migrate_original_to_basic.py] may be helpful. See TracWorkflow for a detailed description of the new basic workflow.248 There are some significant caveats in this, such as accepting a ticket sets it to 'assigned' state, and assigning a ticket sets it to 'new' state. So you will probably want to migrate to "basic" workflow; [trac:source:branches/1.2-stable/contrib/workflow/migrate_original_to_basic.py contrib/workflow/migrate_original_to_basic.py] may be helpful. See TracWorkflow for a detailed description of the new basic workflow. 251 249 252 250 === 7. Restart the Web Server #RestarttheWebServer … … 260 258 Trac supports customization of its Genshi templates by placing copies of the templates in the `<env>/templates` folder of your [TracEnvironment environment] or in a common location specified in the [[TracIni#GlobalConfiguration| [inherit] templates_dir]] configuration setting. If you choose to do so, be aware that you will need to repeat your changes manually on a copy of the new templates when you upgrade to a new release of Trac (even a minor one), as the templates will likely evolve. So keep a diff around. 261 259 262 The preferred way to perform TracInterfaceCustomization is to write a custom plugin doing an appropriate `ITemplateStreamFilter` transformation, as this is more robust in case of changes: we usually won't modify element `id`s or change CSS `class`es, and if we have to do so, this will be documented in the [trac:TracDev/ApiChanges] pages.260 The preferred way to perform TracInterfaceCustomization is to write a custom plugin doing an appropriate `ITemplateStreamFilter` transformation, as this is more robust in case of changes: we usually won't modify an element `id` or change its CSS `class`, and if we have to do so, this will be documented in the [trac:TracDev/ApiChanges] pages. 263 261 264 262 === !ZipImportError … … 283 281 === Upgrading Python 284 282 285 Upgrading Python to a newer version will require reinstallation of Python packages: Trac itself of course, but also [http ://pypi.python.org/pypi/setuptools easy_install], if you've been using that. If you are using Subversion, you'll also need to upgrade the Python bindings for svn.283 Upgrading Python to a newer version will require reinstallation of Python packages: Trac itself of course, but also [https://pypi.org/project/setuptools easy_install], if you've been using that. If you are using Subversion, you'll also need to upgrade the Python bindings for svn. 286 284 287 285 ==== Windows and Python 2.6 288 286 289 If you've been using !CollabNet's Subversion package, you may need to uninstall that in favor of [http ://alagazam.net/ Alagazam], which has the Python bindings readily available, see [trac:TracSubversion]. That package works without tweaking.287 If you've been using !CollabNet's Subversion package, you may need to uninstall that in favor of [https://alagazam.net/ Alagazam], which has the Python bindings readily available, see [trac:TracSubversion]. That package works without tweaking. 290 288 291 289 === Changing Database Backend