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

Add better IMDb logic #60

Merged
merged 9 commits into from Mar 3, 2020
Merged

Add better IMDb logic #60

merged 9 commits into from Mar 3, 2020

Conversation

lcd1232
Copy link
Contributor

@lcd1232 lcd1232 commented Mar 2, 2020

Some of the films have a different layout for IMDb. I fixed it.

@coveralls
Copy link

coveralls commented Mar 2, 2020

Coverage Status

Coverage increased (+0.3%) to 94.549% when pulling 9373c91 on lcd1232:master into 9b0626c on ramusus:master.

@@ -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()',
Copy link
Owner

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.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@ramusus ramusus merged commit 4d55e90 into ramusus:master Mar 3, 2020
@ramusus
Copy link
Owner

ramusus commented Mar 3, 2020

Thanks @lcd1232!

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

3 participants