|Version 2 (modified by 7 years ago) ( diff ),|
Documenting API changes since 1.1.4
The next stable version of Trac will be named 1.2 and will contain the cumulative changes made in the successive 1.1.x releases.
Proposed changes are prefixed with an OPEN mark and the paragraph is written in italics.
- Detailed List of Developer Visible Changes
Other Modifications made to the 1.0 API
- Modified Interfaces
- New Interfaces
- Notification API Changes
- Database API Changes
- Template and CSS changes
- Uncategorized Changes
- New in the 1.1.5 API
Only Python versions 2.6 and 2.7 are supported.
The following language features introduced in Python 2.6 can now be used and the related clean-ups can be done:
- use string format(),
except Cls as val
- class decorators to avoid the
- there's no longer need of
from __future__ import with_statement
next(iterator, [default])to clean-up some unit tests
- timeout in smtplib
TODO List supported browsers. Consider using jQuery's list.
See gmessage:trac-dev:nkMUY_8ILF0/rg1rsArDIewJ for a discussion about what dependencies we'll support in Trac 1.2.
jQuery and jQuery UI (bundled)
The bundled version of jQuery will be 1.9 / 2.0 instead of 1.8.3 in Trac 1.1.1.
See jQuery release notes for the corresponding major updates:
Babel ≥ 0.9.5 is still supported.
OPEN Genshi 0.7
Genshi 0.6.x is still supported.
|MySQL / MariaDB||≥ 5.0|
|pysqlite||≥ 2.4.1 (version provided by Python 2.6), avoid 2.5.2 - 2.5.4|
|Package||Req or Opt?||Version supported|
|SetupTools||Required||≥ 0.6, 5.4 - 5.6 are not recommended.|
|ConfigObj||Optional||Unspecified. Let's consider enforcing a minimum version, such as ≥ 5.0. ConfigObj 5.0 released on 2014-02-15|
|Pygments||Optional||≥ 0.6. Let's consider bumping the requirement to at least 1.0, released in 2008|
… please add any dependencies I've overlooked.
Deprecated Modules Removed
DONE Removed Enscript, SilverCity and PHP renderers.
Detailed List of Developer Visible Changes
|#10975||Enhancement for the contrib/htpasswd.py script|
Component: database backend (1 match)
|#11978||Add drop_schema method to ConnectionBase class|
Component: general (4 matches)
|#6551||IntOption and BoolOption values saved even when not differing from default|
|#8172||Plugin db upgrade infrastructure|
|#11982||Remove dependency on ConfigObj|
|#12008||Deleting unevaluated `@lazy` attribute raises KeyError|
Component: notification (1 match)
|#11875||Notification subscriber config section|
Component: rendering (1 match)
|#12010||Pygments preferences template should be located in mimeview package|
Component: timeline (1 match)
|#12048||[PATCH] Add scope to CSS rules in timeline.css|
Timeline CSS rules are scoped to the
Component: version control (1 match)
|#11995||Versioncontrol API for changeset bookmarks|
Other Modifications made to the 1.0 API
Take the will be removed in version 1.1.1 comments in the code seriously. The earlier the planned API changes in 1.1.x, the better (gives more time to plugin authors to adapt). TODO
Wiki page version comments can now be edited, so
wiki_page_comment_modified(page, old_comment) has been added to allow plugins to be notified of this.
Notification API Changes
Database API Changes
Methods have been added to
DatabaseManager class for settings and retrieving the database version for Trac and plugins:
Environment.get_db_cnx has been removed
Following the deprecation made in 0.12, the method
Environment.get_db_cnx has been removed.
One should now only use the context managers for retrieving a database Connection in read or write mode.
- a read-only Connection can be used to form queries:
with env.db_query as db: ...
dbinstance obtained the above way should only be used for executing SELECT queries
- a writable Connection can be used to modify the database content in a transaction:
with env.db_transaction as db: ...
dbinstance obtained the above way can be used to execute INSERT/UPDATE/DELETE queries; they will be committed when the last such automatic transaction in the control flow completes successfully. See DatabaseApi for the full details.
Environment.get_read_db and the decorators
env.with_transaction() have been deprecated since Trac 1.0 and will be removed in Trac 1.3.1.
db parameters removed from function and method signatures
With the introduction of
@with_transaction(env) decorators in 0.12 and continuing with the introduction of the database connection context managers in 1.0, the
db parameters passed as function and method arguments became deprecated.
db parameters have been removed from nearly all function and method signatures. The
db arguments are still present on methods of
IEnvironmentParticipant implementations, but are deprecated and should no longer be used. They will be removed in 1.3.1.
ConnectionBase class defines an abstract interface that database backends must adhere to when implementing a
Template and CSS changes
tt tags are not support in HTML5 and have been replaced with
code tags in Trac (#11094). The styling of
code tags is the same in Trac , but
code tags should be used since the styling for
tt tags will be removed in a future version of Trac.
about.css stylesheet has been removed and the rules contained in that stylesheet have been moved to
trac.css. The table of environment information on the Error and About pages have been extracted to a new template
environment_info.html and the markup and associated rules in the stylesheet have been significantly changed.
DONE Removed the deprecated
authname parameter from
TODO Log warnings for deprecated functions and methods (comment:26:ticket:11605)
New in the 1.1.5 API
TODO Remove Since info from docstrings for Trac < 0.12.
This is a work in progress - coverage is still not yet complete.