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
Github.search_topics returning list of repos that throw an error when trying to fetch undefined data #929
Comments
I will fix it later :p |
Maybe, wrong code is here. @jacquerie |
Uhm? I don't think I contributed code to any of this... |
Just glancing at the code. It appears that search_topics is returning a paginated list of GitHub repositories, but the API seems to return a list of topics, including the following properties:
I think this may be the root problem. |
Yes indeed, the API endpoint /search/topics returns a list of topics that are related to the provided keyword and not a list of repositories tagged with that topic (which is a little bit confusing, maybe ?). But still, the method in PyGithub should be fixed. |
PR welcome |
The return value of MainClass.search_topics() was a paginated list of Repository, which is incorrect. Add a Topic class to encapuslate what is returned. Fixes PyGithub#929
The return value of MainClass.search_topics() was a paginated list of Repository, which is incorrect. Add a Topic class to encapuslate what is returned. Fixes #929
The return value of MainClass.search_topics() was a paginated list of Repository, which is incorrect. Add a Topic class to encapuslate what is returned. Fixes PyGithub#929
Hello,
I was trying to fetch a list of repositories with a specific topic and then play with the returned attributes, but the Repository objects returned in the PaginatedList throw an error when trying to fetch unknown data:
Below is an example of the code:
It can be tested here: https://repl.it/repls/LawngreenPlushBetaversion
Environment:
Linux ubuntu 4.15.0-36-generic x86_64 GNU/Linux
Python 3.6.6
PyGithub 1.43.2
Any help with that ?
And thanks
The text was updated successfully, but these errors were encountered: