Closed Doujinx closed 9 months ago
Thanks for the report. Maybe its not working with python 3.11. I'll check it sometime coming weekend and see if I can get a fix out.
Hi There,
I have also faced the same problem. This seems like an issue with latest python version and code of github3 package. I have python3.10 installed.
so the solution is to change 2 files:
one is '~/.local/lib/python3.10/site-packages/github3/session.py' and
other one is ~/.local/lib/python3.10/site-packages/github3/structs.py
in session.py file search & replace from collections import Callable
with from collections.abc import Callable
and in structs.py file search & replace class GitHubIterator(models.GitHubCore, collections.Iterator):
with class GitHubIterator(models.GitHubCore, collections.abc.Iterator):
I hope this helps.
$ python3 github-dork.py -r https://github.com/techgaun/github-dorks Traceback (most recent call last): File "/home/kali/Programs/github-dorks/github-dork.py", line 4, in import github3 as github File "/home/kali/.local/lib/python3.11/site-packages/github3/init.py", line 18, in from .api import ( File "/home/kali/.local/lib/python3.11/site-packages/github3/api.py", line 11, in from .github import GitHub, GitHubEnterprise File "/home/kali/.local/lib/python3.11/site-packages/github3/github.py", line 13, in from .auths import Authorization File "/home/kali/.local/lib/python3.11/site-packages/github3/auths.py", line 12, in from .models import GitHubCore File "/home/kali/.local/lib/python3.11/site-packages/github3/models.py", line 19, in from .session import GitHubSession File "/home/kali/.local/lib/python3.11/site-packages/github3/session.py", line 4, in from collections import Callable ImportError: cannot import name 'Callable' from 'collections' (/usr/lib/python3.11/collections/init.py)
Can you help me with that ?
Hi
try to update the lib:
pip3 install --upgrade github3.py
@techgaun this issue should be able to be closed now that #58 is merged.
Thanks closing as fixed by #58
$ python3 github-dork.py -r https://github.com/techgaun/github-dorks Traceback (most recent call last): File "/home/kali/Programs/github-dorks/github-dork.py", line 4, in
import github3 as github
File "/home/kali/.local/lib/python3.11/site-packages/github3/init.py", line 18, in
from .api import (
File "/home/kali/.local/lib/python3.11/site-packages/github3/api.py", line 11, in
from .github import GitHub, GitHubEnterprise
File "/home/kali/.local/lib/python3.11/site-packages/github3/github.py", line 13, in
from .auths import Authorization
File "/home/kali/.local/lib/python3.11/site-packages/github3/auths.py", line 12, in
from .models import GitHubCore
File "/home/kali/.local/lib/python3.11/site-packages/github3/models.py", line 19, in
from .session import GitHubSession
File "/home/kali/.local/lib/python3.11/site-packages/github3/session.py", line 4, in
from collections import Callable
ImportError: cannot import name 'Callable' from 'collections' (/usr/lib/python3.11/collections/init.py)
Can you help me with that ?