Ada-Developers-Academy / classroom-app

Application for tracking and providing feedback on Ada student PRs
http://classroom.adadevelopersacademy.org/
2 stars 5 forks source link

Add count of submitted PRs to summary page #31

Open sudocrystal opened 7 years ago

sudocrystal commented 7 years ago

On this page http://classroom.adadevelopersacademy.org/pull_requests of the PR app, could there count be a count added after student submissions like (4 out of 24) or (all submitted) so it’s easy at a glance to see if anything is missing?

droberts-sea commented 7 years ago

To do this, we'll probably have to set up a webhook for the Ada-C7 organization, that sends us a notification every time a pull request is opened. That way we'll be able to track submissions as they happen.

If we don't do this, we'll have to request PR info from GitHub for every repo on the page. This already takes a while for a single repo, doing so for many would be close to unusable, especially for an overall summary page.

droberts-sea commented 7 years ago

I guess the main thing I'm worried about is making sure we didn't miss anything (if, say the app was down when a PR came in).

Maybe we do something like, when you go to the submissions page for a repo, we pull down the full list of PRs and treat it as authoritative, updating any out-of-date values in the DB.

sudocrystal commented 7 years ago

I don't know how everything works here, but would it be possible to have some kind of chron job that runs say, everyday at 2am, and updates the submission count for that page. And then at the top it just says something like "*PR submissions last updated _____"?

If this all is too much work, or slows down the page too much, I get that. It'd just make at a glance things a lot easier.