Skip item from downloads when "product_name" contains "productVersion"

This commit is contained in:
iainbrad
2025-10-12 13:44:58 +01:00
committed by GitHub
parent ba2d84ef5a
commit 0fc1ca6d6d
+7 -1
View File
@@ -43,7 +43,7 @@ def login_with_selenium(driver, email, password):
Returns:
True if login successful, False otherwise
"""
login_url = "https://shop.2000ad.com/account/sign-in"
login_url = "https://shop.2000ad.com/login"
print("🔐 Navigating to login page...")
driver.get(login_url)
@@ -217,6 +217,12 @@ def download_cbz_files(email, password, output_dir='downloads', headless=True):
# Get product name for better logging
product_name = product.get('data-name', 'Unknown')
# Skip products with placeholder/error text
if '[Pen_-productVersion' in product_name or 'productVersion' in product_name:
print(f"⏭️ Skipping (placeholder/error in name): {product_name}")
skipped += 1
continue
# Get publication date
release_date = product.get('data-released', '')
date_str = ''