PR status only take the first check into account
Nobody has claimed this yet.
Assessment
- Difficulty
- 2/5
- Estimated time
- 1-3 hours
- Newbie friendliness
- 72/100
- Issue type
- Bug
- Clarity
- Mostly clear
- Activity status
- Quiet
- Tech stack
- javascript
- Domain
- frontend
Research direction
Start in trac-env/htdocs/tickethacks.js around line 124, where the pull request status is determined from the checks. Review how all check statuses are represented, then update the aggregation so building takes precedence, errors are reported when present, and success requires every check to succeed. Confirm the displayed Trac status against pull requests with multiple checks.
Written by the indexing model from the issue text.
Description
I was confused today because my PR was marked as "build: success" on Trac, but it had fail on github.
Investigating the issue, I discovered that the javascript that figures out the status of a PR only takes the first check into account: https://github.com/django/code.djangoproject.com/blob/a8774abd91108baa70eb936c5ad5a736dd646b5b/trac-env/htdocs/tickethacks.js#L124
Considering we have around 50 checks, I don't think this logic is accurate.
I would suggest that the status should be "building" if any individual check has status=building, "error" if at least one check has status=error, and "success" only if all checks have status=success (not sure if there are other statues to take into account)
- Dominant language
- Python
- Stars
- 66
- Forks
- 62
- PR merge metrics
- No merged PRs in 30d
Contributor guide
No contributing guide indexed for this repository
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
More from django/code.djangoproject.com
-
Difficulty 3/5 1-2 days Newbie friendliness 55/100
django/code.djangoproject.com#310 ·
-
Difficulty 4/5 3-5 days Newbie friendliness 48/100
django/code.djangoproject.com#308 · 3 comments ·
-
Difficulty 4/5 3-5 days Newbie friendliness 48/100
django/code.djangoproject.com#303 · 1 comment · 4 reactions ·
-
Difficulty 5/5 Over a week Newbie friendliness 35/100
django/code.djangoproject.com#297 ·
-
Difficulty 4/5 3-5 days Newbie friendliness 48/100
django/code.djangoproject.com#293 ·
All issues in django/code.djangoproject.com
Similar issues
-
Difficulty 2/5 1-3 hours Newbie friendliness 88/100
-
Difficulty 2/5 1-3 hours Newbie friendliness 82/100
-
Difficulty 2/5 1-3 hours Newbie friendliness 78/100
-
enhancement
Difficulty 2/5 1-3 hours Newbie friendliness 72/100
-
Difficulty 2/5 1-3 hours Newbie friendliness 74/100