-
Notifications
You must be signed in to change notification settings - Fork 27
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
Gantt: Display x-axis in UTC #1946
Conversation
Sorry I'm late to the party on this issue. This PR clearly works as advertised, but we probably need to use the appropriate time zone for the workflow, not just assume UTC. If you're not running NWP or climate science workflows the local timezone is probably preferred, and I don't think you'll want to see analysis view time axes in UTC. [scheduler]
UTC mode = False # scheduler log timestamps, defaults to local time via global config
cycle point time zone = +1300 # cycle point time zone, defaults to UTC
[scheduling]
initial cycle point = now
[[graph]]
P1D = "foo"
[runtime]
[[foo]]
script = "sleep $(( RANDOM % 10 ))" For the gantt view time axis, it should be determined by |
I imagine it would be useful to be able to choose the timezone from a dropdown (either workflow cycle point time zone, UTC, or local). The cycle point time zone for the workflow can be got by adding this to the query: query ganttQuery ($workflows: [ID]) {
+ workflows(ids: $workflows) {
+ timeZoneInfo {
+ hours
+ minutes
+ stringExtended // if needed
+ }
+ }
jobs(live: false, workflows: $workflows) {
${jobFields.join('\n')}
}
} N.B. the UTC mode setting is not exposed in the GraphQL schema at the moment |
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.
Tested as working.
It would be good to change the x-axis label to "Time (UTC)" to make this clear.
Hmmm yeah you're right. That's a problem, because cycle point time zone is not what we need for the gantt time axis - which applies even for integer cycling. If you set scheduler I guess for now we can just hardwire UTC - because most of our users do NWP and climate workflows - and post an issue to fix it in the future. |
Title has been changed. |
This pull request fixes this issue
#1917
Check List
CONTRIBUTING.md
and added my name as a Code Contributor.setup.cfg
(andconda-environment.yml
if present).?.?.x
branch.