cylc / cylc-ui

Web app for monitoring and controlling Cylc workflows
https://cylc.github.io
GNU General Public License v3.0
37 stars 27 forks source link

tree: tree view differs from table view #1322

Closed oliver-sanders closed 1 year ago

oliver-sanders commented 1 year ago

We have received multiple reports of discrepancies between the tree and table views.

In the most recent report a task was showing in tree view as submitted, but in the table view as succeeded (correct).

In all cases the table view was showing the correct data so this would appear to be a tree-view bug. It has not yet been confirmed whether the graph view matches the tree or table but I suspect it will match the table.

The tree view follows the "node.familyTree" down to the task whereas table/graph views are not interested in this information so use "node.children". So this is likely related to inheritance. We had a previous bug where task ancestors were coming out in an unstable order, this may be similar.

To debug suggest:

oliver-sanders commented 1 year ago

Have managed to replicate this issue with the following workflow:

[task parameters]                                              
    x = 1..2                                                   

[scheduling]                                                   
    [[graph]]                                                  
        R1 = """                                               
            a<x> => b<x> => c<x>                                                                                                   
        """                                                    

[runtime]                                                      
    [[A,B,C]]                                  
    [[a<x>]]                                                   
        inherit = A                                            
    [[b<x>]]                                                   
        inherit = B                                            
    [[b<x=1>]]                                                 
        script = false                                         
    [[c<x>]]                                                   
        inherit = C                                            

Screenshot from 2023-06-16 15-46-16

Note the two tasks which are lacking jobs which appear in the tree view. These do not appear in the table or graph views nor Tui.

oliver-sanders commented 1 year ago

The UI data-store is expecting the list of childTasks received in delta-updates to always be complete. It's possible that the cylc-flow data store is only listing the updated children in each update which could be causing this.

The UI data store relied on this field, both for adding tasks to families in the familyTree and also for removing them. I think we could rely on the pruned delta for the removals which would bypass this problem if true.