tauqua / gog-galaxy-itch.io

An integration connecting itch.io to GOG Galaxy 2.0 using itch's v2 API
GNU General Public License v3.0
221 stars 14 forks source link

Unknown Game - difficult to find out which game it is #4

Closed cheater closed 4 years ago

cheater commented 4 years ago

Currently, if the itch.io plugin cannot figure out a game, it's just not going to display anything. Please instead display the url to the game in the title, or something like that, so it can be found on itch.io and added to IGDB.

tauqua commented 4 years ago

Unfortunately, Galaxy does not allow direct inputting of games. All games entered by the plugin get run through GOG's database before displaying in the library, and if they do not appear there will display as "Unknown Game" regardless of what the plugin says. If you look in the plugin log file you'll see all of the games it has tried to import, even games that aren't showing in Galaxy. As far as I can tell there's nothing I can do about this.

cheater commented 4 years ago

can you: a) make a log entry that clearly displays which games haven't been imported? b) make a pop up of some sort that informs us about what games haven't been displayed? c) propose an API change that allows displaying additional data about a game that hasn't come from the GOG database?

On Sun, Jun 14, 2020 at 7:50 PM tauqua notifications@github.com wrote:

Unfortunately, Galaxy does not allow direct inputting of games. All games entered by the plugin get run through GOG's database before displaying in the library, and if they do not appear there will display as "Unknown Game" regardless of what the plugin says. If you look in the plugin log file you'll see all of the games it has tried to import, even games that aren't showing in Galaxy. As far as I can tell there's nothing I can do about this.

— You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub https://github.com/tauqua/gog-galaxy-itch.io/issues/4#issuecomment-643799352, or unsubscribe https://github.com/notifications/unsubscribe-auth/AABPWPSWDS4XXXJRO7PNXH3RWUEWJANCNFSM4N5QPWXA .

tauqua commented 4 years ago

Unfortunately, I'm not sure if I can do any of those. For a and b, Galaxy doesn't indicate to the plugin that a game hasn't been imported as far as I'm aware, and for c this is more an issue with the Galaxy client than API or database, so I'm not sure where that request would go.

I am considering writing a standalone script which would poll your Itch library and GOG and give you a list of games in your library which aren't in GOG's database. However, this is low priority for me as my main priority is maintaining and improving the plugin. If someone else is willing to write this I'm happy to assist in navigating the APIs.

cheater commented 4 years ago

"more an issue with the Galaxy client than API or database"

yeah! I meant request an enhancement to the API you write your plugins against, i.e. the API exposed by the client. It kind of sucks if GOG don't give you any way of requesting issue improvements on that end.

On Wed, Jun 17, 2020 at 8:48 PM tauqua notifications@github.com wrote:

Unfortunately, I'm not sure if I can do any of those. For a and b, Galaxy doesn't indicate to the plugin that a game hasn't been imported as far as I'm aware, and for c this is more an issue with the Galaxy client than API or database, so I'm not sure where that request would go.

I am considering writing a standalone script which would poll your Itch library and GOG and give you a list of games in your library which aren't in GOG's database. However, this is low priority for me as my main priority is maintaining and improving the plugin. If someone else is willing to write this I'm happy to assist in navigating the APIs.

— You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub https://github.com/tauqua/gog-galaxy-itch.io/issues/4#issuecomment-645555494, or unsubscribe https://github.com/notifications/unsubscribe-auth/AABPWPUCQBGTADKK3TFDYRDRXEFYNANCNFSM4N5QPWXA .

nightblade9 commented 3 years ago

Any update on this - is there anything I can do to help?

I installed this today and imported 180ish games from itch (mostly BLM bundle). Around half of them show up as "Unknown Game." I can probably add some of them to IGDB, but I need to know which ones they are.

Any progress on the standalone script? Can you explain a bit how it works? I haven't used any of the GOG/Itch APIs before.

tauqua commented 3 years ago

I haven't had time to work on this at all recently and as far as I can tell nothing has changed on the Galaxy end. See gogcom/galaxy-integrations-python-api#72 . A few more games have crept into their database but the issue still remains. There may be a workaround by changing the declared platform to a different one such as Test in src/manifest.json and src.itch.py. If you'd like to attempt to help with a standalone script I can give some explanation as to my understanding of the GOG and Itch APIs.

nightblade9 commented 3 years ago

I think I would like to attempt the standalone script. Just to verify my understanding so far:

If that's all correct, yes, I would like to take a stab at using the APIs to build a standalone script to figure out which games are missing.

tauqua commented 3 years ago

Most of that is correct, here's a few clarifications:

The issue is on GOG's side, but the plugin DOES have the correct information. The plugin requests the data directly from the Itch API and passes it along to Galaxy, which checks GOG's API for purposes of duplicate merging, standardized titles and such, before it shows up in your library. That check is where it becomes "Unknown Game".

There is some degree of logging. In the Itch plugins log, I'm currently printing every game imported, even those that later turn out to be "Unknown". Further, in the Galaxy client log, it logs an error when it encounters a 404, which is what produces unknown games. However, it seems like it limits these logs or stops printing them after a point, so the Galaxy client logs aren't a comprehensive list.

Manually comparing your Galaxy library to Itch will work with the main issue being quantity. Be aware that the plugin is only attempting to import items that are classified as "Game" on Itch. These are the same filters you find in the Itch desktop app library section.

Correct about the script. To be specific, the page https://gamesdb.gog.com/platforms/itch/external_releases/{appid} where {appid} is the game's internal ID on itch.io (printed in the plugin logs and accessible through API calls) will return an error if the game is not in GOG's library. You can extract my Itch API code practically verbatim from this plugin, the main work is comparing it to GOG.

Typically adding game data to IGDB will turn them into know games in GOG. However, there have been some instances where that hasn't been the case. It's unclear how the databases are related but there seems to be a correlation.

Good luck and lmk any other questions. You can also find me in the GOG Cafe Discord server.

cheater commented 3 years ago

Why not submit itch games one by one and look at which ones become "Unknown game"? That would give you information in a snap, and you can do it within the conceptual framework of the plugin as it is right now, without building any additional scripts, and leveraging existing code to a lare extent.

On Tue, Feb 16, 2021 at 5:56 PM tauqua notifications@github.com wrote:

Most of that is correct, here's a few clarifications:

The issue is on GOG's side, but the plugin DOES have the correct information. The plugin requests the data directly from the Itch API and passes it along to Galaxy, which checks GOG's API for purposes of duplicate merging, standardized titles and such, before it shows up in your library. That check is where it becomes "Unknown Game".

There is some degree of logging. In the Itch plugins log, I'm currently printing every game imported, even those that later turn out to be "Unknown". Further, in the Galaxy client log, it logs an error when it encounters a 404, which is what produces unknown games. However, it seems like it limits these logs or stops printing them after a point, so the Galaxy client logs aren't a comprehensive list.

Manually comparing your Galaxy library to Itch will work with the main issue being quantity. Be aware that the plugin is only attempting to import items that are classified as "Game" on Itch. These are the same filters you find in the Itch desktop app library section.

Correct about the script. To be specific, the page https://gamesdb.gog.com/platforms/itch/external_releases/{appid} where {appid} is the game's internal ID on itch.io (printed in the plugin logs and accessible through API calls) will return an error if the game is not in GOG's library. You can extract my Itch API code practically verbatim from this plugin, the main work is comparing it to GOG.

Typically adding game data to IGDB will turn them into know games in GOG. However, there have been some instances where that hasn't been the case. It's unclear how the databases are related but there seems to be a correlation.

Good luck and lmk any other questions. You can also find me in the GOG Cafe Discord server.

— You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub https://github.com/tauqua/gog-galaxy-itch.io/issues/4#issuecomment-779970950, or unsubscribe https://github.com/notifications/unsubscribe-auth/AABPWPSBRFBXUWWHXAIOMN3S7KPUNANCNFSM4N5QPWXA .

nightblade9 commented 3 years ago

Great, thanks. I'll take a look and see what I can cook up.

Ideally, I want this solution to be some script you point users to, you say "run this and it'll spit out the list of unknown games." That looks complicated because it requires authenticating to Itch.

I think the first couple of steps I'll try is writing a script that can take a game name/URL/something, looking up the internal ID, and cross-referencing to see if it's in GOG or not. After that, it might also be worth knowing if it's in IGDB or not. That would print out a nice report so you can see which games are suspect.

tauqua commented 3 years ago

Why not submit itch games one by one and look at which ones become "Unknown game"? That would give you information in a snap, and you can do it within the conceptual framework of the plugin as it is right now, without building any additional scripts, and leveraging existing code to a lare extent.

That would work, but my Itch library is currently over 2000 items, and the BLM bundle on its own was 1700+. This would be very tedious to do, in the long term a script would most likely be simpler.

nightblade9 commented 3 years ago

my Itch library is currently over 2000 items, and the BLM bundle on its own was 1700+

Tangent question here, seriously?! That's interesting because my Itch library is only around 180 games. Do you need to install the others before they show up in Itch/GOG?

tauqua commented 3 years ago

You have to go through and click download on each game individually. I used this GreaseMonkey script to do it.

nightblade9 commented 3 years ago

@cheater can we reopen this issue for a while since there's some investigation going on?

I looked through the plugin code yesterday. It seems to me that the easiest option is to provide a toggle within it, something like report_unknown_games, which is disabled by default. If enabled, it will cross-reference every game with the IGDB entry, and if there's no match, will print it out in a log file.

Obviously, this is very expensive for people with more than 5-10 games and/or slow internet, since each game check is another HTTP web request; so it'll be off by default.

What do you think of this solution?

cheater commented 3 years ago

sounds good to me. there is a way to have a settings panel in gog galaxy, maybe use that for configuration if you'd like. it could have a button that runs the plugin in this special mode. i can't re-open the issue, @tauqua has to re-open it.

nightblade9 commented 3 years ago

Sorry, I mixed you two up, that previous comment was for @tauqua :sweat_smile:

nightblade9 commented 3 years ago

I opened a PR here (#36) and need some help debugging (the plugin crashes with no logs/errors after a while). Let's please move this conversation into the PR.

nightblade9 commented 3 years ago

@tauqua any plans to look at my PR? It's been open for a couple of weeks.

tauqua commented 3 years ago

Sorry, have been quite busy and my local repo is a mess with WIP changes. Will hopefully have a chance to look everything over this weekend

cheater commented 3 years ago

if you use the command git gui, you can look at all the files you changed, select single lines, and stage them. that should make it simple for you to turn your changes into a coherent commit log with small commits.