Page MenuHomePhabricator

move_project script does not check if task is in both future parent and future subproject and does not remove future parent project
Open, LowestPublic

Description

Followup from T221112:

In T195855#5190491, the command created data inconsistency.

For example, T57111 was in both #Pywikibot-other-scripts and #pywikibot-solve-disambiguation.py or T57020 was in both #Pywikibot-other-scripts and #pywikibot-weblinkchecker.py. The script does not check if a task is in both the future parent and the future subproject, to remove the future parent project when turning a project into a subproject.
Affected tasks were: https://phabricator.wikimedia.org/maniphest/?ids=104952,105581,57111,57020,167709,85334,117176,57048

A task cannot be in both a parent project and a subproject of the same parent project, so tasks like https://phabricator.wikimedia.org/T85334 have invalid associated project data now.

I think there's currently nothing else left for me here? :)

Event Timeline

mmodell added a subscriber: mmodell.Jun 1 2019, 3:01 PM

This is unfortunately sort of expected due to the nature of moving projects around. How would you propose to resolve it?

Aklapper updated the task description. (Show Details)Jun 2 2019, 12:14 PM
Aklapper triaged this task as Lowest priority.EditedJun 2 2019, 12:27 PM

Not sure if it's worth to resolve, could end up as declined. Filed this more for the sake of potentially documenting this issue, and as it creates a DB inconsistency.

Would probably require adding a query to https://phabricator.wikimedia.org/source/phabricator/browse/wmf%252Fstable/scripts/move_beneath.php for all tasks both associated to the project to be converted to a subtasks && associated to the project to become the new parent.
Could print a warning only, or offer to remove that new parent project before running the conversion, or such.

Aklapper updated the task description. (Show Details)Aug 9 2019, 5:27 PM
Urbanecm removed the point value for this task.Aug 31 2019, 11:27 PM