GithubHelp home page GithubHelp logo

Comments (3)

PallasMedia avatar PallasMedia commented on August 26, 2024

I've been following this project for a a while. How many requests do you expect the bot will be making against the GitHub API to do this? According to the GitHub API

"For requests using Basic Authentication or OAuth, you can make up to 5,000 requests per hour. For unauthenticated requests, the rate limit allows you to make up to 60 requests per hour. Unauthenticated requests are associated with your IP address, and not the user making requests."

I haven't delved deep into the code yet but unless unless you're merging 20-30 PRs a day (non authenticated requests) I don't see how you'd exceed the rate limit.

from bot.

megawac avatar megawac commented on August 26, 2024

There are a couple things to consider:

  • The bot can perform multiple requests per pull request (based on the number of commits, comments, and files). These resources are paginated so we have to perform n/page size requests for each pull request. We then read several files (1 request each)
  • We revalidate pull requests whenever a new commit is added
  • we preform multiple other requests per validation (refresh repo state, get issue, check if user is collab, set pr status (twice), couple other things
  • We preform some meta checks if info.ini lists a github repository (we check repo exists and look at its tagged released)

This can end up taking a large number of requests on some pull requests.

We also share are oauth login with libgrabber which eats a ton of our request quota; this can obviously be addressed by creating a new github account for bot.

Anyway all that said, we haven't hit the quota often but it can happen; adding a step which checks multiple prs on an interval could be suspect in our current configuration

from bot.

megawac avatar megawac commented on August 26, 2024

Mostly fixed in f96af09 though this still requires a bit more tuning

from bot.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.