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

Gantt chart view - choose timezone #1917

Open
ColemanTom opened this issue Aug 29, 2024 · 6 comments
Open

Gantt chart view - choose timezone #1917

ColemanTom opened this issue Aug 29, 2024 · 6 comments
Assignees
Labels
data workflows team Work pertaining to the analysis/gantt/etc views
Milestone

Comments

@ColemanTom
Copy link

Problem

I was looking at the Gantt view to see timings and was getting confused because the time along the x-axis was local time. I was expecting UTC because that is what I was wanting - workflow is triggered/runs using UTC, so analysis of it I tend to do in UTC.

Proposed Solution

Provide the ability to choose timezone, or at least a switch to allow changing between Local and UTC. Or perhaps, have both visible along the x-axis.

Also, the x-axis should not just say Time, it should be Time (tz) where tz is the display timezone.

@MetRonnie MetRonnie added the data workflows team Work pertaining to the analysis/gantt/etc views label Aug 29, 2024
@MetRonnie MetRonnie added this to the Pending milestone Aug 29, 2024
@ChrisPaulBennett
Copy link
Contributor

Ah, yes. Slight oversight on my part. I'm currently swamped at the moment. If someone else wants to deal this, you are very welcome to. Other wise I'll try and fit this in

@ChrisPaulBennett
Copy link
Contributor

I've had a look at this and none of my code is altering the time. I get the time values from a GraphQL query, which gives me the time in Zulu time (I'm assuming that's what the z means). Zulu time is the same as UTC.
The x-axis is auto-generated by chart library (I will guess the scale from the max and min times in the data). So the x-axis will always match the data.

Can you try the same GraphQL commands as shown below.

Are you sure that you are getting local time?
If you definitely are, I think it might be graphQL giving you time based on your time zone

image

@ColemanTom
Copy link
Author

Are you sure that you are getting local time?

Definitely. I just ran a suite, Gantt chart is sowint 905am instead of 2305UTC

If you definitely are, I think it might be graphQL giving you time based on your time zone

When I run your query, it returns the results in UTC time, not local time.

image

JS frontend perhaps?

@ChrisPaulBennett ChrisPaulBennett self-assigned this Sep 24, 2024
@ChrisPaulBennett
Copy link
Contributor

ChrisPaulBennett commented Sep 24, 2024

Curious. I'll have another look.
Can you show me what you see on the chart? Is it showing you local time?
My time and UTC time is the same for me. So it's difficult for me to see if the time has been altered to local time.

@ChrisPaulBennett
Copy link
Contributor

The JavaScript functions that get time all convert to local time by default (Which should have been obvious to me).
x-axis strings are now UTC
#1946

@MetRonnie
Copy link
Member

To summarise what is left to do:

  • (cylc-flow) expose UTC mode via the GraphQL schema so it can automatically be chosen by the Gantt view
  • Dropdown to choose between local time or UTC?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
data workflows team Work pertaining to the analysis/gantt/etc views
Projects
None yet
Development

No branches or pull requests

3 participants