プロジェクト

全般

プロフィール

Vote #79168

未完了

Issue parents are getting set incorrectly

Admin Redmine さんが約4年前に追加. 約4年前に更新.

ステータス:
New
優先度:
通常
担当者:
-
カテゴリ:
Issues_2
対象バージョン:
-
開始日:
2022/05/09
期日:
進捗率:

0%

予定工数:
category_id:
2
version_id:
0
issue_org_id:
28240
author_id:
305899
assigned_to_id:
0
comments:
6
status_id:
1
tracker_id:
1
plus1:
0
affected_version:
closed_on:
affected_version_id:
102
ステータス-->[New]

説明

It is same as Defect #27066.

When adding and saving a sub issue under a parent issue, the subtask appear under wrong parent.

In our Redmine environment, this occurs pretty often for some root_id issues have over 100 decendent issues.

We recently start running "Issues#rebuild_tree!" once a month at midnight.
But "once a month" is not enough.
"Issues#rebuild_tree!" takes over 5 hours and lockes all issues meanwhile. So running this script every day is not good.

'Issue.rebuild_single_tree!(1)' needs manual operation by redmine admins at daytime.

So preventing "issue parents is wrong(="lft" and "rgt" values of issues become wrong.)" from happening would be much better.

Environment

  • Redmine 3.2
  • Rails 4
  • Ruby 2.3
  • Issue number:about 400000

journals

--------------------------------------------------------------------------------

--------------------------------------------------------------------------------

--------------------------------------------------------------------------------
Tomoko Shimizu wrote:
> * Redmine 3.2

I'd first suggest to update to the current release branch, 3.4.x. As Toshi and Randa both pointed out in #27066, recent release might have changed things in order to fix/mitigate the issue.

Additionally, are you using any plugins? See [[submissions]] and message#667 for some pointers.

--------------------------------------------------------------------------------
Affected version is 3.3.0 (not 3.2), sorry I was wrong.

Environment:
Redmine version 3.3.0.stable
Ruby version 2.3.1-p112 (2016-04-26) [x86_64-linux]
Rails version 4.2.6
Environment production
Database adapter Mysql2
SCM:
Subversion 1.8.13
Filesystem
Redmine plugins:
clipboard_image_paste 1.10
notify_custom_users 1.0.2
project_overview 1.2.0
redmine_absolute_dates 0.0.2
redmine_backlogs v1.0.6
redmine_banner 0.1.1
redmine_code_review 0.7.0
redmine_diff_email 0.0.5

--------------------------------------------------------------------------------
Thank you Mischa.
I would version up our Redmine Environment to the latest verion.

I have thought "def update_nested_set_attributes" and "def update_nested_set_attributes_on_parent_change" in "app/models/issue.rb" are related to this defect, and If both defs are done under same DB trunsaction , the defect might be fixed.

The recent change about "def update_nested_set_attributes" and "def update_nested_set_attributes_on_parent_change" is only following one.
Merged rails-5.1 branch (#23630). r16859.

This change looks different purpose.
http://www.redmine.org/projects/redmine/repository/revisions/16859/diff/trunk/app/models/issue.rb

--------------------------------------------------------------------------------


related_issues

relates,Closed,27066,issue parents is wrong

Admin Redmine さんが約4年前に更新

  • カテゴリIssues_2 にセット

他の形式にエクスポート: Atom PDF

いいね!0
いいね!0