Python scraper based on AI
Python ai-crawlerai-scrapingai-searchcrawlerdata-extractionfirecrawl-alternativelarge-language-modelllmmarkdownragscrapingscraping-pythonweb-crawlerweb-crawlersweb-dataweb-data-extractionweb-scraperweb-scrapingweb-searchwebscraping
Fix E402 errors in smart_scraper_graph.py by moving imports to top
copilot-swe-agent[bot]ced037395140
diff --git a/scrapegraphai/graphs/smart_scraper_graph.py b/scrapegraphai/graphs/smart_scraper_graph.pyindex 8cf11f35..ffcd3dbe 100644--- a/scrapegraphai/graphs/smart_scraper_graph.py+++ b/scrapegraphai/graphs/smart_scraper_graph.py@@ -7,9 +7,6 @@ from typing import Optional, Typefrom pydantic import BaseModel-# Initialize logger-logger = logging.getLogger(__name__)-from ..nodes import (ConditionalNode,FetchNode,@@ -21,6 +18,9 @@ from ..prompts import REGEN_ADDITIONAL_INFOfrom .abstract_graph import AbstractGraphfrom .base_graph import BaseGraph+# Initialize logger+logger = logging.getLogger(__name__)+class SmartScraperGraph(AbstractGraph):"""@@ -97,7 +97,7 @@ class SmartScraperGraph(AbstractGraph):)# Use logging instead of print for better production practices- if 'request_id' in response and 'result' in response:+ if "request_id" in response and "result" in response:logger.info(f"Request ID: {response['request_id']}")logger.info(f"Result: {response['result']}")else: