-
Notifications
You must be signed in to change notification settings - Fork 94
fix reload failures on active/incomplete orphans #6817
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
base: 8.4.x
Are you sure you want to change the base?
fix reload failures on active/incomplete orphans #6817
Conversation
e1b725c
to
6e14ae8
Compare
@@ -0,0 +1 @@ | |||
Fixes reload failures about orphaned tasks. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Cryptic IMO
Fixes reload failures about orphaned tasks. | |
Fixes a bug where reload removed information about orphaned tasks from the data store. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Even simpler:
Fixes reload failures about orphaned tasks. | |
Fixes a couple of rare scheduler crashes. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
IMO we should at least hint at what triggers the bug. How about this?
Fixes reload failures about orphaned tasks. | |
Fixes two rare bugs associated with reloading the workflow configuration | |
after removing tasks or xtriggers from it. |
start, | ||
log_filter, | ||
): | ||
"""Reload should not fail about orphaned tasks. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
"""Reload should not fail about orphaned tasks. | |
"""Reload should not remove orphaned task data. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The bug was not data being removed, it was the scheduler crashing
- Removal of both xtrigger and associated active/incomplete task. | ||
- Broadcast deltas generated after reload. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Check that I have the issue mapping the right way around!
- Removal of both xtrigger and associated active/incomplete task. | |
- Broadcast deltas generated after reload. | |
- Removal of both xtrigger and associated active/incomplete task. | |
https://github.com/cylc/cylc-flow/issues/6814 | |
- Broadcast deltas generated after reload. | |
https://github.com/cylc/cylc-flow/issues/6815 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think it's the other way round
'scheduler': { | ||
'allow implicit tasks': True | ||
}, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Not required: The fixture adds this as a default. 😄
'scheduler': { | |
'allow implicit tasks': True | |
}, |
'scheduler': { | ||
'allow implicit tasks': True | ||
}, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
'scheduler': { | |
'allow implicit tasks': True | |
}, |
@@ -0,0 +1 @@ | |||
Fixes reload failures about orphaned tasks. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Even simpler:
Fixes reload failures about orphaned tasks. | |
Fixes a couple of rare scheduler crashes. |
- Removal of both xtrigger and associated active/incomplete task. | ||
- Broadcast deltas generated after reload. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think it's the other way round
schd = scheduler(id_) | ||
async with start(schd): | ||
# spawn in bar | ||
foo = schd.pool.get_tasks()[0] |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
foo = schd.pool.get_tasks()[0] | |
foo = schd.pool._get_task_by_id('20010101T0000Z/foo') |
bar = schd.pool.get_tasks()[0] | ||
assert bar.identity == '20010101T0000Z/bar' |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
bar = schd.pool.get_tasks()[0] | |
assert bar.identity == '20010101T0000Z/bar' | |
bar = schd.pool._get_task_by_id('20010101T0000Z/bar') |
schd.pool.task_events_mgr.process_message( | ||
foo, '20010101T0000Z', 'succeeded') |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The 2nd arg is severity, not cycle point
schd.pool.task_events_mgr.process_message( | |
foo, '20010101T0000Z', 'succeeded') | |
schd.pool.task_events_mgr.process_message(foo, 'INFO', 'succeeded') |
schd.pool.task_events_mgr.process_message( | ||
bar, '20010101T0000Z', 'failed') |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
schd.pool.task_events_mgr.process_message( | |
bar, '20010101T0000Z', 'failed') | |
schd.pool.task_events_mgr.process_message(bar, 'INFO', 'failed') |
): | ||
"""Reload should not fail about orphaned tasks. | ||
|
||
The following aspects of reload about orphans are tested: |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Can "reload about orphans" be rephrased more clearly? "reload after removing tasks from the workflow config" maybe?
closes #6814
closes #6815
Note - A good way to see the bugs is to comment out a fix and run the test for each.
Check List
CONTRIBUTING.md
and added my name as a Code Contributor.setup.cfg
(andconda-environment.yml
if present).?.?.x
branch.