I created a view in the UI for: - Relative Now +- ...
# prefect-ui
j
I created a view in the UI for: • Relative Now +- 24 hours • saved it as
Plus_Minus_24_Hours
And when I try to switch to it, it won't switch and this is error message I see in Console. It won't let me delete it either I believe.
Copy code
TypeError: e.toISOString is not a function
    at Z0.format (index.js:34:46681)
    at Z0.safeFormatValue (index.js:34:46336)
    at index.js:34:46072
    at Array.map (<anonymous>)
    at Z0.set (index.js:34:46060)
    at aue.set [as _setter] (index.js:34:47311)
    at set value [as value] (index.js:1:11831)
    at aue.set [as _setter] (index.js:71:264877)
    at set value [as value] (index.js:1:11831)
    at oO.set (index.js:1:5845)
Am I doing the view creation incorrectly (like _s break it maybe) ? Thank you 🙏
j
Thanks for reporting. We’ll take a look and see what’s up!
j
Thanks Jenny, appreciate it! Let me know if you need any more details
c
@Jack P thanks for the reproduction steps. I can reproduce and will figure out what's going on here.
PR in our ui-library that should fix the issue you're having (fixes it for me). Will plan to get that merged and released to cloud by end of day. I'll let you know when that's released so you can verify for me that you're no longer seeing this issue.
j
Craig once again, you're the 🐐!! ty sir 🫡 🦜
🐐 1
c
We just did a release. Would you mind letting me know if you're able to use your saved filter mentioned in your original message?
j
Copy code
index.js:1304 TypeError: e.toISOString is not a function
    at V0.format (index.js:34:46683)
    at V0.safeFormatValue (index.js:34:46338)
    at index.js:34:46074
    at Array.map (<anonymous>)
    at V0.set (index.js:34:46062)
    at lO.set [as _setter] (index.js:34:47313)
    at set value [as value] (index.js:1:13566)
    at lO.set [as _setter] (index.js:71:264881)
    at set value [as value] (index.js:1:13566)
    at qD.set (index.js:1:9045)
Still getting this when I click, do I need to log out and log back in
c
Hmm shouldn’t need to. But if you haven’t refreshed the page make sure you do that. And let me double check the fix went out with that release
j
It's working now! Must have been timing, thank you @Craig Harshbarger 🙏 !
🙌 1
c
Awesome, thanks for letting me know!
🦜 1
🚀 1
j
Hey @Craig Harshbarger, I am running into these two messages spamming console when I go from
Flow Runs
to any page and back. It then only lets mean navigate to every page except
Flow Runs
. I am on Google Chrome and had the Prefect default View set as my custom Plus/Minus 24 hours one (
around
and
now
options are used in the filter). Let me know if you need more info/or can't reproduce. I wanted to note too that I did try clearing cookies/cache and still have it occurring. Thank you 🫡
Copy code
<Warning color>
index.js:1304 Error
    at vn (index.js:5:26475)
    at bP (index.js:5:27290)
    at iI (index.js:5:28429)
    at Mpe (index.js:6:38202)
    at dk (index.js:6:38785)
    at ine.kAe (index.js:71:23278)
    at ine.map (index.js:97:66684)
    at ine.r$e (index.js:71:47011)
    at ine.map (index.js:97:66684)
    at r (FlowRunsPageWithDefaultFilter-bcCJASK7.js:1:180)

<Error color>
index.js:1304 RangeError: Invalid time value
    at Date.toISOString (<anonymous>)
    at V0.format (index.js:34:46683)
    at V0.safeFormatValue (index.js:34:46338)
    at index.js:34:46074
    at Array.map (<anonymous>)
    at V0.set (index.js:34:46062)
    at lke (index.js:34:47445)
    at index.js:34:47789
    at Array.forEach (<anonymous>)
    at OA (index.js:34:47728)
Here's custom default filter for reference
c
so you can go to the flow runs page. But then if you go to another page, and then go back to the flow runs page you get these errors? Did you set your custom filter as the default filter?
j
Yes can go initially, then Yes, and Yes to both of those
c
If you don't mind I'd like to set your default filter back to the system default and see if the issue persists. Would you mind removing the local storage item where the default is set? You can do this by running this in the devtools console
localStorage.removeItem('prefect-ui-library-custom-default-flow-runs-filter')
Actually that snippets not quite correct. One second
This should work
localStorage.removeItem('cache-key-4:prefect-ui-library-custom-default-flow-runs-filter')
j
ya sure one sec
After running that command, it still won't let me click "Flow Runs", and as soon as I click it I get spammed with the errors in console
c
when you go to the page for the first time (with a refresh) and the page loads. What does it say your default filter is?
j
c
Okay so the default was reset correctly at least.
When you get an error in the console, are you able to click the source link and see the line that errored? For example the
index.js:34:46681
should be a link and should take you to a source file. If you can open a source file and send me a screenshot that would be helpful. It should highlight the line that is erroring. Including as much context of the file as you can would be helpful.
Copy code
TypeError: e.toISOString is not a function
    at Z0.format (index.js:34:46681)
👀 1
j
Here's error, I'll click and send screenshot of each in a msg one sec
👍 1
V0.format
v0.safeFormatValue
c
hmm interesting
still not sure what's up, but that its helpful context
j
Lemme know if you need the other ones as well, I feel like the only obvious issue would be me cilcking option
now
, but that's me with no idea how it's built lol.
c
now
in the date picker just sets the date to the time that it is currently. Its not live updated. If you want something that is relative to "now" you'd have to use one of the relative time formats like
Past 24 hours
j
Oh my gosh, I am stupid I just realized that haha. Is there a way to get scheduled runs along with past 24, that's what I was triyng to accomplish
c
Not currently. You basically want Past 24 hours AND next 24 hours. Which currently isn't supported. But something we could probably add. Would you mind creating a feature request issue for that? Maybe we can get some traction on that.
j
ya for sure no problem, that'd be awesome feature 😄 , is feature request just issue in repo/and is that the prefect UI library repo?
c
Yep that would be fine, ty!
still poking around trying to figure out whats going on with your flow run page.
j
np! lemme know if you need any other context/info, happy to help 😄
c
When it errors, does it load the flow run page at all? Or does it just get stuck on whatever page you were on
j
just sits on empty dark screen
c
The url updates correct? Then its just a blank screen? Sidebar shows up or no?
j
Now it actually did something different and totally freezed
It was set as deafult to the 24 hour, refreshed page and then those starting sending blank errors
🤔 1
c
Would you mind sending my the account id and workspace id? Or just send me any url from your workspace (the url has the ids)
1