Playnite Forums
  • Playnite Web
  • Rules
  • Members
  • Team
  • Search
  • Register
  • Login
  • Home
  • Members
  • Help
  • Search
Playnite Forums Extension Database Metadata Plugins SGDB Metadata Extension

SGDB Metadata Extension
cooperate
Offline

#1
03-14-2020, 07:39 PM (This post was last modified: 11-29-2020, 07:33 PM by cooperate.)
Here is my SteamGridDB metadata extension.

Some notes...
-Supported Types: Covers/Backgrounds/Icons
-While using the background downloader, it is hard coded to fetch the top result on a query to their api for an image based on the criteria you choose in the extension settings.
-You must provide an api key

Future plans
-Proper support for different cover dimensions [complete]
-Hero image support [complete]
-Icon support [complete]
-Manual selection for images when more than one is available [complete]
-Fuzzy Search implementation
-Use app id when available [complete]
-"Style" filter for grid images [complete]

UPDATE:
v0.5.0 released
Addressed extension bug preventing launch.
Only one dialog selection for metadata now.

v0.5.1 released
-Download in background should not fail silently anymore.
-Manual download edge cases fixed for null values.

v0.5.2
-Hotfix for missing arg on MetaDataFile, was breaking certain media downloads.

v0.5.3
-Fallback to fuzzy search if game platform does not exist for background downloads.

v0.5.4
-Replace "Legacy" grid size api enum 660x930

v0.5.5
-Add id to extension metadata for Playnite 8.0 compatibility
-Add exceptions for source and gameID for background downloader

v0.5.6
-Only download by platform from Steam during background downloader

v0.5.7
-Add support for thumbnails in preview window while selecting media

https://github.com/cooperate/SteamGridDB.../tag/0.5.7
sheepbeep
Offline

#2
03-22-2020, 02:39 PM (This post was last modified: 03-22-2020, 02:45 PM by sheepbeep.)
Does not really work.

First, in the extension menu, the icon is oddly shaped and there are two entries (I installed it once).

[Image: bCRUKmi.png]

The options menu only has a single text entry, there I entered my API key and saved.

When I try to download the metadata with the plugin, I get a "service error".

[Image: 5lmoiaY.png]

Playnite is 7.4.

Error message is
2020-03-22 15:36:11.0912|ERROR:Failed to download metadata, aebe8b7c-6dc3-4a66-af31-e7375c6b5e9e, 1207660773System.Exception: Service failure.
   at SGDBMetadata.SGDBMetadataProvider.GetIcon() in U:\App_Dev\SGDBMetadata\SGDBMetadata\SGDBMetadata\SGDBMetadataProvider.cs:line 91
   at Playnite.DesktopApp.ViewModels.GameEditViewModel.<>c__DisplayClass391_0.<DownloadPluginData>b__0() in E:\Devel\Playnite\source\Playnite.DesktopApp\ViewModels\GameEditViewModel.cs:line 2873

Suggestions (aside from making it work):
- make a proper configuration dialog, a blank text line without a description for what it is for is a bit too obscure.
- catch the service error and display what the real response from the API is. If it is 'just' the missing API, offer to enter it.

My guess is that the entered API key in the options is not saved or used, although I have entered it.
Unknow0059
Offline

#3
05-03-2020, 06:02 AM
Where do I place the API key?
yatesl
Offline

#4
05-03-2020, 10:33 PM
(05-03-2020, 06:02 AM)Unknow0059 Wrote: Where do I place the API key?
I'm struggling to find it too. It shows up in Extensions, but no-where else (in any drop downs or otherwise).
darklinkpower
Offline

#5
05-04-2020, 12:49 AM
[Image: XnT2yI0.png]
SeeDborg
Offline

#6
05-04-2020, 08:00 PM
I installed the plugin, I see it activated but I have not "Steam Grid DB Metadata" under "Metadata sources"... Did I do something wrong ?


[Image: aOqDN6h.png]
SirTyler
Offline

#7
05-04-2020, 09:25 PM
It seems to be something they broke in version 0.4, I managed to fix it by using 0.3 and then updating.
Crow
Offline

Administrator
#8
05-06-2020, 08:53 AM
I opened for it, 0.3 also works for me but 0.4 doesn't.

https://github.com/cooperate/SteamGridDB...a/issues/2
cooperate
Offline

#9
05-19-2020, 11:12 PM
(05-04-2020, 09:25 PM)SirTyler Wrote: It seems to be something they broke in version 0.4, I managed to fix it by using 0.3 and then updating.

