The viewgame API is now the easiest way to see the list of tags for a game, if all you want to see is the public tags. (It didn’t include tags before, but now it does.)
But I see that tm.py is using mine_only, and for that, you’d use the search API, like this:
Sorry to keep wandering in here with problems, but I just realized that since the update, when the tag manipulator adds a tag to a game I’ve tagged in the past, it erases all my previous tags.
Unfortunately, I am engaged on other time-critical projects at the moment, and I don’t have the time to continue adapting an open-source project to an API that, although stable for many years, is now apparently subject to major breaking changes without either advance warning or backwards compatibility. Maybe @salty-horse or another user is interested in ensuring that community-made tools continue to work with IFDB’s changing infrastructure?
For now, my recommendation would be to quit using the tool, as I can no longer guarantee that it will work correctly or even predictably. I may return to this project in the future.
I’d prefer that you post updated versions on this forum thread, not GitHub. Anyway, I agree with dfabulich; having a similar capability integrated into IFDB itself would be a better and more sustainable solution.
Having it in a repository makes it easier to track changes.
Here’s what I did:
Changed tabs to spaces, and moved import to the top, to be closer to Python conventions.
Used built-in Python functions for building URLs.
Changed the APIs to the new ones, so got rid of the XML code. Backups are now in JSON.
Printing the exception if it happens when saving tags.
I noticed some weird errors that don’t affect anything. Searching for a TUID “abc” will say Warning: no game found with title "abc". But everything else will work fine.
It was just -st "<name of tag>" -at "<name of other tag>". (I did several rounds of bulk tagging before I noticed the problem, so I can say that the specific tags involved do not appear to matter.)