Skip to content

Commit 20501cf

Browse files
authored
Merge pull request #175 from adafruit/good_first_issues
Now outputs the number of good first issues
2 parents 2180ee8 + 1ac1492 commit 20501cf

File tree

3 files changed

+7
-0
lines changed

3 files changed

+7
-0
lines changed

adabot/circuitpython_libraries.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -225,6 +225,7 @@ def run_library_checks(validators, bundle_submodules, latest_pylint, kw_args):
225225
print_issue_overview(lib_insights)
226226
output_handler("* https://circuitpython.org/contributing")
227227
output_handler(" * {} open issues".format(len(lib_insights["open_issues"])))
228+
output_handler(" * {} good first issues".format(lib_insights["good_first_issues"]))
228229
open_pr_days = [
229230
int(pr_sort_re.search(pr).group(1)) for pr in lib_insights["open_prs"]
230231
if pr_sort_re.search(pr) is not None

adabot/lib/circuitpython_library_validators.py

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -909,6 +909,7 @@ def gather_insights(self, repo, insights, since, show_closed_metric=False):
909909
insights["new_issues"] += 1
910910
insights["issue_authors"].add(issue_info["user"]["login"])
911911
insights["active_issues"] += 1
912+
912913
else:
913914
insights["closed_issues"] += 1
914915
insights["issue_closers"].add(issue_info["closed_by"]["login"])
@@ -954,6 +955,10 @@ def gather_insights(self, repo, insights, since, show_closed_metric=False):
954955
issue_link = "{0} (Open {1} days)".format(issue["html_url"],
955956
days_open.days)
956957
insights["open_issues"].append(issue_link)
958+
if "labels" in issue:
959+
for i in issue["labels"]:
960+
if i["name"] == 'good first issue':
961+
insights["good_first_issues"] += 1
957962

958963
# process Hacktoberfest labels if it is Hacktoberfest season
959964
in_season, season_action = hacktober.is_hacktober_season()

adabot/lib/common_funcs.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -297,6 +297,7 @@ def __init__(self):
297297
"new_issues": 0,
298298
"active_issues": 0,
299299
"open_issues": [],
300+
"good_first_issues": 0,
300301
"issue_authors": set(),
301302
"issue_closers": set(),
302303
"hacktober_assigned": 0,

0 commit comments

Comments
 (0)