I'll look into this this week.  Been away from this for a bit.
cooperate
Offline

#10
05-22-2020, 04:59 AM
(05-04-2020, 08:00 PM)SeeDborg Wrote: I installed the plugin, I see it activated but I have not "Steam Grid DB Metadata" under "Metadata sources"... Did I do something wrong ?


[Image: aOqDN6h.png]
Should be resolved now! Smile
stompysan
Offline

#11
05-23-2020, 06:38 PM
(05-22-2020, 04:59 AM)cooperate Wrote: Should be resolved now! Smile

Working flawlessly.  Thanks for the update!
SeeDborg
Offline

#12
05-25-2020, 07:57 PM
Here is a proposition I made on your Git Page : https://github.com/cooperate/SteamGridDB...a/issues/4

Thanks for the wonderful plugin !
hunt363
Offline

#13
06-10-2020, 01:03 PM (This post was last modified: 06-10-2020, 01:04 PM by hunt363.)
I get an error message saying "Failed to download metadata: Service failure" when I try to download metadata    
sheepbeep
Offline

#14
06-10-2020, 03:27 PM
(06-10-2020, 01:03 PM)hunt363 Wrote: I get an error message saying "Failed to download metadata: Service failure" when I try to download metadata
It would help, if you open the playnite.log and post the relevant from there alongside the problem description. Look for SGDB or something similar.

Don't provide the whole log file, as there is some stuff like Steam ID, Steam API key which you don't want to provide publicly.
hunt363
Offline

#15
06-10-2020, 04:03 PM
(06-10-2020, 03:27 PM)sheepbeep Wrote:
(06-10-2020, 01:03 PM)hunt363 Wrote: I get an error message saying "Failed to download metadata: Service failure" when I try to download metadata
It would help, if you open the playnite.log and post the relevant from there alongside the problem description. Look for SGDB or something similar.

Don't provide the whole log file, as there is some stuff like Steam ID, Steam API key which you don't want to provide publicly.
Is this helpful? I tried it again and copied the last log.
2020-06-10 21:28:22.9679|INFO:SGDB Initialized
2020-06-10 21:28:22.9679|INFO:AvailableFields
2020-06-10 21:28:22.9679|INFO:GetAvailableFields
2020-06-10 21:28:22.9679|INFO:GetSgdbMetadata
2020-06-10 21:28:22.9679|INFO:Devil May Cry 4 Special Edition
2020-06-10 21:28:22.9679|INFO:Devil May Cry 4 Special Edition
2020-06-10 21:28:22.9679|INFO:https://www.steamgriddb.com/api/v2/search/autocomplete/Devil May Cry 4 Special Edition
2020-06-10 21:28:23.4021|INFO:{"success":false,"errors":["Invalid API key"]}
2020-06-10 21:28:23.4021|ERROR:Failed to download metadata, cb91dfc9-b977-43bf-8e70-55f46e410fab, 329050System.Exception: Service failure.
   at SGDBMetadata.SgdbServiceClient.getGameListSGDB(String gameTitle) in U:\App_Dev\SGDBMetadata\SGDBMetadata\SGDBMetadata\SGDBService.cs:line 148
   at SGDBMetadata.SGDBMetadataProvider.GetSgdbMetadata() in U:\App_Dev\SGDBMetadata\SGDBMetadata\SGDBMetadata\SGDBMetadataProvider.cs:line 187
   at SGDBMetadata.SGDBMetadataProvider.GetAvailableFields() in U:\App_Dev\SGDBMetadata\SGDBMetadata\SGDBMetadata\SGDBMetadataProvider.cs:line 173
   at SGDBMetadata.SGDBMetadataProvider.get_AvailableFields() in U:\App_Dev\SGDBMetadata\SGDBMetadata\SGDBMetadata\SGDBMetadataProvider.cs:line 26
   at SGDBMetadata.SGDBMetadataProvider.GetIcon() in U:\App_Dev\SGDBMetadata\SGDBMetadata\SGDBMetadata\SGDBMetadataProvider.cs:line 124
   at Playnite.DesktopApp.ViewModels.GameEditViewModel.<>c__DisplayClass391_0.<DownloadPluginData>b__0() in E:\Devel\Playnite\source\Playnite.DesktopApp\ViewModels\GameEditViewModel.cs:line 2873
cooperate
Offline

#16
06-25-2020, 12:29 AM
You're api key is invalid. Are you sure you've set one up through the settings?
hunt363
Offline

