Commit Graph

1601 Commits

Author SHA1 Message Date
Georges-Antoine Assi
3fcce6606c complete updating the endpoints and models 2024-12-20 22:41:56 -05:00
Georges-Antoine Assi
0850c0cbcf migration to create and move to rom_file 2024-12-20 18:09:31 -05:00
Georges-Antoine Assi
e1ef8225c3 Create migration for new romfile 2024-12-20 10:42:53 -05:00
Georges-Antoine Assi
49c50ad810 Move hash calc for roms to bacakground task 2024-12-19 22:21:51 -05:00
Georges-Antoine Assi
37db255328 refactor oidc handler and fix tests 2024-12-18 10:49:45 -05:00
Georges-Antoine Assi
1a9735645e Merge branch 'master' into openid-connect 2024-12-18 00:17:40 -05:00
Michael Manganiello
3eb9d902d6 misc: Remove print leftover in CallbackIO class 2024-12-16 22:50:28 -03:00
Michael Manganiello
099f6e6fe2 misc: Remove unneeded Redis key for Twitch token expiration
The key `romm:twitch_token_expires_at` is not needed, as we already
set an expiration time for the token key itself. If the token is still
present in Redis, it is valid. If not, it means we either never fetched
it, or it was too close to expiration.

With this change, fetching the Twitch token makes a single Redis call
instead of two.
2024-12-13 14:33:56 -03:00
Michael Manganiello
f78611e8bb Merge pull request #1359 from rommapp/misc/sort-roms-at-handler
misc: Sort roms in get_roms method
2024-12-13 14:29:01 -03:00
Georges-Antoine Assi
34d49e6494 changes from self review 2024-12-13 11:33:39 -05:00
Georges-Antoine Assi
1ca4d894dd Merge branch 'master' into openid-connect 2024-12-13 11:24:04 -05:00
Michael Manganiello
bcaecbd311 misc: Sort roms in get_roms method
The `get_roms` method is used during scanning and to generate feeds.
Sorting by filename is not perfect (e.g. prefixes like "The" or "A"),
but should be good enough for users to better visualize how the scanning
process is going, and how close it's to finish.
2024-12-13 10:01:49 -03:00
Michael Manganiello
09c32f2376 misc: Use async cache in IGDB handler
One of the only places we are still using the sync cache, can be easily
changed to use the async one.
2024-12-13 09:21:47 -03:00
Georges-Antoine Assi
2d5bc34e9c add tests for oidc handler 2024-12-12 17:37:30 -05:00
Georges-Antoine Assi
776d3c6547 fix user endpoint tests 2024-12-12 16:17:54 -05:00
Georges-Antoine Assi
fa1eceed7a [HOTFIX] Lower permission on update user endpoint and check perms internally 2024-12-12 10:47:27 -05:00
Georges-Antoine Assi
e953398cab add email to user create 2024-12-12 10:43:45 -05:00
Georges-Antoine Assi
82ac766c9e oidc login using email 2024-12-12 10:08:27 -05:00
Georges-Antoine Assi
bb43767249 Merge branch 'master' into openid-connect 2024-12-11 23:20:40 -05:00
Georges-Antoine Assi
0e2866f0f5 dont setup OIDC if disabled 2024-12-11 23:20:21 -05:00
Georges-Antoine Assi
cae4089ccf add email field 2024-12-09 19:57:13 -05:00
Georges-Antoine Assi
2cd9041e85 Merge branch 'master' into openid-connect 2024-12-09 19:25:44 -05:00
Georges-Antoine Assi
d172f2f3ef hotfix some sqlalchemy models 2024-12-09 19:21:00 -05:00
Georges-Antoine Assi
60283c31b0 single log entry 2024-12-09 09:54:01 -05:00
Georges-Antoine Assi
b3366728a6 fix when user is not authenticasted 2024-12-08 23:07:43 -05:00
Georges-Antoine Assi
613b581700 [ROMM-1348] Log when a user downloads a game 2024-12-08 21:40:41 -05:00
Georges-Antoine Assi
b7dac4743a Merge branch 'master' into openid-connect 2024-12-07 22:19:24 -05:00
Michael Manganiello
743ecd83e7 misc: Fix some typing issues 2024-12-07 12:29:45 -03:00
zurdi
c6039ccff4 fix: correct filter condition for retrieving collections associated with a ROM ID 2024-12-05 16:16:34 +00:00
zurdi
014427e69f fix: update ROM deletion process to remove associated collections and streamline user data updates 2024-12-05 16:08:45 +00:00
zurdi
eae8d34d8f fix: convert zlib error to string for better logging in ROM hash calculation 2024-12-04 00:10:44 +00:00
zurdi
7614df07b1 fix: handle zlib error when calculating ROM hashes for corrupted files 2024-12-04 00:06:06 +00:00
Zurdi
a6ff9baf80 Merge pull request #1324 from rommapp/feature/add-platform-info
feat: Add platform info drawer + per platform settings
2024-12-03 19:01:16 +01:00
zurdi
5eefdda9d8 refactor aspect_ratio field to use string type and update related components 2024-12-03 10:51:29 +00:00
Zurdi
5b39127a02 Merge pull request #1323 from rommapp/fix/check-user-on-middleware
fix: Crash on new instance from previous installation
2024-12-03 00:25:42 +01:00
Zurdi
219145e000 Update middleware based on review 2024-12-02 18:56:58 +01:00
zurdi
caa24433b1 refactor: improve user authentication handling without requesting to database 2024-12-02 15:37:13 +00:00
zurdi
44afc718a6 refactor: check user existence only for /api/heartbeat endpoint 2024-12-02 15:09:36 +00:00
zurdi
52ccd1c727 fixes based on unit testing 2024-12-02 11:20:40 +00:00
zurdi
b545d12731 improved aspect ratio set in gamecard 2024-12-02 11:03:01 +00:00
Michael Manganiello
0a4c81d5c1 misc: Retrieve roms by filename from database in bulk during scan
The scanning process could try to fetch thousands of roms from the
database, one by one, which is very inefficient, especially when only a
few new roms are added to the library, as the overhead of database calls
is very high compared to metadata API calls.

This change introduces a new method in the roms handler to retrieve roms
by their file names in bulk, which is used during the scan process to
fetch a batch of roms at once, instead of one by one.

It also avoids the `@with_details` decorator when fetching roms during
the scanning process, as those details are not needed, and they were
adding unnecessary joins and data decoding.
2024-12-02 00:00:47 -03:00
zurdi
ec41d72a8f set gameCard aspect ratio based on platform 2024-12-01 23:51:46 +00:00
Michael Manganiello
00f75841f8 fix: Speed up scan for matched roms without filesystem changes
When the scanning process fiends that a rom should not be scanned, it
was still updating the rom data in the database.

This database update is only needed when the existing data is different
to the newly found filesystem data, so we can avoid most of the updates
for already existing library roms.
2024-12-01 17:35:46 -03:00
zurdi
b670b68df3 added default aspect ratio in platform table 2024-12-01 18:22:27 +00:00
zurdi
6771956846 fixed platform fields in response 2024-11-30 17:51:00 +00:00
Georges-Antoine Assi
f2f8956ad4 more cleanup of unneded oauth code 2024-11-29 09:26:03 -05:00
zurdi
2bed0a8b23 removed unnecessary config variables from config endpoint 2024-11-28 16:34:00 +00:00
zurdi
c661a98347 removed unnecessary structure path value to the front 2024-11-28 16:24:44 +00:00
zurdi
6a7433e1f9 removed unnecessary video endpoint request 2024-11-28 16:12:05 +00:00
zurdi
cb5d2438d2 Merge remote-tracking branch 'origin/master' into feature/add-platform-info 2024-11-28 15:23:32 +00:00