mirror of
https://github.com/R0m1k3/Priceflow.git
synced 2026-10-24 15:48:11 +02:00
feat: Add Cataloguemate.fr scraper service to replace Tiendeo, utilizing BrowserlessService for robust scraping.
This commit is contained in:
1 parent
101e5f0656
commit
cde1f75d3a
1 file changed
+1
-4
@@ -9,6 +9,7 @@ Refactored to use BrowserlessService for robust containerized scraping.
|
|||||||
import asyncio
|
import asyncio
|
||||||
import logging
|
import logging
|
||||||
import re
|
import re
|
||||||
|
import hashlib
|
||||||
from datetime import datetime, timedelta
|
from datetime import datetime, timedelta
|
||||||
from typing import Any, Optional
|
from typing import Any, Optional
|
||||||
|
|
||||||
@@ -229,10 +230,6 @@ async def scrape_enseigne(enseigne: Enseigne, db: Session) -> ScrapingLog:
|
|||||||
if not pages:
|
if not pages:
|
||||||
continue
|
continue
|
||||||
|
|
||||||
import hashlib
|
|
||||||
|
|
||||||
# ... imports ...
|
|
||||||
|
|
||||||
# Create catalog entry
|
# Create catalog entry
|
||||||
# Generate content hash (URL + Title + Date)
|
# Generate content hash (URL + Title + Date)
|
||||||
hash_input = f"{cat_info['url']}{cat_info['title']}{datetime.now().date()}".encode('utf-8')
|
hash_input = f"{cat_info['url']}{cat_info['title']}{datetime.now().date()}".encode('utf-8')
|
||||||
|
|||||||
Reference in new issue
Block a user