Skip to content

Commit

Permalink
1.6dev: Sync from t.e.o wiki
Browse files Browse the repository at this point in the history
Refs #13333


git-svn-id: http://trac.edgewall.org/intertrac/log:/trunk@17718 af82e41b-90c4-0310-8c96-b1721e28e2e2
  • Loading branch information
rjollos committed Sep 22, 2023
1 parent f7eba7b commit f320b8a
Show file tree
Hide file tree
Showing 5 changed files with 78 additions and 25 deletions.
4 changes: 3 additions & 1 deletion RELEASE.rst
Original file line number Diff line number Diff line change
@@ -1,9 +1,11 @@
Release Notes for Trac 1.6 'Py3' Release
===========================================
Not yet released
September 23, 2023

Highlights
----------
* Supports Python 3.5 and later.
* Drop support for Python 2.

Detailed User Visible Changes
-----------------------------
Expand Down
5 changes: 4 additions & 1 deletion trac/wiki/default-pages/InterMapTxt
Original file line number Diff line number Diff line change
Expand Up @@ -84,7 +84,10 @@ MediaWiki https://www.mediawiki.org/wiki/

SO https://stackoverflow.com/questions/ # Question $1 in StackOverflow

Transifex https://www.transifex.com/projects/p/trac/
Transifex https://www.transifex.com/cboos/trac/
TransifexLang https://www.transifex.com/cboos/trac/language/$1/
TransifexResource https://www.transifex.com/cboos/trac/$1/
TransifexView https://www.transifex.com/cboos/trac/viewstrings/#$1/$2

kwquery /query?group=status&keywords=~ # Custom query for tickets matching keyword $1

Expand Down
48 changes: 48 additions & 0 deletions trac/wiki/default-pages/TracChangeLog
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,22 @@ This is a rough list of changes between released versions.

To see where Trac is going in future releases, see the [trac:roadmap Roadmap].

== 1.6.x Releases

=== '''1.6 'Py3''''

//(September 23, 2023)//

Trac 1.6 is the first major release of Trac in almost 4 years.

This is the first release to support Python 3, supporting Python
3.5 and later. Python 2 is no longer supported.

