Open mefaba opened 2 years ago
Revisiting this, I agree that we definitely shouldn't call the GFN API on every load for every user. That's just a bad practice in general, and it would create a lot of instability for the end-user (if they ever get rate-limited or whatever). In fact, the other extension (Cloud Gaming Lister) suffers from that problem frequently for me, which is how I found yours!
It's a good idea to bundle the games list with the extension, especially now that it's just a small array of IDs.
I think we might be able to use a Github Action on a schedule to check it regularly (at least once a day), fetching the latest IDs, doing a sanity check (making sure there wasn't an error, the number of games hasn't increased or decreased drastically, etc.), and then making a commit and PR for it for us to review.
There probably isn't a need to do something more real-time than that because the GFN games list doesn't change all that often to begin with. They usually publish games in batches on every GFN Thursday. Once in a while they will also add games out-of-cycle, like they did midweek with Starfield. But if we check once a day (or like once an hour, still very reasonable) we should catch those.
What do you think?
We are currently getting geforce now game data staticly inside code. We should not do that. Instead we should implement API call or simple websitet scraping. 1)Look up if geforce now is providing game list through API If NOT: 2)Web Scrape Geforce Now Game List page when user enters steam website