unicorn-fail / dreditor.org

Dreditor Browser Extension Site
https://dreditor.org
GNU General Public License v2.0
0 stars 1 forks source link

Merging causes all PRs to appear as "Rebase needed" #6

Open markhalliwell opened 10 years ago

markhalliwell commented 10 years ago

rebase

Current code is using the mergeable value provided in the PR JSON: https://github.com/dreditor/dreditor.org/blob/7.x/sites/all/modules/custom/dreditor_org/dreditor_org.pages.inc#L62

https://github.com/dreditor/dreditor.org/blob/7.x/sites/all/modules/custom/dreditor_org/dreditor_org.pages.inc#L88-L94

This is fine, but we need to add an AJAX mechanism that checks the status of each PR until it's either mergeable or the latest (top) status returned by travis-ci is success: https://api.github.com/repos/dreditor/dreditor/statuses/283c7caaefeea05993a8058519c3942952164f15

markhalliwell commented 10 years ago

A temporary solution is to remove the dreditor_org_pull_requests entry in the {cache} table and force it to rebuild pull the PRs from GH's API (after the tests have finished re-checking everything).