mirror of
https://github.com/clinton-hall/nzbToMedia.git
synced 2025-08-19 21:03:14 -07:00
improve logging for imdb id lookup. #1341
This commit is contained in:
parent
01bb0b9bc1
commit
e5066cba0d
1 changed files with 4 additions and 2 deletions
|
@ -1118,10 +1118,12 @@ def find_imdbid(dirName, inputName, omdbApiKey):
|
||||||
|
|
||||||
url = "http://www.omdbapi.com"
|
url = "http://www.omdbapi.com"
|
||||||
|
|
||||||
|
if not omdbApiKey:
|
||||||
|
logger.info("Unable to determine imdbID: No api key provided for ombdapi.com.")
|
||||||
|
return
|
||||||
|
|
||||||
logger.debug("Opening URL: {0}".format(url))
|
logger.debug("Opening URL: {0}".format(url))
|
||||||
|
|
||||||
if not omdbApiKey:
|
|
||||||
return
|
|
||||||
try:
|
try:
|
||||||
r = requests.get(url, params={'apikey': omdbApiKey, 'y': year, 't': title},
|
r = requests.get(url, params={'apikey': omdbApiKey, 'y': year, 't': title},
|
||||||
verify=False, timeout=(60, 300))
|
verify=False, timeout=(60, 300))
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue