The first Python man in Github

Source: Internet
Author: User

Checked out the most star Python man on GitHub today.

Maybe that's the goal.

Import Requestsurl = ' Https://api.github.com/search/repositories?q=language:python&sort=stars ' def json_get (url ): Try:r = requests.get (URL) r.raise_for_status () Except:prin T (' 404 ') else:r.encoding = r.apparent_encoding return R.json () response_dict = Json_g ET (URL) print ("Total repositories:", response_dict[' Total_count ')) #探索有关仓库信息repo_dicts = response_dict[' Items ']print ("Repositories returned:", Len (repo_dicts)) #研究第一个仓库repo_dict = Repo_dicts[0]print ("\nselected information about first Repository ") Print (" Name: ", repo_dict[' name ']) print (" Owner: ", repo_dict[' owner ' [' Login ']) print (" Stars: ", Repo_ dict[' Stargazers_count ') print ("Repository:", repo_dict[' Html_url ']) print ("CREATD:", repo_dict[' Created_at ')) Print ("Downloads:", repo_dict[' Downloads_url ')) print ("Updated:", repo_dict[' Updated_at ')) print ("Description:", repo_dict[' description ') print ("Watchers num:", repo_dict[' Watchers_count '])

The first Python man in Github

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.