#17
06-25-2020, 04:10 PM
(06-25-2020, 12:29 AM)cooperate Wrote: You're api key is invalid.  Are you sure you've set one up through the settings?
Yeah, I have. I've also revoked the key and re-registered several times and it still doesn't work.
Unknow0059
Offline

#18
07-18-2020, 06:47 AM
Thanks. Works like a charm.
CriticalComposer
Offline

#19
07-23-2020, 02:16 AM
Is there a way that the results could show the size of the pictures? Too often I've pulled down a GOG cover or one of the 3800x1800 heroes and I've ended up just going to SGDB anyways to find exactly what I want, especially when there isn't a logo because Steam provides one -- though I understand there isn't much you can do about that one.
sheepbeep
Offline

#20
07-28-2020, 03:17 PM
This should not happen, if there is some basic problem, like not finding the game, the extension should not crash and burn and stopping other metadata extensions to continue searching.



2020-07-28 17:13:14.2918|DEBUG:Downloading metadata for Alien Breed: Tower Assault, 1207663753, aebe8b7c-6dc3-4a66-af31-e7375c6b5e9e
2020-07-28 17:13:14.7981|DEBUG:Downloading string content from http://api.gog.com/products/1207663753?expand=description using cookies and System.Text.UTF8Encoding encoding.
2020-07-28 17:13:15.9000|INFO:SGDB Initialized
2020-07-28 17:13:15.9000|INFO:AvailableFields
2020-07-28 17:13:15.9000|INFO:GetAvailableFields
2020-07-28 17:13:15.9000|INFO:https://www.steamgriddb.com/api/v2/heroes/gog/1207663753
2020-07-28 17:13:16.1056|INFO:{"success":false,"status":404,"errors":["Game not found"]}
2020-07-28 17:13:16.1056|DEBUG:Copying file bad path to D:\Client\PlayNite\7\library\files\74e0d2e4-8c98-4fda-866e-1b80c0fc2944\07e6e307-50c2-45ca-9436-3b3e87b30903
2020-07-28 17:13:16.1056|ERROR:Failed to copy file bad path to database.System.IO.FileNotFoundException: Could not find file 'bad path'.
File name: 'bad path'
  at System.IO.__Error.WinIOError(Int32 errorCode, String maybeFullPath)
  at System.IO.File.InternalCopy(String sourceFileName, String destFileName, Boolean overwrite, Boolean checkHost)
  at System.IO.File.Copy(String sourceFileName, String destFileName, Boolean overwrite)
  at Playnite.Common.FileSystem.CopyFile(String sourcePath, String targetPath, Boolean overwrite)
  at Playnite.Database.GameDatabase.AddFile(String path, Guid parentId) in E:\Devel\Playnite\source\Playnite\Database\GameDatabase.cs:line 379
2020-07-28 17:13:16.1056|INFO:AvailableFields
2020-07-28 17:13:16.1056|INFO:GetCoverImage
2020-07-28 17:13:16.1056|INFO:https://www.steamgriddb.com/api/v2/grids/gog/1207663753?dimensions=600x900&styles=alternate
2020-07-28 17:13:16.3262|INFO:{"success":false,"status":404,"errors":["Game not found"]}
2020-07-28 17:13:16.3262|DEBUG:Copying file bad path to D:\Client\PlayNite\7\library\files\74e0d2e4-8c98-4fda-866e-1b80c0fc2944\69443918-2c6a-433e-899a-f41cc5950694
2020-07-28 17:13:16.3262|ERROR:Failed to copy file bad path to database.System.IO.FileNotFoundException: Could not find file 'bad path'.
File name: 'bad path'
  at System.IO.__Error.WinIOError(Int32 errorCode, String maybeFullPath)
  at System.IO.File.InternalCopy(String sourceFileName, String destFileName, Boolean overwrite, Boolean checkHost)
  at System.IO.File.Copy(String sourceFileName, String destFileName, Boolean overwrite)
  at Playnite.Common.FileSystem.CopyFile(String sourcePath, String targetPath, Boolean overwrite)
  at Playnite.Database.GameDatabase.AddFile(String path, Guid parentId) in E:\Devel\Playnite\source\Playnite\Database\GameDatabase.cs:line 379

See also https://github.com/cooperate/SteamGridDB...a/issues/6
« Next Oldest | Next Newest »
Pages (2): 1 2 Next »



  • View a Printable Version
  • Subscribe to this thread

© Designed by D&D - Powered by MyBB

Linear Mode
Threaded Mode