cylc-ui
cylc-ui copied to clipboard
Xtriggers and mode in info view
Requires https://github.com/cylc/cylc-flow/pull/6671
Check List
- [x] I have read
CONTRIBUTING.mdand added my name as a Code Contributor. - [x] Contains logically grouped changes (else tidy your branch by rebase).
- [x] Does not contain off-topic changes (use other PRs for other changes).
- [x] Applied any dependency changes to both
setup.cfg(andconda-environment.ymlif present). - [x] Tests are included (or explain why tests are not needed).
- [x] Changelog entry included if this is a change that can affect users
- [x] Cylc-Doc pull request opened if required at cylc/cylc-doc/pull/XXXX.
- [x] If this is a bug fix, PR should be raised against the relevant
?.?.xbranch.
Broken for this workflow::
#!/bin/bash
TMP=$(mktemp -d)
echo Files extracted to ${TMP}
mkdir -p "${TMP}/."
cat > "${TMP}/./flow.cylc" <<__ICI__
[scheduler]
allow implicit tasks = True
cycle point format = %Y
[scheduling]
initial cycle point = 2026
[[graph]]
R1 = """
@myxt => foo
@echo => foo
"""
[[xtriggers]]
echo = echo('Hello, world!', succeed=False)
myxt = myxt():PT1S
[runtime]
[[foo]]
[[[meta]]]
description = """
Xtriggers dissapear from the gui
to make myxt return true
touch ~/foo.flag
"""__ICI__
mkdir "${TMP}/./lib"
mkdir "${TMP}/./lib/python"
cat > "${TMP}/./lib/python/myxt.py" <<__ICI__
from pathlib import Path
def myxt():
"""Switched by the existance of a file foo.flag in the users home
directory.
"""
if (Path.home() / 'foo.flag').exists():
return True, {}
return False, {}
__ICI__
When one touches the foo.flag file the state of myxt correctly displays as satisfied, but the still unsatisfied echo trigger dissapears.
Note to self - remove the note from cylc doc added in https://github.com/cylc/cylc-doc/pull/816 about info view not showing xtriggers.
PR is ready for review, but only works in combination with https://github.com/cylc/cylc-flow/pull/6671
Checks cancelled because diff is https://github.com/cylc/cylc-ui/compare/077f8cd1ae3363314ac038512e84b079f8bfee10..73a93e22501b5e39032ad35029c8db0f81184004 no change
I get a blank Info view on this branch, I'm afraid (cylc-flow PR checked out, cylc-uiserver at master)
I get a blank Info view on this branch, I'm afraid (cylc-flow PR checked out, cylc-uiserver at master)
Can confirm - I've made a mistake in the graphql - I'll have a poke at some point, but i think some of the reviewing I have is more urgent
Unfortunately, if there is a problem/mistake in a subscription query, we don't seem to be getting any error reporting
Unfortunately, if there is a problem/mistake in a subscription query, we don't seem to be getting any error reporting
My evidence is that I checked out the upstream/master src/views/Info.vue and it all worked fine. This also demonstates that I haven't used the extra data, so it's pointless, and that I hadn't finished something I was doing on branch!
(I've started looking at this one)
(I've started looking at this one)
For context, task filtering based on xtrigger-derived state & task icon badges will follow in future PRs, this one is just about the info view.
Something is going wrong with the trigger time field:
And what's up with the sort order? Why is the latest xtrigger in the middle?
LGTM, small issue with xtrigger sorting and trigger time calculation.
Note, we could just replace the trigger_time field in the xtriggers signature with the ISO8601 value to avoid adding an extra column (that only applies to @clock triggers).
Something is going wrong with the trigger time field:
I've removed seconds. Forgot about retry triggers when I did that. Thought that minutes would be fine.
And what's up with the sort order? Why is the latest xtrigger in the middle?
I've done nothing to sort the items. I imagine accidentally shearing seconds off them won't help. It seems to have sorted itself out in the process of fixing the other issues.
The re-formatted trigger-time field looks great.
The xtriggers are still being displayed in the order the backend provides them in which is unsorted. Not a biggie, but I think it would be good for the info view to sort by label, then signature.
Yes, it's covered in https://github.com/cylc/cylc-flow/issues/6298.
To some extent, https://github.com/cylc/cylc-flow/issues/6810 will help.