Page MenuHomePhabricator

Maniphest `ownerOrdering` column is no longer populating, disrupting "Group By: Assigned"
Closed, ResolvedPublic

Description

We recently upgraded to rP62794e4494e0 from a revision that was at least a couple of months old.

Maniphest is no longer displaying tasks in descending order of priority even when "Order by: Priority" is selected in "Edit Query".

Seems like all the tasks from prior to the upgrade appear in priority order, but new tasks that are assigned to users show up in random places in that user's list of tasks ordered by priority.

I'm not sure if it always happens or only gets triggered in some particular scenario (like creating new task, or editing a task or whatever). In the latest case in our instance, I reassigned a High priority task from me to someone else, and it's appearing below Normal priority tasks in that guy's list. I think it's happening only when tasks are reassigned rather than for tasks that are assigned while being created.

Somewhat relatedly, "Group by: Assigned" combined with "Order by: Priority" now displays the users in random order. Previously the users were in alphabetical order. Don't know if it was a coincidence, but it was certainly very useful.

Event Timeline

adityar7 raised the priority of this task from to Needs Triage.
adityar7 updated the task description. (Show Details)
adityar7 added a project: Maniphest.
adityar7 added a subscriber: adityar7.

Can you find a query on this install which reproduces the issue? I'm having difficulty replicating this.

I can't reproduce it on this install. But then, I can't reproduce it for every task on my install. However, I can reproduce it consistently for certain tasks. Here are some screenshots in which I assign task 968 to user sahil, then to aditya, then to amyth.

http://d.pr/i/zMBa
http://d.pr/i/VjD3
http://d.pr/i/GLgM

The query executed to view the page is http://d.pr/i/Oc5w. Is the query incorrect? It's the same one that always worked before the latest upgrade.

Also, that username not appearing in alphabetical order thing -- every time any task is modified and the page with the above query is refreshed, the order of users changes randomly. It doesn't change if no tasks are modified.

Is this only happening for "Group By: Assigned"?

Quite possibly, yes.

I just tried "Group By: Project, Order By: Priority" and get all the projects in alphabetical order. Unlike the "Assigned" case, the projects with higher priority tasks don't show up before those with lower priority tasks.

Can't really group by anything else since it'll change the semantics of what's displayed.

I think I've identified the issue. After T2217, we stopped updating the denormalized username ordering on tasks. The symptoms I would expect are:

  • This will occur only with "Group By: Assigned".
  • Each list of tasks under an owner will have exactly one or two sub-groups of correctly ordered tasks. For example, it might go "High, Medium, Low, High, Medium Low" (two runs from high to low), but not "High, Low, High, Low, High, Low" (three runs from high to low).

Are these consistent with what you're seeing? It looks like from the screenshots.

Yeah, all our users have two sub-groups, except for "Not Assigned" which has a single one.

Hopefully the random username ordering is related to this as well? That's probably more bothersome than the sub-group issue, since one now has to scroll or use the browser search to find a username (or "Not Assigned").

epriestley renamed this task from Maniphest order by priority is malfunctioning to Maniphest `ownerOrdering` column is no longer populating, disrupting "Group By: Assigned".Nov 18 2013, 4:38 PM
epriestley triaged this task as Normal priority.
epriestley claimed this task.

(D7602 presumably fixed this.)