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
Add better IMDb logic #60
Conversation
@@ -204,10 +204,16 @@ class MovieMainPage(KinopoiskPage): | |||
'rating': './/span[@class="rating_ball"]/text()', | |||
'votes': './/div[@id="block_rating"]//div[@class="div1"]//span[@class="ratingCount"]/text()', | |||
'imdb': './/div[@id="block_rating"]//div[@class="block_2"]//div[last()]/text()', | |||
'imdb2': './/div[@id="block_rating"]//div[@class="block_2"]//div[last()-1]/text()', |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Could you please try './/div[@id="block_rating"]//div[@class="block_2"]//div[position()>last()-1]/text()'
for imdb
index? I would like to keep as less xpath as possible.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
# Conflicts: # .travis.yml
This reverts commit 4b47ae5
Thanks @lcd1232! |
Some of the films have a different layout for IMDb. I fixed it.