Project

General

Profile

Actions

Defect #20995

closed

Automatic done ratio calculation in issue tree is wrong in some cases

Added by Felix Schäfer about 9 years ago. Updated about 9 years ago.

Status:
Closed
Priority:
Normal
Category:
Issues
Target version:
Start date:
Due date:
% Done:

0%

Estimated time:
Resolution:
Fixed
Affected version:

Description

Currently the done ratio of parent issues in an issue tree is calculated based on the average of done ratios of the leaves bellow that issue source:/tags/3.1.1/app/models/issue.rb#L1491. This however can lead to inconsistencies in the automatically calculated done ratios.

For example: issue C with a done ratio of 50% and an open status, which is a subtask of issue B with a done ratio of 70% automatically set by its (open) status, which itself is a subtask of issue A, with a status that doesn't automatically set the done ratio. In that case, A will have an automatically calculated done ratio of 50% because it will be calculated based on the leaf's done ratios, i.e. from C, although its only direct child has a done ratio of 70%.

Is there any rationale to keeping the calculation of the done ratio based on the leaves? I would like to change it to be calculated based on the done ratios of the direct children. If this is an acceptable change I can work on a patch.


Files


Related issues

Related to Redmine - Defect #23511: Progress of parent task should be calculated using total estimated hours of childrenClosedJean-Philippe Lang

Actions
Actions

Also available in: Atom PDF