wiki:TimingAndEstimationPlugin

Version 120 (modified by figaro, 9 years ago) (diff)

Cosmetic changes

Estimation and Time Tracking

Demo Site | User Manual | Open Tickets | New ticket

Description

This plugin adds estimation and time tracking to Trac. It basically adds CustomFields and CustomReports and an interface for filling the dynamic variables for the report. This plugin requires Javascript enabled to work.

Supported Versions

This plugin has been tested on:

  • Python >= 2.5 (perhaps more recent versions of Pythons will work on older Trac versions).
  • Trac >= 0.10
  • Database, should support all three major open source databases:
    • SQLite3 >= 3.6.8, required for SAVEPOINT calls to work
    • MySql
    • PostgreSQL
  • Genshi:
    • for Trac 0.11 you need Genshi >= v5
    • for Trac 0.12 you need Genshi >= v6 (Trac installs this automatically)

Documents

Bugs/Feature Requests

Existing bugs and feature requests for TimingAndEstimationPlugin are here.

If you have any issues, create a new ticket.

defect

237 / 244

enhancement

68 / 79

task

5 / 5

Download and Source

When downloading these files the extension is lost, or the filename corrupted. A simple rename to filename.zip seems to resolve it and the contents remain intact.

Email Notifications are currently unaffected by permissions

Browse the source

Older Versions

Download the source using Svn:

Download the zipped source:

  • [download:timingandestimationplugin/branches/trac0.12 Zipped source for plugin for Trac 0.12]
  • [download:timingandestimationplugin/branches/trac0.12-Permissions Zipped source for plugin for Trac 0.12]
  • [download:timingandestimationplugin/branches/trac0.11 Zipped source for plugin for Trac 0.11]
    • Trac 0.11 has inconsistent database and transaction management that has been fixed in Trac 0.12, see #8363.
  • [download:timingandestimationplugin/branches/trac0.11-Permissions Zipped source for plugin for Trac 0.11 with permissions]
  • [download:timingandestimationplugin/branches/trac0.10 Zipped source for plugin for Trac 0.10] - no longer maintained

Browse the source using Trac:

In the repository there is a script folder 0.12/0.11 that contains some Python files that I have written to perform billing queries across an entire directory of Tracs and email the results to a specified address. As these work in my setup, some paths at the top of each file may need to be changed. These are mostly included because I wrote them for myself and thought others might want to perform similar tasks.

Installation

To install this plugin follow these steps:

  1. The plugin can be installed either for a single project or globally. See the details on how to install a Trac plugin at TracPlugins.
  2. Enable the plugin in your trac.ini file as follows:
    [components]
    timingandestimationplugin.* = enabled
    
    • Alternatively, this can be enabled in the Web Admin section of the website as well.
  3. Run trac-admin /path/to/projenv upgrade and you should get a message like this:
    Timing and Estimation needs an upgrade
    Upgrading Database
    Creating bill_date table
    Upgrading fields
    Upgrading reports
    Upgrading usermanual
    Done Upgrading
    Upgrade done.
    
  4. Restart your webserver.

Post Installation Configuration Options

Components

By default, the TimingAndEstimationPlugin's four components will all be active. However, you can disable some of the components if you want to. The easiest way to do this is to ensure you have the trac:WebAdmin plugin installed.

The plugin's components are:

  1. TimeTrackingSetupParticipant
    Required component.
  2. TimeTrackingTicketObserver
    Ensures that the "Total Hours" values are updated when a user edits a ticket's "Add Hours to Ticket" field. You would not normally want to disable this component.
  3. TicketWebUiAddon
  4. TimingEstimationAndBillingPage

Permissions (Trac >= 0.11 only)

Email Notifications are currently unaffected by permissions

Post Commit Hooks

The scripts folder contains various post-commit scripts. The svn and git post receive/commit hooks call the trac-post-commit.py script with the correct command line arguments (see #8737 for more information and an alternative single file git-post-receive). There are a simple svn-post-commit.sh, a simple git-post-receive, and a more complex git_post_receive.py that tries to ensure that each commit is sent to Trac only once (by default moving a commit from one branch to another will cause the comment (and time) to be reposted to Trac, resulting in unintentional extra time on tickets.

Uninstallation

  • There is an uninstall script in the scripts folder that tries to make uninstall easy. I dont promise it will get everything, but it should get you most of the way there.
  • See #995, an old uninstall ticket, which might provide some insight.

Patches

Related Plugins

Interacting with T&E

If you want a plugin that you are writing to add reports to the management page, there is a file, reportmanager.py, that should make interacting with its reports easier.

Recent Changes

17249 by bobbysmith007 on 2018-07-30 16:26:11
Change db backend import stuff to allow running without all backends installed re #13462
17107 by bobbysmith007 on 2018-04-09 17:22:27
1.5.9(b) - fixed Decimal cast in ticket_daemon re #13405
17096 by bobbysmith007 on 2018-04-05 15:41:39
Fix hour summing in reports to not round partial hours

version 1.5.8(b)

re #13405

(more)

Author/Contributors

Author: bobbysmith007
Maintainer: Russ Tyndall
Contributors:

  • Aquafold has provided a license to their excellent Aqua Data Studio application to help further development
  • Obsidian Software sponsored the work to create a permission enabled branch
  • Alessio Massaro: wiki:masariello
    • Helped Get Reports working in postgres and started moving toward generic work rather than hours
  • kkurzweil@…
    • helped postgresql database backend compatibility
  • Jonas Borgstrom : t:wiki:JonasBorgstrom
    • made it so that base_url was unnecessary
  • Colin Guthrie
    • Refactored custom reports stuff into a single class/module that can be copied to other plugins, to make interaction with T&E easier.
  • David Abrahams
    • Trac.11 - Stream filters to prettify the Reports Screen and make TotalHours not editable
  • Tay Ray Chuan
    • Added a stopwatch to the ticket pages
  • Josh Godsiff, for Oxide Interactive
    • added props table client reformatting to remove extra whitespace