-
-
Notifications
You must be signed in to change notification settings - Fork 321
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
IMDB collections not working #1496
Comments
There was apparently a recent change on the IMDB side such that PMM's requests now fail or return empty responses. It is yet to be fully characterized, and there's no ETA for a fix. |
I'm sure this wasn't clear in my initial post, but I was able to fix this by passing the The actual solution probably should pass the language to the headers function. |
Oh, thanks; I've been answering this same question reflexively over and over recently so didn't read this as closely as I obviously should have. |
#1499 this should fix it <3 |
Getting a similar error too, I've switched over to the nightly branch but the imdb fix recently committed there hasn't done the trick. I've got two collections that just check the imdb popular lists and neither have updated or been sorted correctly for the last few weeks. |
Can you share the specific urls to these imdb lists? |
Just using the default templates by PMM, here's the config I'm using: libraries:
Movies:
metadata_path:
- pmm: imdb
template_variables:
item_radarr_tag_popular: popular
name_popular: Popular
order_popular: 0
summary_popular: ''
use_popular: true
use_top: false
use_lowest: false
visible_home_popular: true
visible_library: true
visible_shared_popular: true
TV:
metadata_path:
- pmm: imdb
template_variables:
name_popular: Popular
order_popular: 0
summary_popular: ''
use_popular: true
use_top: false
use_lowest: false
visible_home_popular: true
visible_library: true
visible_shared_popular: true |
These use IMDb charts, they (IMDb) are currently changing the html structure of charts. This might've broken the IMDb scraper. |
I just noticed that this was no longer working too. I was able to make a quick fix to get this to work. I tested only the popular and top 250 urls: https://www.imdb.com/chart/moviemeter It's been awhile since I've used python, but I got this to work by changing the last line in _ids_from_chart in imdb.py. This is from the nightly branch. def _ids_from_chart(self, chart, language):
if chart == "box_office":
url = "chart/boxoffice"
elif chart == "popular_movies":
url = "chart/moviemeter"
elif chart == "popular_shows":
url = "chart/tvmeter"
elif chart == "top_movies":
url = "chart/top"
elif chart == "top_shows":
url = "chart/toptv"
elif chart == "top_english":
url = "chart/top-english-movies"
elif chart == "top_indian":
url = "india/top-rated-indian-movies"
elif chart == "lowest_rated":
url = "chart/bottom"
else:
raise Failed(f"IMDb Error: chart: {chart} not ")
#return self._request(f"https://www.imdb.com/{url}", language=language, xpath="//div[@class='wlb_ribbon']/@data-tconst")
ids = self._request(f"https://www.imdb.com/{url}", language=language, xpath="//a[@class='ipc-lockup-overlay ipc-focusable']/@href")
return [i.split('/')[2] for i in ids] This at least works with the current HTML returned from IMDb. |
yea imdb just pushed out more changes. the current nightly69 should fix it again |
i imagine this will be a cat and mouse game for a while, until imdb is done doing what they're doing |
Version Number
1.19.0
What branch are you on?
master
Describe the Bug
The IMDB Chart collections are no longer being updated.
I'm not sure when this started, but I traced this to to receiving a 403 forbidden error when retrieving the IMDB resources, https://www.imdb.com/chart/moviemeter.
The User-Agent header is not being overwritten, which is causing IMDB to reject these requests.
modules/imdb.py
Relevant Collection/Overlay/Playlist Definition
No response
Logs
No response
The text was updated successfully, but these errors were encountered: