mirror of
https://github.com/R0m1k3/Priceflow.git
synced 2026-10-20 13:48:16 +02:00
fix: Correct proxy configuration for Crawl4AI compatibility
- Changed proxy format from dict to string (http://user:pass@ip:port) - Updated get_random_proxy() to return Crawl4AI-compatible format - Replaced deprecated 'proxy' with 'proxy_config' in BrowserConfig - Fixed test script to handle new proxy format - Added credential hiding in proxy logging for security Fixes AttributeError: 'dict' object has no attribute 'strip'
This commit is contained in:
2 files changed
+24
-10
No files matched your search
@@ -98,7 +98,10 @@ async def test_anti_detection():
|
||||
# Test proxy
|
||||
proxy = get_random_proxy()
|
||||
if proxy:
|
||||
logger.info(f"✓ Proxy test: {proxy['server']}")
|
||||
# Extract just the IP for logging (hide credentials)
|
||||
proxy_parts = proxy.split('@')
|
||||
proxy_server = proxy_parts[1] if len(proxy_parts) > 1 else proxy
|
||||
logger.info(f"✓ Proxy test: {proxy_server}")
|
||||
else:
|
||||
logger.warning("⚠️ Pas de proxy configuré")
|
||||
|
||||
|
||||
Reference in new issue
Block a user