[Bug]: css_selector can only select the first class in the page
crawl4ai version
Version: 0.5.0.post8
Expected Behavior
CSS Selector Example
async def simple_example_with_css_selector(): print("\n--- Using CSS Selectors ---") browser_config = BrowserConfig(headless=True) crawler_config = CrawlerRunConfig( cache_mode=CacheMode.BYPASS, css_selector="li.CommitRow-module__ListItem_0--PkFAi h4" )
async with AsyncWebCrawler(config=browser_config) as crawler:
result = await crawler.arun(
url="https://github.com/microsoft/TypeScript/commits/main", config=crawler_config
)
print("Partial HTML length:", len(result.cleaned_html))
this code can only result in the first commit, there 35 commits in the page
Current Behavior
CSS Selector Example
async def simple_example_with_css_selector(): print("\n--- Using CSS Selectors ---") browser_config = BrowserConfig(headless=True) crawler_config = CrawlerRunConfig( cache_mode=CacheMode.BYPASS, css_selector="li.CommitRow-module__ListItem_0--PkFAi h4" )
async with AsyncWebCrawler(config=browser_config) as crawler:
result = await crawler.arun(
url="https://github.com/microsoft/TypeScript/commits/main", config=crawler_config
)
print("Partial HTML length:", len(result.cleaned_html))
can only receive the first commit, there 35 commits in the page
Is this reproducible?
Yes
Inputs Causing the Bug
Steps to Reproduce
Code snippets
OS
Linux Ubuntu 24.04
Python version
3.12
Browser
No response
Browser version
No response
Error logs & Screenshots (if applicable)
No response
update to version Version: 0.6.2 then the issue is gone... no bother then, thanks in advance.