thepracticaldev / 1pr

I will be accepting up to one pull request per day on this project.
BSD 2-Clause "Simplified" License
145 stars 44 forks source link

Github Issues button in footer #38

Open frattaro opened 7 years ago

frattaro commented 7 years ago

Is the 'Issues' button count supposed to show Issues + Pull Requests? At least, that's what I think is showing.

DominicBisset commented 7 years ago

I looked into it but there isn't a quick fix.

It's a quirk with the underlying GitHub API - historically there was less of a difference between an issue and a PR so they share the same underlying framework and get included in the same summary count on the reposendpoint. There is no readily available alternative to pipe into the button control. You can determine which are pull requests and which are issues by looking at the the issues endpoint but can only get a count by loading all of the data. That data is paginated, limited to 30 entries per page, so we'd probably hit a rate limiter once the project hits some level of scale.

Even if we go down this route we'd then have to re-implement the button controls to handle our custom API since they are quite tailored towards the GitHub API.

DominicBisset commented 7 years ago

This was solved by @woubuc as part of PR #43, though it did loose the links to the relevant pages.