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

incorrect prerequisites after task state changes #2599

Closed
hjoliver opened this issue Mar 10, 2018 · 5 comments
Closed

incorrect prerequisites after task state changes #2599

hjoliver opened this issue Mar 10, 2018 · 5 comments
Assignees
Labels
bug Something is wrong :(
Milestone

Comments

@hjoliver
Copy link
Member

hjoliver commented Mar 10, 2018

Since cylc-6.10.1 [UPDATE: this is where the first part of the problem started; more below]

First revealed here: #2561 (comment)

@hjoliver hjoliver added the bug Something is wrong :( label Mar 10, 2018
@hjoliver hjoliver added this to the soon milestone Mar 10, 2018
@hjoliver
Copy link
Member Author

git bisect says the offending commit is 3b654e9

@hjoliver
Copy link
Member Author

hjoliver commented Mar 10, 2018

Some change in that commit results in prerequisites.set_satisfied() being called when a task is ready to run [UPDATE: oops, see next comment] fails

Revising the title - prerequisite status remains correct unless/until a task fails (the task in my test suite was set to fail immediately).

@hjoliver hjoliver changed the title "cylc show" pre-requisite status listing broken prerequisites set incorrectly on task fail Mar 10, 2018
@hjoliver
Copy link
Member Author

hjoliver commented Mar 10, 2018

The plot thickens. On master, the situation is worse than as described in the previous comment. All prerequisites are set satisfied when the task is ready to run (or thereabouts) ... or are least listed that way by cylc show. I suspect this results from using "forced task state reset" semantics (where it may? be OK to artificially mess with prerequisite status) for normal in-run state changes.

@hjoliver
Copy link
Member Author

hjoliver commented Mar 10, 2018

Test case. Observe baz prerequisites and outputs with watch -n 1 cylc show SUITE baz.1.

[scheduling]
    [[dependencies]]
        graph = FOO:succeed-any & BAR:finish-all => baz
[runtime]
    [[FOO, BAR]]
        pre-script = sleep $(( 10 + RANDOM % 10 ))
    [[foo_1, foo_2, foo_3, foo_4]]
        inherit = FOO
    [[foo_4]]
        script = false
    [[bar_1, bar_2, bar_3, bar_4]]
        inherit = BAR
    [[bar_4]]
        script = false
    [[baz]]
        init-script = sleep 5  # stay 'submitted' for 5 sec

Once baz.1 finishes (leave watch ... running) try manually forcing its state, and retriggering it. Remove one upstream family from the live suite to confirm that prerequisites get unset on reset to 'waiting':

@hjoliver hjoliver changed the title prerequisites set incorrectly on task fail prerequisite statuses set incorrectly after triggering? Mar 10, 2018
@hjoliver hjoliver changed the title prerequisite statuses set incorrectly after triggering? bad prerequisite status reset after triggering? Mar 10, 2018
@hjoliver hjoliver changed the title bad prerequisite status reset after triggering? incorrect prerequisite status after reset Mar 12, 2018
@hjoliver
Copy link
Member Author

New PR to come, after rethinking how to handle outputs and prerequisites properly on state changes.

@hjoliver hjoliver self-assigned this Mar 12, 2018
@hjoliver hjoliver changed the title incorrect prerequisite status after reset incorrect prerequisites after task state changes Mar 12, 2018
@matthewrmshin matthewrmshin modified the milestones: soon, next release Apr 16, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something is wrong :(
Projects
None yet
Development

No branches or pull requests

2 participants