Spaces:
Running
Running
Update main.py
Browse files
main.py
CHANGED
@@ -599,18 +599,17 @@ async def _run_apify_actor_for_web_content(url: str, api_token: str, actor_id: s
|
|
599 |
}
|
600 |
logger.debug(f"{log_prefix} Using input format for Default YT Actor ({APIFY_ACTOR_ID}) with Residential Proxy")
|
601 |
# --- CORRECTED BLOCK START (Ensure this 'elif' has same indentation as the 'if' above) ---
|
602 |
-
|
603 |
-
# Input
|
604 |
run_input = {
|
605 |
-
"
|
606 |
"proxyConfiguration": {
|
607 |
"useApifyProxy": True,
|
608 |
"apifyProxyGroups": ["RESIDENTIAL"],
|
609 |
},
|
610 |
"maxRetries": 5,
|
611 |
}
|
612 |
-
|
613 |
-
logger.debug(f"{log_prefix} Using list input format for Structured YT Actor ({actor_id}) with Residential Proxy")
|
614 |
# --- END ADDED PROXY CONFIG ---
|
615 |
# (Extra brace and redundant logger call removed from here)
|
616 |
elif actor_id == APIFY_TEXT_SCRAPER_ACTOR_ID:
|
|
|
599 |
}
|
600 |
logger.debug(f"{log_prefix} Using input format for Default YT Actor ({APIFY_ACTOR_ID}) with Residential Proxy")
|
601 |
# --- CORRECTED BLOCK START (Ensure this 'elif' has same indentation as the 'if' above) ---
|
602 |
+
elif actor_id == APIFY_STRUCTURED_YT_ACTOR_ID:
|
603 |
+
# Input for the Structured YT extractor actor must use a single "url" string
|
604 |
run_input = {
|
605 |
+
"url": url,
|
606 |
"proxyConfiguration": {
|
607 |
"useApifyProxy": True,
|
608 |
"apifyProxyGroups": ["RESIDENTIAL"],
|
609 |
},
|
610 |
"maxRetries": 5,
|
611 |
}
|
612 |
+
logger.debug(f"{log_prefix} Using input format for Structured YT Actor ({actor_id}) with Residential Proxy")
|
|
|
613 |
# --- END ADDED PROXY CONFIG ---
|
614 |
# (Extra brace and redundant logger call removed from here)
|
615 |
elif actor_id == APIFY_TEXT_SCRAPER_ACTOR_ID:
|