Feature #10989
closedPrevent parent issue from being closed if a child issue is open
Description
I am able to close a parent issue while its Child issues are yet not closed/rejected, ideally it should not let a use to close a Parent issue, until all it's child issues are not closed.
Files
Related issues
Updated by Jean-Philippe Lang about 14 years ago
- Tracker changed from Defect to Feature
- Subject changed from Parent issue can be closed, while it's child issues are still open to Prevent parent issue from being closed, while it's child issues are still open
- Assignee deleted (
Azamat Hackimov) - Priority changed from High to Normal
Updated by Toshi MARUYAMA over 11 years ago
- Has duplicate Feature #12956: Warning "parent issue is closed" added
Updated by Toshi MARUYAMA over 11 years ago
- Has duplicate Feature #18212: The status of parent issue could be changed to closed before all of the sub issues' status are changed to closed added
Updated by Go MAEDA almost 10 years ago
I think the behavior is logical and this feature is really needed.
#18212 has a patch.
Updated by Marius BĂLTEANU almost 10 years ago
This means also that we shouldn't be able to add to a new/open issue a parent which is already closed?
Updated by Marius BĂLTEANU almost 10 years ago
I made a patch (inspired from #18212) with tests that implements this feature request.
@Go MAEDA, I still think that in order to implement this completely, we should not allow to set for a new/open issue a parent which is already closed. I'm waiting for your feedback (or other Redmine contributors) in order to include also this change in the patch.
Updated by Toshi MARUYAMA almost 10 years ago
- Related to Feature #13585: Make sub-task inherit the properties of parent added
Updated by Toshi MARUYAMA almost 10 years ago
- Related to deleted (Feature #13585: Make sub-task inherit the properties of parent)
Updated by Toshi MARUYAMA almost 10 years ago
- Related to Feature #13585: Make sub-task inherit the properties of parent added
Updated by Toshi MARUYAMA almost 10 years ago
- Has duplicate Feature #5462: Blocking issues to be closed which have open subtasks added
Updated by Toshi MARUYAMA almost 10 years ago
Marius BALTEANU wrote:
I made a patch (inspired from #18212) with tests that implements this feature request.
LGTM.
I have some questions.
What happens if opened child issues which user cannot see (private/visibility)?
error_can_not_close_issue_with_open_subtasks: "An issue with open subtasks cannot be closed"
Would it better "An issue" -> "The issue"?
@Go MAEDA, I still think that in order to implement this completely, we should not allow to set for a new/open issue a parent which is already closed. I'm waiting for your feedback (or other Redmine contributors) in order to include also this change in the patch.
I think this would better in separate issue.
Updated by Marius BĂLTEANU almost 10 years ago
Toshi MARUYAMA wrote:
The user will receive the same error message and I think that is the correct behavior because any open subtask means work to do (from my point of view).What happens if opened child issues which user cannot see (private/visibility)?
If you have the following scenario:
- Issue with 4 subtasks
- Two are visible to my role
- Other two are visible to another role.
Closing my subtasks doesn't means that the parent issue can be closed, it means only that I made my piece of work. If you think that it'll be confusing for the users, we can improve the error message.
Would it better "An issue" -> "The issue"?
I took some internal feedback and the new proposal is "You cannot close an issue with open subtasks.". Let me know what do you think in order to update the patch.
@Go MAEDA, I still think that in order to implement this completely, we should not allow to set for a new/open issue a parent which is already closed. I'm waiting for your feedback (or other Redmine contributors) in order to include also this change in the patch.
I think this would better in separate issue.
Agree, I'll open a new issue.
Updated by Toshi MARUYAMA over 9 years ago
- Target version set to Candidate for next major release
Updated by Toshi MARUYAMA over 9 years ago
Marius BALTEANU wrote:
Let me know what do you think in order to update the patch.
Please update the patch.
Updated by Marius BĂLTEANU over 9 years ago
- File cant_close_before_sub_issues_closed_v2.patch cant_close_before_sub_issues_closed_v2.patch added
Here it is.
Updated by Toshi MARUYAMA over 9 years ago
- Target version changed from Candidate for next major release to 3.4.0
Updated by Marius BĂLTEANU over 9 years ago
- File cant_close_before_sub_issues_closed_v3.patch cant_close_before_sub_issues_closed_v3.patch added
Fixed the expected error message in the test.
Updated by Jean-Philippe Lang over 9 years ago
- Subject changed from Prevent parent issue from being closed, while it's child issues are still open to Prevent parent issue from being closed if a child issue is open
- Status changed from New to Closed
- Assignee set to Jean-Philippe Lang
- Resolution set to Fixed
Added in r16108. It prevents a parent task with open subtasks from being closed and a subtask of a closed issue from being reopened (in the same way as blocked issues were currently handled). It also prevents an open issue to be set as a subtask of a closed parent issue.
Updated by Jean-Philippe Lang over 9 years ago
I took some internal feedback and the new proposal is "You cannot close an issue with open subtasks."
I chose to use "An open issue cannot be attached to a closed parent task" to be consistent with other validation messages (eg. "An issue cannot be linked to one of its subtasks").
Updated by Marius BĂLTEANU over 9 years ago
Thanks for implementing this. The new error message is fine for me.
Updated by Go MAEDA over 8 years ago
- Related to Defect #27974: Issue-state can't set to done if state of one subissue is not set to done added
Updated by Go MAEDA almost 8 years ago
- Related to Feature #27864: Subtasks inherit parent settings during copy added
Updated by Go MAEDA almost 8 years ago
- Related to deleted (Feature #27864: Subtasks inherit parent settings during copy)
Updated by Go MAEDA almost 8 years ago
- Related to Feature #28492: Option not to block closing a parent issue when it has open subtask(s) added
Updated by Go MAEDA about 7 years ago
- Related to Feature #31589: Show warning and the reason when the issue cannot be closed because of open subtasks or blocking open issue(s) added
Updated by Go MAEDA about 7 years ago
- Related to Feature #31321: Option not to block closing a parent issue when its subtask is open added