diff --git a/src/calibre/gui2/store/stores/amazon_au_plugin.py b/src/calibre/gui2/store/stores/amazon_au_plugin.py index dda7a505d6..ed925783d6 100644 --- a/src/calibre/gui2/store/stores/amazon_au_plugin.py +++ b/src/calibre/gui2/store/stores/amazon_au_plugin.py @@ -4,7 +4,7 @@ from __future__ import (unicode_literals, division, absolute_import, print_function) -store_version = 4 # Needed for dynamic plugin loading +store_version = 5 # Needed for dynamic plugin loading from contextlib import closing import urllib @@ -66,7 +66,7 @@ def search_amazon(query, max_results=10, timeout=60, cover_xpath = "descendant-or-self::img[@class and contains(concat(' ', normalize-space(@class), ' '), ' s-access-image ')]/@src" title_xpath = "descendant-or-self::h2[@class and contains(concat(' ', normalize-space(@class), ' '), ' s-access-title ')]//text()" author_xpath = './/span[starts-with(text(), "by ")]/following-sibling::span//text()' - price_xpath = 'descendant::span[contains(@class, "s-price")]//text()' + price_xpath = 'descendant::div[@class="a-row a-spacing-none" and not(span[contains(@class, "kindle-unlimited")])]//span[contains(@class, "s-price")]//text()' else: return diff --git a/src/calibre/gui2/store/stores/amazon_ca_plugin.py b/src/calibre/gui2/store/stores/amazon_ca_plugin.py index 5035be15da..88c0957a75 100644 --- a/src/calibre/gui2/store/stores/amazon_ca_plugin.py +++ b/src/calibre/gui2/store/stores/amazon_ca_plugin.py @@ -4,7 +4,7 @@ from __future__ import (unicode_literals, division, absolute_import, print_function) -store_version = 6 # Needed for dynamic plugin loading +store_version = 7 # Needed for dynamic plugin loading from contextlib import closing import urllib @@ -66,7 +66,7 @@ def search_amazon(query, max_results=10, timeout=60, cover_xpath = "descendant-or-self::img[@class and contains(concat(' ', normalize-space(@class), ' '), ' s-access-image ')]/@src" title_xpath = "descendant-or-self::h2[@class and contains(concat(' ', normalize-space(@class), ' '), ' s-access-title ')]//text()" author_xpath = './/span[starts-with(text(), "by ")]/following-sibling::span//text()' - price_xpath = 'descendant::span[contains(@class, "s-price")]//text()' + price_xpath = 'descendant::div[@class="a-row a-spacing-none" and not(span[contains(@class, "kindle-unlimited")])]//span[contains(@class, "s-price")]//text()' else: return diff --git a/src/calibre/gui2/store/stores/amazon_de_plugin.py b/src/calibre/gui2/store/stores/amazon_de_plugin.py index 1dad09ce60..07bab1f669 100644 --- a/src/calibre/gui2/store/stores/amazon_de_plugin.py +++ b/src/calibre/gui2/store/stores/amazon_de_plugin.py @@ -4,7 +4,7 @@ from __future__ import (unicode_literals, division, absolute_import, print_function) -store_version = 14 # Needed for dynamic plugin loading +store_version = 15 # Needed for dynamic plugin loading from contextlib import closing import urllib @@ -68,7 +68,7 @@ def search_amazon(query, max_results=10, timeout=60, cover_xpath = "descendant-or-self::img[@class and contains(concat(' ', normalize-space(@class), ' '), ' s-access-image ')]/@src" title_xpath = "descendant-or-self::h2[@class and contains(concat(' ', normalize-space(@class), ' '), ' s-access-title ')]//text()" author_xpath = './/span[starts-with(text(), "%s ")]/following-sibling::span//text()' % BY - price_xpath = 'descendant::span[contains(@class, "s-price")]//text()' + price_xpath = 'descendant::div[@class="a-row a-spacing-none" and not(span[contains(@class, "kindle-unlimited")])]//span[contains(@class, "s-price")]//text()' else: return diff --git a/src/calibre/gui2/store/stores/amazon_es_plugin.py b/src/calibre/gui2/store/stores/amazon_es_plugin.py index a46ac72c69..d159cd4940 100644 --- a/src/calibre/gui2/store/stores/amazon_es_plugin.py +++ b/src/calibre/gui2/store/stores/amazon_es_plugin.py @@ -4,7 +4,7 @@ from __future__ import (unicode_literals, division, absolute_import, print_function) -store_version = 14 # Needed for dynamic plugin loading +store_version = 15 # Needed for dynamic plugin loading from contextlib import closing import urllib @@ -68,7 +68,7 @@ def search_amazon(query, max_results=10, timeout=60, cover_xpath = "descendant-or-self::img[@class and contains(concat(' ', normalize-space(@class), ' '), ' s-access-image ')]/@src" title_xpath = "descendant-or-self::h2[@class and contains(concat(' ', normalize-space(@class), ' '), ' s-access-title ')]//text()" author_xpath = './/span[starts-with(text(), "%s ")]/following-sibling::span//text()' % BY - price_xpath = 'descendant::span[contains(@class, "s-price")]//text()' + price_xpath = 'descendant::div[@class="a-row a-spacing-none" and not(span[contains(@class, "kindle-unlimited")])]//span[contains(@class, "s-price")]//text()' else: return diff --git a/src/calibre/gui2/store/stores/amazon_in_plugin.py b/src/calibre/gui2/store/stores/amazon_in_plugin.py index 241a4961d0..afa40fa861 100644 --- a/src/calibre/gui2/store/stores/amazon_in_plugin.py +++ b/src/calibre/gui2/store/stores/amazon_in_plugin.py @@ -4,7 +4,7 @@ from __future__ import (unicode_literals, division, absolute_import, print_function) -store_version = 4 # Needed for dynamic plugin loading +store_version = 5 # Needed for dynamic plugin loading from contextlib import closing import urllib @@ -66,7 +66,7 @@ def search_amazon(query, max_results=10, timeout=60, cover_xpath = "descendant-or-self::img[@class and contains(concat(' ', normalize-space(@class), ' '), ' s-access-image ')]/@src" title_xpath = "descendant-or-self::h2[@class and contains(concat(' ', normalize-space(@class), ' '), ' s-access-title ')]//text()" author_xpath = './/span[starts-with(text(), "by ")]/following-sibling::span//text()' - price_xpath = 'descendant::span[contains(@class, "s-price")]//text()' + price_xpath = 'descendant::div[@class="a-row a-spacing-none" and not(span[contains(@class, "kindle-unlimited")])]//span[contains(@class, "s-price")]//text()' else: return diff --git a/src/calibre/gui2/store/stores/amazon_it_plugin.py b/src/calibre/gui2/store/stores/amazon_it_plugin.py index 55254b5fc2..5efab2e816 100644 --- a/src/calibre/gui2/store/stores/amazon_it_plugin.py +++ b/src/calibre/gui2/store/stores/amazon_it_plugin.py @@ -4,7 +4,7 @@ from __future__ import (unicode_literals, division, absolute_import, print_function) -store_version = 14 # Needed for dynamic plugin loading +store_version = 15 # Needed for dynamic plugin loading from contextlib import closing import urllib @@ -68,7 +68,7 @@ def search_amazon(query, max_results=10, timeout=60, cover_xpath = "descendant-or-self::img[@class and contains(concat(' ', normalize-space(@class), ' '), ' s-access-image ')]/@src" title_xpath = "descendant-or-self::h2[@class and contains(concat(' ', normalize-space(@class), ' '), ' s-access-title ')]//text()" author_xpath = './/span[starts-with(text(), "%s ")]/following-sibling::span//text()' % BY - price_xpath = 'descendant::span[contains(@class, "s-price")]//text()' + price_xpath = 'descendant::div[@class="a-row a-spacing-none" and not(span[contains(@class, "kindle-unlimited")])]//span[contains(@class, "s-price")]//text()' else: return diff --git a/src/calibre/gui2/store/stores/amazon_uk_plugin.py b/src/calibre/gui2/store/stores/amazon_uk_plugin.py index 557d9e44a7..e1390d8692 100644 --- a/src/calibre/gui2/store/stores/amazon_uk_plugin.py +++ b/src/calibre/gui2/store/stores/amazon_uk_plugin.py @@ -4,7 +4,7 @@ from __future__ import (unicode_literals, division, absolute_import, print_function) -store_version = 14 # Needed for dynamic plugin loading +store_version = 15 # Needed for dynamic plugin loading from contextlib import closing import urllib @@ -66,7 +66,7 @@ def search_amazon(query, max_results=10, timeout=60, cover_xpath = "descendant-or-self::img[@class and contains(concat(' ', normalize-space(@class), ' '), ' s-access-image ')]/@src" title_xpath = "descendant-or-self::h2[@class and contains(concat(' ', normalize-space(@class), ' '), ' s-access-title ')]//text()" author_xpath = './/span[starts-with(text(), "by ")]/following-sibling::span//text()' - price_xpath = 'descendant::span[contains(@class, "s-price")]//text()' + price_xpath = 'descendant::div[@class="a-row a-spacing-none" and not(span[contains(@class, "kindle-unlimited")])]//span[contains(@class, "s-price")]//text()' else: return