Scrape: restore full-size movie poster URL for UMD video covers
This commit is contained in:
+3
-1
@@ -1400,7 +1400,7 @@ def get_movie_metadata(title, timeout=10):
|
||||
# Manual linking (pick the correct movie/game when the auto-match is wrong)
|
||||
# --------------------------------------------------------------------------- #
|
||||
def search_movies(query, limit=20, timeout=10):
|
||||
"""Return [{id, title, year, overview, thumb_url, source}] for a movie search.
|
||||
"""Return [{id, title, year, overview, thumb_url, image_url, source}] for a movie search.
|
||||
|
||||
TheMovieDB first; keyless Wikipedia page titles as a fallback.
|
||||
"""
|
||||
@@ -1422,6 +1422,7 @@ def search_movies(query, limit=20, timeout=10):
|
||||
"year": (r.get("release_date") or "")[:4],
|
||||
"overview": (r.get("overview") or "").strip(),
|
||||
"thumb_url": (_TMDB_IMAGE + "w185" + poster) if poster else "",
|
||||
"image_url": (_TMDB_IMAGE + "w500" + poster) if poster else "",
|
||||
"source": "tmdb",
|
||||
})
|
||||
if not out:
|
||||
@@ -1432,6 +1433,7 @@ def search_movies(query, limit=20, timeout=10):
|
||||
"year": "",
|
||||
"overview": "",
|
||||
"thumb_url": "",
|
||||
"image_url": "",
|
||||
"source": "wikipedia",
|
||||
})
|
||||
return out[:limit]
|
||||
|
||||
Reference in New Issue
Block a user