You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Timestamp '1970/01/01 00:00:00' formats as 'undefined' in hovertext #6751
I am happy to try and fix this issue myself but could benefit from someone pointing me in the right direction. I presume that the issue is caused by something like "0 seconds since epoch" is wrongly resolved as falsey at some point.
Thanks @archmoj for the pointers! I have now created PR #6752.
In addition to your suggestion, I had to add another change which prevents the function from trailing stripping zeroes when they were not added because of 'extraPrecision'.
Activity
archmoj commentedon Oct 18, 2023
Nice find 🥇
After long investigation,
it looks like the bug is coming from this block:
plotly.js/src/plots/cartesian/axes.js
Lines 1770 to 1779 in 630b092
Perhaps we should modify the first if statement to be something like:
I am looking forward to reviewing your pull request.
FYI - Our contributing information is at https://github.com/plotly/plotly.js/blob/master/CONTRIBUTING.md
Fix issue 6751: epoch date formats '%H:%M:%S' as 'undefined'
Fix issue 6751: epoch date formats '%H:%M:%S' as 'undefined'
adamjhawley commentedon Oct 18, 2023
Thanks @archmoj for the pointers! I have now created PR #6752.
In addition to your suggestion, I had to add another change which prevents the function from trailing stripping zeroes when they were not added because of 'extraPrecision'.
Add a test to for custom hover format of epoch timestamp
Add a test to for custom hover format of epoch timestamp
Add a test to for custom hover format of epoch timestamp
Add a test to for custom hover format of epoch timestamp