Skip to content

Instantly share code, notes, and snippets.

@hamiltont
Created April 3, 2015 23:33
Show Gist options
  • Save hamiltont/7fa5c3adc9e6728a68e0 to your computer and use it in GitHub Desktop.
Save hamiltont/7fa5c3adc9e6728a68e0 to your computer and use it in GitHub Desktop.
Count issues created or closed since FrameworkBenchmarks Round 9
from github import Github
from datetime import datetime
import time
# Visit https://github.com/settings/applications
# and issue a new "personal access token"
g = Github("<your own github token>")
round9 = datetime.strptime('2014-03-19 13:07:11', '%Y-%m-%d %H:%M:%S')
issues = g.get_repo('TechEmpower/FrameworkBenchmarks').get_issues(state='all')
created=0
closed=0
for issue in issues:
if issue.created_at >= round9:
print "Found issue : " + issue.title
print "State : " + issue.state
created = created + 1
if issue.state == "closed":
closed = closed + 1
time.sleep(0.5)
print "Created: " + str(created)
print "Closed : " + str(closed)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment