Skip to content

Conversation

@wforbes5
Copy link

@wforbes5 wforbes5 commented Sep 26, 2025

This is my first ever attempt at open source contribution, so apologies in advance if I am not following the proper process.

I did not write any automated tests however I did test by uploading around 20-40 games at a time for n64, ps1, and atari.

Workflow Changes

  1. Added a bulk upload icon to all of the platform screens.
  2. Clicking this icon brings user to a new bulk upload endpoint.
  3. Users can drop multiple files into this screen, which will then be matched against the steam grid api, automatically taking the highest quality match.
  4. Added a file name label to the new endpoint so users can see the file name that was uploaded to evaluate if the match is correct.

Backend

  1. Added an auto-match function to the steamgrid api, this was necessary to simplify the workflow.
  2. Added new function process_new_shortcut so this function could be shared by both the single manual upload functionality and bulk upload process.
  3. Implemented context manager interface on the ShortcutsFile object that locks the thread and file to prevent bad writes to this file.
  4. Utilized this interface this in the process_new_shortcut function.

@wforbes5 wforbes5 changed the title This PR implements the bulk adding feature requested in #223 Implemented the bulk add feature requested in #223 Sep 26, 2025
@NeroReflex
Copy link
Contributor

Thanks! I defer to @alkazar since I can't understand python

@alkazar
Copy link
Member

alkazar commented Sep 26, 2025

That is some awesome work. My main concern is overloading the SteamGridDB API limits. We have already had our API token revoked once due to overuse and it is very disruptive.

In order for this to be deployed we would have to create and run some kind of proxy server to SteamGridDB.

@wforbes5
Copy link
Author

wforbes5 commented Sep 26, 2025 via email

@wforbes5 wforbes5 force-pushed the 223_Bulk_rom_adding branch from f93da5c to 570049e Compare October 20, 2025 01:37
@wforbes5
Copy link
Author

wforbes5 commented Oct 20, 2025

I added a quick change to the change per our discussion @alkazar. I added in functionality that prevents the bulk upload functionality unless the user has added their own personal API key via the settings section. This should prevent the risk of rate limiting based on the current chimera api key.

@NeroReflex
Copy link
Contributor

Thanks! I hope alkazar will find it amusing as I do.

@wforbes5
Copy link
Author

Thanks! I hope alkazar will find it amusing as I do.

It’s my first ever attempt at contributing to open source. I hope I screw something up to warrant the humor.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants