Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

i have some error AttributeError: module 'collections' has no attribute 'Callable' #106

Open
Zibzeus opened this issue Oct 24, 2023 · 2 comments

Comments

@Zibzeus
Copy link

Zibzeus commented Oct 24, 2023

hi, can u help me to finish this problem sir ?

i give some error log in here :
Traceback (most recent call last):
File "/home/smartcapt/Downloads/KP/CloudFail/cloudfail.py", line 307, in
dnsdumpster(args.target)
File "/home/smartcapt/Downloads/KP/CloudFail/cloudfail.py", line 84, in dnsdumpster
res = DNSDumpsterAPI(False).search(target)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/home/smartcapt/Downloads/KP/CloudFail/DNSDumpsterAPI.py", line 71, in search
soup = BeautifulSoup(req.content, 'html.parser')
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/home/smartcapt/.local/lib/python3.11/site-packages/bs4/init.py", line 228, in init
self._feed()
File "/home/smartcapt/.local/lib/python3.11/site-packages/bs4/init.py", line 289, in _feed
self.builder.feed(self.markup)
File "/home/smartcapt/.local/lib/python3.11/site-packages/bs4/builder/_htmlparser.py", line 215, in feed
parser.feed(markup)
File "/usr/lib/python3.11/html/parser.py", line 110, in feed
self.goahead(0)
File "/usr/lib/python3.11/html/parser.py", line 178, in goahead
k = self.parse_html_declaration(i)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/lib/python3.11/html/parser.py", line 269, in parse_html_declaration
self.handle_decl(rawdata[i+2:gtpos])
File "/home/smartcapt/.local/lib/python3.11/site-packages/bs4/builder/_htmlparser.py", line 160, in handle_decl
self.soup.endData(Doctype)
File "/home/smartcapt/.local/lib/python3.11/site-packages/bs4/init.py", line 365, in endData
self.object_was_parsed(o)
File "/home/smartcapt/.local/lib/python3.11/site-packages/bs4/init.py", line 370, in object_was_parsed
previous_element = most_recent_element or self._most_recent_element
^^^^^^^^^^^^^^^^^^^^^^^^^
File "/home/smartcapt/.local/lib/python3.11/site-packages/bs4/element.py", line 1054, in getattr
return self.find(tag)
^^^^^^^^^^^^^^
File "/home/smartcapt/.local/lib/python3.11/site-packages/bs4/element.py", line 1292, in find
l = self.find_all(name, attrs, recursive, text, 1, **kwargs)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/home/smartcapt/.local/lib/python3.11/site-packages/bs4/element.py", line 1313, in find_all
return self._find_all(name, attrs, text, limit, generator, **kwargs)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/home/smartcapt/.local/lib/python3.11/site-packages/bs4/element.py", line 528, in _find_all
strainer = SoupStrainer(name, attrs, text, **kwargs)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/home/smartcapt/.local/lib/python3.11/site-packages/bs4/element.py", line 1610, in init
self.text = self._normalize_search_value(text)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/home/smartcapt/.local/lib/python3.11/site-packages/bs4/element.py", line 1615, in _normalize_search_value
if (isinstance(value, str) or isinstance(value, collections.Callable) or hasattr(value, 'match')
^^^^^^^^^^^^^^^^^^^^
AttributeError: module 'collections' has no attribute 'Callable'

@xhat007
Copy link

xhat007 commented Nov 9, 2023

Please ensure that you are using Python version 3.9 or 3.8 for this project, as versions 3.10 and 3.11 are not supported.

@Remi-Avec-Un-I
Copy link

Add :
import collections
collections.Callable = collections.abc.Callable
in the beginning of cloudfail.py

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants