cfcrawler icon indicating copy to clipboard operation
cfcrawler copied to clipboard

AttributeError: module 'httpx._types' has no attribute 'VerifyTypes'

Open noob-4-life opened this issue 9 months ago • 1 comments

from cfcrawler import AsyncClient
Traceback (most recent call last):
  File "<python-input-0>", line 1, in <module>
    from cfcrawler import AsyncClient
  File "/Users/bob/cfcrawler-venv/lib/python3.13/site-packages/cfcrawler/__init__.py", line 1, in <module>
    from cfcrawler.client import AsyncClient
  File "/Users/bob/cfcrawler-venv/lib/python3.13/site-packages/cfcrawler/client.py", line 42, in <module>
    class AsyncClient(_AsyncClient):
    ...<84 lines>...
                return random.choice(get_all_ua_for_specific_browser(self.browser))
  File "/Users/bob/cfcrawler-venv/lib/python3.13/site-packages/cfcrawler/client.py", line 57, in AsyncClient
    verify: _types.VerifyTypes = False,
            ^^^^^^^^^^^^^^^^^^
AttributeError: module 'httpx._types' has no attribute 'VerifyTypes'. Did you mean: 'ProxyTypes'?

cfcrawler was installed with with pip instead of poetry as our project does not use the latter.

pip install cfcrawler

This is happening because pip installs the latest version of httpx, and _types.VerifyTypes was removed in version 0.28.0 (as was _types.ProxiesTypes).

noob-4-life avatar Apr 05 '25 16:04 noob-4-life

same problem here, need a fix!

gillbates avatar Aug 20 '25 07:08 gillbates