Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Define order of task groups in new task-group page #581

Open
tcompa opened this issue Oct 9, 2024 · 5 comments
Open

Define order of task groups in new task-group page #581

tcompa opened this issue Oct 9, 2024 · 5 comments
Labels
to be discussed Not ready to implement

Comments

@tcompa
Copy link
Collaborator

tcompa commented Oct 9, 2024

The first structure of this new page (that replaces the current "Tasks" page) is defined in #579.
A specific question concerns the organization of the different task groups (which will be already aggregated in terms of their pkg_name).

The data we start from is a list of task groups which (among others) have these attributes:

    pkg_name: str
    user_id: int
    user_group_id: Optional[int] = None
    user_group_name: Optional[str]   # to be computed in fractal-web based on `user_group_id`
    origin: Literal["pypi", "wheel-file", "other"]
    version: Optional[str] = None
    active: bool
    timestamp_created: datetime
  1. How many tables should we show? Options:
    • (A) All task groups are in a single table
    • (B) We split task groups into two tables, e.g. "my task groups" (the ones with my own user_id) and "other people task groups (the ones to which I have access due their usergroup).
    • ... other?
  2. How are task groups sorted? This is especially relevant if we opt for a single table, and then use order to show the "most interesting" tasks first.
    • The naive option, especially valid for the two-tables option above, is to have alphabetical order by pkg_name.
    • Another option is by group_name, and then pkg_name.
    • ... other?

Note: this issue does not concern disambiguation rules for when the same task exists in multiple copies (one created by me, one created by userX and assigned to group All, ...). For the moment we are showing the whole list of task groups, without disambiguation logic.

@jluethi
Copy link
Collaborator

jluethi commented Oct 9, 2024

which will be already aggregated in terms of their pkg_name

= If we have 10 versions of fractal-tasks-core installed, we still just see it once, right?

Re ordering: If we think of this as a table, can we make it user reordable by different columns? e.g. reorder by version, by pkg_name, by timestamp_created, etc?
The question to me would become: How do we go from package list to seeing individual tasks? Just a modal within each like info? [this hides the tasks quite a bit, but that may be fine on that page] Or an "expand package => task list shows up in the table"? [not sure how feasible]

I think we need to start with a basic version of this and iterate a bit. Or we mock desired outcomes. For the task list, I'm not as picky as for the task addition in workflows, so fine if we slowly iterate on this

@jluethi
Copy link
Collaborator

jluethi commented Oct 9, 2024

High-level: Let's start with a basic single list, ordered by package name. And then iterate further.

Maybe we want different tables, but could also imagine reorderable tables, searchable tables or something else

@tcompa
Copy link
Collaborator Author

tcompa commented Oct 9, 2024

If we have 10 versions of fractal-tasks-core installed, we still just see it once, right?

That's correct: they should all appear as a single collapsed item.

Re ordering: If we think of this as a table, can we make it user by different columns? e.g. reorder by version, by pkg_name, by timestamp_created, etc?
The question to me would become: How do we go from package list to seeing individual tasks? Just a modal within each like info? [this hides the tasks quite a bit, but that may be fine on that page] Or an "expand package => task list shows up in the table"? [not sure how feasible]'

Our first plan is the following. Let's say that we have collected several versions of two packages, and then we also have added a single task and performed a custom task collection.
First view:

fractal-tasks-core (3 versions available, pre-selected version v1.3.0, number of tasks = 10)
faim-hcs (1 version only, number of tasks: 4)
plant-seg-custom-collection (1 version, number of tasks: 6) 
my-custom-task (1 version only, number of tasks: 1)

The different items expose different UI

  • All the ones that have a single version (my-custom-task, plant-seg-custom-collection and faim-hcs) expose a single option, which is a "expand task list" button (it may be + or something similar). When clicked, this expands a nested table which shows all tasks of that task group.
  • For task groups with more than one version (e.g. fractal-tasks-core above), you can
    • select version (the "latest" is preselected, but I can pick another one)
    • for a given version, expand the task list (as above)

If the nested task-list table is too heavy, we can iterate on this and possibly move to a modal - but that it is not our first option (although it would be simpler to implement).

@tcompa
Copy link
Collaborator Author

tcompa commented Oct 9, 2024

reorder by version, by pkg_name, by timestamp_created, etc?

Ordering by pkg_name is well defined.

Ordering by timestamp_created: how would it work? Each collapsed item may include several versions, created at different times. Do we only consider the timestamp of the latest-created version?

@tcompa tcompa changed the title [fractal-server v2.7] Define order of task groups in new task-group page Define order of task groups in new task-group page Oct 11, 2024
@jluethi
Copy link
Collaborator

jluethi commented Oct 11, 2024

If the nested task-list table is too heavy, we can iterate on this and possibly move to a modal - but that it is not our first option (although it would be simpler to implement).

Sounds like a great first thing to implement!

@tcompa tcompa added to be discussed Not ready to implement and removed fractal-server-v2.7 labels Oct 18, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
to be discussed Not ready to implement
Projects
Development

No branches or pull requests

2 participants