gogrepoc
gogrepoc copied to clipboard
Orphaning dir fails because path already exists
I'm using gogrepoc for a few years now, and I am very thankful that it exists, because it enables me to download and manage my entire collection which has become quite big nowadays. However, recently I have repeatedly stumbled upon this annoying bug, which appears to occur whenever a game on GOG is renamed (or removed) AND this exact game has already had orphaned file entries in the past. Thus when moving the whole game directory into the orphaned folder, it fails, because a folder named like this is already there.
Subsequently the script completely stops orphaning the remaining files, because there is no proper error handling.
This error occurred with Master of Magic and some other game, and now with Wolfenstein 3D.
I always have to manually remove/rename the problematic folders, because orphaning always fails when the folder is present.
Here is the log output:
08:25:59 | orphaning dir 'wolfenstein_3d'
08:25:59 | fatal...
Traceback (most recent call last):
File "gogrepoc.py", line 2891, in