개요
Scrapling은 단일 요청부터 대규모 크롤링까지 지원하는 적응형 웹 스크래핑 프레임워크입니다. 이 파서는 웹사이트의 변화를 학습하여 페이지가 업데이트될 때 요소를 자동으로 다시 찾습니다. Cloudflare Turnstile과 같은 안티크롤링 시스템 우회 기능이 내장되어 있으며, 동시 다중 세션 크롤링과 프록시 로테이션을 지원합니다.
README 미리보기
\n\n\n \n \n \n \n \n \n \n Effortless Web Scraping for the Modern Web\n\n\n\n \n \n العربيه | Español | Português (Brasil) | Français | Deutsch | 简体中文 | 日本語 | Русский | 한국어\n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n\n\n\n Selection methods\n ·\n Fetchers\n ·\n Spiders\n ·\n Proxy Rotation\n ·\n CLI\n ·\n MCP\n\n\nScrapling is an adaptive Web Scraping framework that handles everything from a single request to a full-scale crawl.\n\nIts parser learns from website changes and automatically relocates your elements when pages update. Its fetchers bypass anti-bot systems like Cloudflare Turnstile out of the box. And its spider framework lets you scale up to concurrent, multi-session crawls with pause/resume and automatic proxy rotation - all in a few lines of Python. One library, zero compromises.\n\nBlazing fast crawls with real-time stats and streaming. Built by Web Scrapers for Web Scrapers and regular users, there's something for everyone.\n\n```python\nfrom scrapling.fetchers import Fetcher, AsyncFetcher, StealthyFetcher, DynamicFetcher\nStealthyFetcher.adaptive = True\np = StealthyFetcher.fetch('https://example.com', headless=True, network_idle=True) # Fetch website under the radar!\nproducts = p.css('.product', auto_save=True) # Scrape data that survives website design changes!\nproducts = p.css('.product', adaptive=True) # Later, if the website structure changes, pass `adaptive=True` to find them!\n```\nOr scale up to full crawls\n```python\nfrom scrapling.spiders import Spider, Response\n\nclass MySpider(Spider):\n name = "demo"\n start_urls = ["https://example.com/"]\n\n async def parse(self, response: Response):\n for item in response.css('.product'):\nFAQ (5)
문제 해결Claude Desktop에서 Docker MCP 연결 오류: 'pull access denied for scrapling, repository does not exist' 해결 방법
claude_desktop_config.json에서 scrapling 대신 전체 Docker 이미지 이름 pyd4vinci/scrapling을 사용하세요.
1. 이미지를 가져옵니다:
docker pull pyd4vinci/scrapling
2. MCP 서버 구성을 업데이트합니다:
{
"mcpServers": {
"ScraplingServer": {
"command": "/usr/local/bin/docker",
"args": ["run", "-i", "--rm", "pyd4vinci/scrapling", "mcp"]
}
}
}
macOS에서는 Docker 설치 환경에 따라 command를 "docker" 또는 /usr/local/bin/docker로 지정할 수도 있습니다.
3. 파일을 저장하고 Claude Desktop을 완전히 다시 시작하세요.
이 오류는 Docker가 scrapling을 scrapling:latest라는 이름의 이미지로 해석하지만, 실제로 가져온 이미지는 pyd4vinci/scrapling:latest이기 때문에 발생합니다.
문제 해결scrapling에서 lxml 6 사용 시 "DeprecationWarning: The 'strip_cdata' option of HTMLParser()" 경고를 해결하는 방법
이 경고는 scrapling (≤0.4.15)이 lxml의 HTMLParser()에 strip_cdata를 전달하기 때문에 발생하며, lxml 6에서 해당 옵션은 폐기(deprecated)되었습니다(이 옵션은 원래 아무 효과도 없었으며, 향후 제거된 후에는 TypeError가 발생합니다). 해결 방법:
1. scrapling 업그레이드 — 관리자가 dev 브랜치에서 해당 옵션을 제거했으므로 0.4.15 이후 릴리스로 업데이트하세요: pip install -U scrapling
2. 임시 해결 방법 — lxml을 6 미만으로 고정: pip install "lxml<6"
3. 현재 버전을 유지해야 하는 경우 경고 억제: Selector를 생성하기 전에 warnings.filterwarnings("ignore", message=".*strip_cdata.*", category=DeprecationWarning)을 추가하세요.
문제 해결solve_cloudflare=True일 때 Scrapling StealthyFetcher의 fetch()가 timeout보다 훨씬 오래 걸리는 이유는 무엇인가요?
Scrapling 0.4.15에서는 Cloudflare Turnstile 솔버가 일부 챌린지 변형에서는 절대 일치하지 않는 위젯 로케이터를 기다리며, 재시도 루프에 상한이 없습니다. 따라서 fetch(..., timeout=15000) 호출이 74초 이상 실행될 수 있습니다(timeout 인자는 전체 fetch 데드라인이 아니라 개별 작업에 대한 제한입니다). 수정 사항 및 해결 방법:
1. **업그레이드**: 다음 릴리스를 위한 dev 브랜치에서 수정되었습니다. 누락된 위젯을 기다리는 대기가 제거되었고 솔버 재시도 루프에 상한이 적용되었습니다. dev 빌드를 설치하거나 릴리스 후 0.4.15 이후 버전으로 업그레이드하세요.
2. **세션 재사용**: cf_clearance 쿠키가 유지되므로 첫 번째 fetch만 솔버를 거칩니다. 측정 결과: 첫 페이지 약 8초, 이후 페이지당 약 3초.
3. **외부 wall clock**: 영향받는 버전에서는 timeout=만으로는 호출 시간을 제한할 수 없으므로, fetch를 별도의 워커 프로세스에서 실행하고 데드라인을 초과하는 프로세스는 강제 종료하세요.
이 호출은 여전히 상태 200과 올바른 콘텐츠를 반환하며 성공한다는 점에 유의하세요. 이는 실패가 아니라 순전히 지연 시간 문제입니다.
문제 해결Windows에서 관리자 권한으로 실행할 때 발생하는 StealthyFetcher TargetClosedError를 해결하는 방법은?
Windows에서 Python이 권한 승격(관리자) 상태로 실행되면, Scrapling의 추가 --disable-features 스위치가 patchright/Playwright의 목록을 대체하면서 AutoDeElevate가 누락됩니다. 이에 따라 Chromium이 권한이 낮아진 상태로 다시 시작된 후 종료되어 TargetClosedError: BrowserType.launch_persistent_context가 발생합니다. scrapling 0.4.15에 대한 해결 방법: 권한 해제 플래그를 명시적으로 전달하세요:
from scrapling.fetchers import StealthyFetcher
StealthyFetcher.fetch("https://example.com", headless=True, extra_flags=["--do-not-de-elevate"])
영구적인 해결 방법: dev 브랜치에서 disabled-features 목록이 병합되었으므로, 0.4.15 이후의 다음 릴리스로 업그레이드하세요. 또는 권한이 승격되지 않은 셸에서 스크립트를 실행하세요.
문제 해결ClawHub의 Scrapling 스킬 페이지가 비어 있거나 손상된 이유는 무엇인가요?
이는 일시적인 장애(openclaw/clawhub#2345)였으며 해결되었습니다. https://clawhub.ai/D4Vinci/scrapling-official 페이지는 현재 정상 작동 중입니다. 여전히 빈 페이지가 보인다면, 대체方案으로 agent-skill GitHub 디렉토리의 zip 파일을 사용해 보세요: https://github.com/D4Vinci/Scrapling/tree/main/agent-skill