FriendsOfGalaxy / galaxy-integration-origin

origin integration for galaxy
77 stars 14 forks source link

Uninstall game goes to Control panel/Uninstall list #15

Open SylwesterZarebski opened 4 years ago

SylwesterZarebski commented 4 years ago

Describe the bug When I choose Manage install/Uninstall uninstaller is not run, but Control panel/Uninstall list is shown.

To Reproduce Choose any installed Origin game, then Manage install/Uninstall.

Expected behavior Uninstall game - the same as in Origin.

Attached logs Relevant log entries:

2019-12-22 20:19:23,299 - galaxy.api.jsonrpc - INFO - Handling notification: method=uninstall_game, params={'game_id': 'Origin.OFR.50.0001892'}
2019-12-22 20:19:23,299 - galaxy.task_manager - DEBUG - Task manager jsonrpc server: creating task 17 (uninstall_game)
2019-12-22 20:19:23,300 - galaxy.task_manager - DEBUG - Task manager plugin external: creating task 24 (uninstall_game)
2019-12-22 20:19:23,410 - galaxy.task_manager - DEBUG - Task manager plugin external: finished task 24 (uninstall_game)
2019-12-22 20:19:23,410 - galaxy.task_manager - DEBUG - Task manager jsonrpc server: finished task 17 (uninstall_game)
SylwesterZarebski commented 4 years ago

This may be problem of Origin platform, not GOG nor plugin, but still reporting this to check it out.

FriendsOfGalaxy commented 4 years ago

Well, its intentional. Origin do the same, at least for some games, for example Need For Speed Shift.

We didn't found browser protocol command for uninstall, so just use simplified "uninstall" for all.

SylwesterZarebski commented 4 years ago

It is true for only some games. Most of them are uninstalled right off from the client (Origin) without going to control panel. I've checked this with Battlefield V (5) game. It is uninstalled right off from Origin and GOG goes to control panel.

Thanks for information. If it is limitation of protocol, it may be resolved in future.

FriendsOfGalaxy commented 4 years ago

Sure, but usually foreign clients do not need to implement "uninstall" command in browser protocol, so if it does not exists now, I wouldn't suspect this to appear in the near future.

But maybe it does exist? You can try out to find - we're accepting any ideas and PRs :)

Another way is to parse uninstall registry and just call proper UninstallString db4d4f707b905656be2897178d72068d

which in case of Need For Speed shift will result in: c31aaf1074c7e9aaf55d32de50d41022

or without warning prompt if box was selected (in this case it is MsiExec.exe feature). Can you check if uninstalling Battlefield V from control panel flow is the same as uninstalling from Origin client?

SylwesterZarebski commented 4 years ago

Checking Steam plugin it looks like Steam have desired functionality, maybe Origin will have it in future.

PS. Uninstalling from Origin sometimes do not show usual window but some internal/styled one and uninstall immediately then. I'll check with Battlefield V or another game when i'll be home.

FriendsOfGalaxy commented 4 years ago

@SylwesterZarebski how the situation with uninstalling Battlefield/other custom uninstalled game?

SylwesterZarebski commented 4 years ago

Sorry for delay. I checked few other games (B5 is too big to download just for uninstall :-/) and it looks like executing uninstall from EA client is the same as from Control Panel.

Uninstall from Control Panel: obraz Uninstall from EA client: obraz

All games which i've checked was executing EA Installer Cleanup tool: obraz

FriendsOfGalaxy commented 4 years ago

Thanks for checking! I'll research how EA Installer Cleanup works in spare time to handle uninstall properly.

FriendsOfGalaxy commented 3 years ago

During EA Desktop research I found this in their logs after trying to uninstall UnravelTwo (steam version).

    73  [2021-05-20T09:21:52.383Z]   19652  INFO      (eax::services::gameManagement::readManifestFile) Reading manifest file: D:\Games\SteamLibrary\steamapps\common\UnravelTwo\__Installer\installerdata.xml.
    74  [2021-05-20T09:21:52.384Z]   19652  ERROR     (eax::legacyInterface::content::fillCatalogLocalUninstall)  Could not parse uninstallCommandLine=[] of offerId=[Origin.OFR.50.0002520]

It resulted in opening Control Panel. Looks like opening Control Panel is a fallback for getting unistall command from installer manifest.

Attaching the game manifest that EA Desktop couldn't parse: installerdata.zip

I wonder if looking for __Installer\installerdata.xml can be safely hardcoded in all Origin games. I've checked 2 games and it is there.

I have no time (for now) to implement this enhancement but it shouldn't be very difficult. And we can do better than EA Desktop (and Origin?), if we can parse manifest properly each time:)


UPDATE I'm not sure how it relates to EA Installer Cleanup