openclimatefix / quartz-frontend

Front End repo for the Nowcasting project.
https://openclimatefix.org/projects/nowcasting/
MIT License
100 stars 16 forks source link

change api call for gsp chart to call one gsp #393

Closed rachel-labri-tipton closed 1 year ago

rachel-labri-tipton commented 1 year ago

Pull Request

Description

Update to the GSP remix chart code to query one gsp for the chart data

Fixes #392

How Has This Been Tested?

The code has been run locally using v1.4.8 of the API.

Checklist:

vercel[bot] commented 1 year ago

The latest updates on your projects. Learn more about Vercel for Git ↗︎

Name Status Preview Comments Updated (UTC)
nowcasting-app ✅ Ready (Inspect) Visit Preview 💬 Add feedback Aug 8, 2023 0:38am
nowcasting-website ✅ Ready (Inspect) Visit Preview 💬 Add feedback Aug 8, 2023 0:38am
rachel-labri-tipton commented 1 year ago

hey @braddf, I just tested the production app vs. this branch. production app: 70+ seconds to load this branch: 10-12 seconds I'm hoping this will make a difference.

braddf commented 1 year ago

Great work! I'll take a look shortly - hopefully most of this speed improvement is down to your changes, and not the added stuff between the API versions (1.4.8 on development currently, 1.5.2 on production) 🤞🏻

braddf commented 1 year ago

Happy for this to be merged into development. 👍

Highlights a general issue that the SWR fetcher should be using cached values if they've already been requested, but may do that and re-request a fresh set, on a long query load time (still, this should be cached API side) - I was going to look into this generally this afternoon anyway! 🤞

peterdudfield commented 1 year ago

Perhaps it just me, but I couldnt click on a GSP to get the gsp specific graph up? Maybe this is a bug on my side

braddf commented 1 year ago

@peterdudfield seems okay to me, although it's still slow to load on full strength wifi so possibly will timeout/not load on a dodgy train connection 🥲