Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Support looking up via uniqueIDs (filename identifiers) #205

Merged
merged 1 commit into from
Dec 16, 2023

Conversation

sundermann
Copy link
Contributor

Add the needed changes for looking up by unique identifiers required for supporting filename identifiers. The current implementation allows only for tmdb and imdb identifiers because no additional call to find by id is done. tmdb does support looking up by Facebook, Instagram, TikTok, Twitter, Wikidata and YouTube but the benefit of those identifiers is questionable. The normal tmdb movie API accepts imdb identifiers which is probably the most common identifier besides native tmdb identifiers.

The implementation does not catch errors which means that if a wrong identifier is supplied in the filename an error message is shown in kodi. It is up to debate if it would be better to catch the exception in case of a unique identifier lookup and fail silently. If a movie could not be looked up, Kodi falls back to the traditional lookup by title and year.

@rmrector
Copy link
Contributor

rmrector commented Dec 9, 2023

Agreed about low benefit for the other identifiers.

Where is there error message coming from? That shouldn't happen - we do not want to see an error if things are working as expected. Scrapers can log a debug message if they receive an ID they don't recognize, but not much more than that.

@sundermann
Copy link
Contributor Author

TMDB returns 404 if called with a non-existing id:
2023-12-09 17:24:14.493328+0100 Kodi[62051:9174096] 2023-12-09 17:24:14.493 T:9174096 warning <general>: [metadata.themoviedb.org.python]: The Movie Database Python error with web service TMDB: failed to reach the remote site Reason: Not Found

@sundermann
Copy link
Contributor Author

It fails silently now for the uniqueIDs lookup showing no error notification but still logging the error

@rmrector
Copy link
Contributor

Why log as a warning? This is expected behavior now. Any message that shows up outside of debug will generate more support requests.

@sundermann
Copy link
Contributor Author

Alright, changed it to skip logging as well

@rmrector
Copy link
Contributor

Cheers

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants