W
Windmill•13mo ago
zsnmwy

Is it possible to display only the first

Is it possible to display only the first element of the array? I only need the object schema.
30 Replies
Sindre
Sindre•13mo ago
Yeah, in general when the data is to big to view, it would be very useful to display something, like first 5 or last 5. because you want to do a sanity check on what you are doing. (see that it is as you expect, or use the schema in the next step etc.
rubenf
rubenf•13mo ago
Just to be sure, would it be sufficient to have a button (display 1) next to the + button that would expand 100 ?
zsnmwy
zsnmwy•13mo ago
Maybe not need the button to expand to 100. That may make the page crash or slow. Display 1 and the schema when the object has a huge array. Generally speaking, the schema is consistent when I work with large amounts of data.
No description
zsnmwy
zsnmwy•13mo ago
My PC memory is 32GB. The page still crashes.
rubenf
rubenf•13mo ago
Yes i think it's displaying them. Just to be sure, the page crash when you expand the array specifically right ?
zsnmwy
zsnmwy•13mo ago
To be exact, after I clicked the Test Flow button several times, the page became stuck until it finally crashed. I don't think the component instances that display JSON are being cleaned up promptly. I use for loops. Each loop fetches a huge JSON data.
rubenf
rubenf•13mo ago
Is there a way you could reproduce the error with a dummy flow and dummy huge JSON? It will be hard to solve otherwise
zsnmwy
zsnmwy•13mo ago
This is the last line of the JSON file. 48765 😂 I downloaded it back from the page with the processing results.
No description
zsnmwy
zsnmwy•13mo ago
That is just one loop. Let me think about it. 🤔
zsnmwy
zsnmwy•13mo ago
@rubenf Load the flow and test it.
zsnmwy
zsnmwy•13mo ago
1. Load The Flow. 2. Click the Test Flow Button. 3. Page slow. 🤯 4. Click twice and more. 5. Page Crash. 💥
rubenf
rubenf•13mo ago
Thanks!
zsnmwy
zsnmwy•13mo ago
How's the progress going? Any updates? This is more important to me now. I hard to dev because the page always crashed. 😂
rubenf
rubenf•13mo ago
Today I'm away from my laptop unfortunately But will get to it first thing tomorrow I'm in sf doing sales 🙂 your flow is working fine on firefox
zsnmwy
zsnmwy•13mo ago
I use Chrome. I have a try in Firefox.
rubenf
rubenf•13mo ago
I've been doing some improvements will release soon
zsnmwy
zsnmwy•13mo ago
Thanks The flow working fine on Firefox Developer Edition. I test the flow on Google Chrome Canary. The problem remains.
rubenf
rubenf•13mo ago
just committed some improvements for flows
zsnmwy
zsnmwy•13mo ago
I will have a test when the image is complete. But Firefox is so smooth. I upgraded to 1.108.1. But it's not helpful for Chrome. Now I change to use Firefox. 😂
rubenf
rubenf•13mo ago
I'm unable to reproduce under chrome @zsnmwy with the flow above I even made the list 10 elems long but no crash
zsnmwy
zsnmwy•13mo ago
😂 Now I use Firefox.
rubenf
rubenf•13mo ago
could you confirm that running the flow above under chrome crash when doing test flow ? When does it do it in particular ? At the end of the for loop ?
zsnmwy
zsnmwy•13mo ago
The page freezes when it tries to handle huge JSON data and begins rendering. After about 10 seconds, the page recovers, but it becomes too slow. If I click the test flow button again, about three times, the page will freeze until Chrome thinks it's not working and kills it. I feel like the entire UI rendering process is being blocked, and it cannot render properly.
zsnmwy
zsnmwy•13mo ago
No description
zsnmwy
zsnmwy•13mo ago
I export the page performance data. You can import to Chrome.
No description
rubenf
rubenf•13mo ago
Thanks, will try to reproduce on my own chrome with the flow and figure out what's up
zsnmwy
zsnmwy•13mo ago
I think the performance profile is better than a few sentences to describe. I hope it can help you to analyze the problem. Don't forget to unzip it first. 😂
rubenf
rubenf•13mo ago
rendering should be improved quite a bit in last version
zsnmwy
zsnmwy•13mo ago
Better than before. But the page still easy to freezes in Chrome. Firefox has better performance.