For more information see the [trac:wiki:TracDev/ApiChanges/1.6 API changes] and the detailed
release notes for [[trac:wiki:TracDev/ReleaseNotes/1.6|1.6]] and the change log for [#a1.5.xReleases 1.5.x Releases] below.

[trac:source:/tags/trac-1.6 View Tag] | [trac:milestone:1.6 View Milestone]

== 1.5.x Releases

=== 1.5.4
Expand Down Expand Up @@ -56,6 +72,38 @@ releases will support Python 3.5+.

== 1.4.x Releases

=== 1.4.4

//(August 11, 2023)//

Trac 1.4.4 contains about a dozen minor fixes
and improvements.

[trac:source:/tags/trac-1.4.4 View Tag] | [trac:milestone:1.4.4 View Milestone]

=== 1.4.3

//(May 9, 2021)//

Trac 1.4.3 contains about a dozen minor fixes
and improvements.

[trac:source:/tags/trac-1.4.3 View Tag] | [trac:milestone:1.4.3 View Milestone]

=== 1.4.2

//(June 17, 2020)//

Trac 1.4.2 has more than a dozen minor fixes and
improvements, including the following highlights:

* Batch modify has autopreview for comment textarea
and better form styling ([trac:#13285]).
* TracAdmin `config remove <section>` command
deletes a configuration section ([trac:#13305]).

[trac:source:/tags/trac-1.4.2 View Tag] | [trac:milestone:1.4.2 View Milestone]

=== 1.4.1

//(February 12, 2020)//
Expand Down
25 changes: 11 additions & 14 deletions trac/wiki/default-pages/TracPlugins
Original file line number Diff line number Diff line change
Expand Up @@ -6,11 +6,11 @@ Trac is extensible with [trac:PluginList plugins]. Plugin functionality is based

== Plugin discovery

A plugin is either a single .py file or a package (.egg or .whl). Trac looks for plugins in Python's `site-packages` directory, the [TracIni#GlobalConfiguration global shared] `plugins` directory and the [TracEnvironment project environment] `plugins` directory. Plugins installed to the project environment `plugins` directory are enabled, unless explicitly disabled in the `[components]` section of the `trac.ini` file. Plugins installed elsewhere must be explicitly enabled in the [TracIni#components-section "[components]"] section of the `trac.ini` file.
A plugin is either a single .py file or a package (.egg or .whl). Trac looks for plugins in Python's `site-packages` directory, the [TracIni#GlobalConfiguration global shared] `plugins` directory and the [TracEnvironment project environment] `plugins` directory. Plugins installed to the project environment `plugins` directory are enabled, unless explicitly disabled in the `[components]` section of the `trac.ini` file. Plugins installed elsewhere must be explicitly enabled in the [TracIni#components-section "[components]"] section of the `trac.ini` file.

== Installing a Trac plugin

The instructions below are applicable to a plugins installed as packages. Plugins implemented as a single `py` file should be downloaded and copied to the [TracEnvironment project environment] `plugins` directory or the [TracIni#GlobalConfiguration global shared] plugins directory.
The instructions below are applicable to plugins installed as packages. Plugins implemented as a single `py` file should be downloaded and copied to the [TracEnvironment project environment] `plugins` directory or the [TracIni#GlobalConfiguration global shared] plugins directory.

=== For a single project

Expand All @@ -24,7 +24,7 @@ $ python setup.py bdist_egg
The egg file will be created in the `dist` subdirectory.
* Copy the egg file to the `plugins` directory of the [TracEnvironment project environment].

Make sure the web server has sufficient permissions to read the plugin egg and restart the web server. If you are running as a [TracStandalone "tracd" standalone server], restart tracd (i.e. kill the process and run again).
Make sure the web server has sufficient permissions to read the plugin egg and restart the web server. If you are running as a [TracStandalone "tracd" standalone server], restart tracd, i.e. kill the process and run again.

Trac also searches for plugins installed in the [TracIni#GlobalConfiguration global shared] plugins directory. This is a convenient way to share the installation of plugins across several, but not all, environments.

Expand All @@ -42,9 +42,7 @@ Remove the egg from the `plugins` directory and restart the web server.

The modern Python package manager, `pip`, is included in Python 2.7.9 and later. In earlier versions of Python it can be installed through the package manager of your OS (e.g. `apt-get install python-pip`) or using [https://pip.pypa.io/en/latest/installing.html#install-pip get_pip.py].

Using `pip`, the plugin will be installed
in the [https://pythonwheels.com/ wheel format], which is the modern standard for Python and a
replacement for the egg format.
Using `pip`, the plugin will be installed in the [https://pythonwheels.com/ wheel format], which is the modern standard for Python and a replacement for the egg format.

==== From PyPI

Expand All @@ -55,7 +53,7 @@ $ pip install TracTags

The version can be specified, which can be useful if you don't want to install the latest:
{{{#!sh
$ pip install TracTags==0.10
$ pip install TracTags==1.2
}}}

==== From source
Expand All @@ -65,8 +63,7 @@ You can install directly from a source repository:
$ pip install svn+https://trac-hacks.org/svn/tagsplugin/trunk
}}}

Replace the `svn+` prefix with `git+` if installing
from a Git repository.
Replace the `svn+` prefix with `git+` if installing from a Git repository.

Or from the path or URL of a tar.gz or zip archive:
{{{#!sh
Expand Down Expand Up @@ -97,7 +94,7 @@ After installing the plugin, you must restart your web server.

==== Upgrading the environment

Some plugins require an environment upgrade. This will typically be necessary for plugins that implement `IEnvironmentSetupParticipant`. Common reasons for requiring an environment upgrade are to add tables to the database or add configuration parameters to trac.ini. A notification will be displayed when accessing Trac for the first time after installing a plugin and restarting the web server. To upgrade the environment, run the command:
Some plugins require an environment upgrade. This will typically be necessary for plugins that implement `IEnvironmentSetupParticipant`. Common reasons for requiring an environment upgrade are to add tables to the database or add configuration parameters to `trac.ini`. A notification will be displayed when accessing Trac for the first time after installing a plugin and restarting the web server. To upgrade the environment, run the command:

{{{#!sh
$ trac-admin /path/to/env upgrade
Expand All @@ -107,7 +104,7 @@ A database backup will be made before upgrading the environment, unless the `--n

==== Redeploying static resources

If you [TracInstall#MappingStaticResources mapped static resources] so they are served by the web server, and the plugin contains static resources (CSS, !JavaScript and image files), the resources will need to be deployed to the location on the filesystem that is served by the web server.
If you [TracInstall#MappingStaticResources mapped static resources] so they are served by the web server, and the plugin contains static resources, such as stylesheets, !JavaScript and image files, the resources will need to be deployed to the location on the filesystem that is served by the web server.

Execute the `deploy` command, as is done during install and [TracUpgrade#a5.Refreshstaticresources upgrade]:

Expand Down Expand Up @@ -189,7 +186,7 @@ Or for mod_python:

'''Note''': !SetEnv requires the `mod_env` module, which needs to be activated for Apache. In this case the !SetEnv directive can also be used in the `mod_python` Location block.

For [TracFastCgi FastCGI], you'll need to `-initial-env` option, or whatever is provided by your web server for setting environment variables.
For [TracFastCgi FastCGI], you will need to `-initial-env` option, or whatever is provided by your web server for setting environment variables.

'''Note''': if you already use -initial-env to set the project directory for either a single project or parent, you will need to add an additional -initial-env directive to the !FastCgiConfig directive:

Expand All @@ -212,7 +209,7 @@ You can write your own Trac plugin using the following resources:

=== Did you get the correct version of the Python egg?

Python eggs have the Python version encoded in their filename. For example, `MyPlugin-1.0-py2.5.egg` is an egg for Python 2.5, and will '''not''' be loaded if you're running a different Python version (such as 2.4 or 2.6).
Python eggs have the Python version encoded in their filename. For example, `MyPlugin-1.0-py2.5.egg` is an egg for Python 2.5, and will '''not''' be loaded if you're running a different Python version, such as 2.4 or 2.6.

Also, verify that the egg file you downloaded is indeed a .zip archive. If you downloaded it from a Trac site, you may have downloaded the HTML preview page instead.

Expand Down Expand Up @@ -243,7 +240,7 @@ If you put your plugins in one of the `plugins` directories, and certainly if yo

* Only one version of the plugin can be loaded for each running Trac server, i.e. each Python process. The Python namespaces and module list will be shared, and it cannot handle duplicates. Whether a plugin is `enabled` or `disabled` makes no difference.
* A globally installed plugin will override any version in the global or project plugins directories. A plugin from the global plugins directory will be discovered ''before'' any project plugins directory.
* If your Trac server hosts more than one project (as with `TRAC_ENV_PARENT_DIR` setups), having two versions of a plugin in two different projects will give unpredicatable results. Only one of them will load, and the one loaded will be shared by both projects. Trac will load the first plugin found, usually from the project that receives the first request.
* If your Trac server hosts more than one project (as with `TRAC_ENV_PARENT_DIR` setups), having two versions of a plugin in two different projects will give unpredictable results. Only one of them will load, and the one loaded will be shared by both projects. Trac will load the first plugin found, usually from the project that receives the first request.
* Having more than one version listed inside Python site-packages is fine, because setuptools will make sure you get the version installed most recently. However, don't store more than one version inside a global or project plugins directory: neither the version number nor the installed date will matter at all. There is no way to determine which one will be located first when Trac searches the directory for plugins.

=== If all of the above failed
Expand Down
21 changes: 12 additions & 9 deletions trac/wiki/default-pages/TracRepositoryAdmin
Original file line number Diff line number Diff line change
Expand Up @@ -3,14 +3,15 @@

== Quick start #QuickStart

Trac is primarily used as an issue tracking and project planning system, but can also be used to connect to and maintain source code repositories. This page describes the guidelines and caveats when connecting Trac to a repository.
* Enable the repository connector(s) for the version control system(s) that you will use.
* Add repositories through the //Repositories// admin page, using `trac-admin` or by editing the `[repositories]` section of [[wiki:TracIni#repositories-section|trac.ini]].
* Synchronize the repositories with the cache, if using cached repositories.
* Configure your repository hooks to synchronize the repository. Alternatively you can synchronize on every request or disable the use of cached repositories, both of which have performance drawbacks and reduced functionality, but are easier to configure.

== Enabling the components

Support for version control systems is provided by optional components distributed with Trac, which are disabled by default //(since 1.0)//. Subversion and Git must be explicitly enabled if you wish to use them.
Support for version control systems is provided by optional components distributed with Trac, which are disabled by default. Subversion and Git must be explicitly enabled if you wish to use them.

The version control systems can be enabled by adding the following to the `[components]` section of your [TracIni#components-section trac.ini], or enabling the components through the //Plugins// admin page.

Expand Down Expand Up @@ -38,9 +39,7 @@ From the Repository Admin page, the default repository is specified by leaving t

=== Repository Attributes

There are a number of attributes that can be specified for each repository, and additional attributes may be available through plugins. A repository `name` and one of the `alias` or `dir` attributes are mandatory. All others are optional.

The following attributes are supported:
A repository is defined through the attribute `name` and one of the `alias` or `dir` attributes, all other attributes are optional:

||='''Attribute''' =||='''Description''' =||
||`alias` ||\
Expand All @@ -50,15 +49,19 @@ The following attributes are supported:
||`description` ||\
||The text specified in the `description` attribute is displayed below the top-level entry for the repository in the source browser. It supports WikiFormatting. ||
||`dir` ||\
||The `dir` attribute specifies the location of the repository in the filesystem. The `alias` and `dir` attributes are mutually exclusive. ||
|| Specifies the location of the repository in the filesystem. The `alias` and `dir` attributes are mutually exclusive. ||
||`hidden` ||\
|| When set to `true`, the repository is hidden from the repository index page in the source browser. Browsing the repository is still possible, and links referencing the repository remain valid. ||
||`name` ||\
|| Identifies the version control system used by the repository. This field is mandatory. ||
||`sync_per_request`||\
|| When set to `true` the repository will be synchronized on every request (implicit synchronization). This is generally not recommended. See [#Synchronization repository synchronization] for a comparison of explicit and implicit synchronization. The attribute defaults to `false`. ||
||`type` ||\
|| The `type` attribute specifies the version control system used by the repository. Trac provides support for Subversion and Git, and plugins add support for several other systems. If `type` is not specified, it defaults to the value of the `[versioncontrol]` [wiki:TracIni#versioncontrol-default_repository_type-option default_repository_type] option. ||
|| Specifies the version control system used by the repository. Trac provides support for Subversion and Git, and plugins add support for several other systems. If `type` is not specified, it defaults to the value of the `[versioncontrol]` [wiki:TracIni#versioncontrol-default_repository_type-option default_repository_type] option. ||
||`url` ||\
|| The `url` attribute specifies the root URL to be used for checking out from the repository. When specified, a "Repository URL" link is added to the context navigation links in the source browser, that can be copied into the tool used for creating the working copy. ||
|| Specifies the root URL to be used for checking out from the repository. When specified, a "Repository URL" link is added to the context navigation links in the source browser, that can be copied into the tool used for creating the working copy. ||

Additional attributes may be available through plugins.

=== Scoped Repository

Expand Down Expand Up @@ -273,13 +276,13 @@ See [trac:CommitTicketUpdater#Troubleshooting] for more troubleshooting tips.

=== Git control files missing

If your repository is not browseable and you find a message in the log that looks like:
If your repository is not browsable and you find a message in the log that looks like:
{{{
2017-08-08 10:49:17,339 Trac[PyGIT] ERROR: GIT control files missing in '/path/to/git-repository'
2017-08-08 10:49:17,339 Trac[git_fs] ERROR: GitError: GIT control files not found, maybe wrong directory?
}}}

First check that the path to your repository is correct. If the path is correct, you may have a permission problem whereby the web server cannot access the repository. You can use Git to verify the repository. On a Debian-like Linux OS, the following command should help:
First check that the path to your repository is correct. If the path is correct, you may not have the permission to have the web server access the repository. You can use Git to verify the repository. On a Debian-like Linux OS, the following command should help:
{{{#!sh
$ sudo -u www-data git --git-dir=/path/to/git-repository fsck
}}}
Expand Down

0 comments on commit f320b8a

Please sign in to comment.