Add is_rate_limit_low method#970
Add is_rate_limit_low method#970centosinfra-prod-github-app[bot] merged 1 commit intopackit:mainfrom
Conversation
Summary of ChangesHello @majamassarini, I'm Gemini Code Assist1! I'm currently reviewing this pull request and will post my feedback shortly. In the meantime, here's a summary to help you and other reviewers quickly get up to speed! This pull request enhances the Service API by introducing a new method, Highlights
🧠 New Feature in Public Preview: You can now enable Memory to help Gemini Code Assist learn from your team's feedback. This makes future code reviews more consistent and personalized to your project's style. Click here to enable Memory in your admin console. Using Gemini Code AssistThe full guide for Gemini Code Assist can be found on our documentation page, here are some quick tips. Invoking Gemini You can request assistance from Gemini at any point by creating a comment using either
Customization To customize Gemini Code Assist for GitHub experience, repository maintainers can create a configuration file and/or provide a custom code review style guide (such as PEP-8 for Python) by creating and adding files to a Limitations & Feedback Gemini Code Assist may make mistakes. Please leave feedback on any instances where its feedback is incorrect or counter productive. You can react with 👍 and 👎 on @gemini-code-assist comments. If you're interested in giving your feedback about your experience with Gemini Code Assist for Github and other Google products, sign up here. You can also get AI-powered code generation, chat, as well as code reviews directly in the IDE at no cost with the Gemini Code Assist IDE Extension. Footnotes
|
There was a problem hiding this comment.
Code Review
This pull request introduces a new method, is_rate_limit_low, to the GitService abstract class and provides implementations for GitHub, GitLab, and Pagure. This is a useful addition for clients of this library to proactively handle API rate limiting. The changes are well-implemented and include corresponding tests. My main feedback is on the GitLab implementation, where the exception handling can be improved to be more specific and to include logging, which will make the code more robust and easier to debug.
|
❌ pre-commit FAILURE in 3m 33s |
14b5932 to
601cfc4
Compare
|
❌ pre-commit FAILURE in 3m 25s |
lbarcziova
left a comment
There was a problem hiding this comment.
one question about design, otherwise this looks like a good direction!
| Returns: | ||
| True if the rate limit remaining is less than 100, False otherwise. |
There was a problem hiding this comment.
what do you think about having the method in ogr to just return the number of remaining API calls, and we would check/control based on that the behaviour on packit-service?
601cfc4 to
15dcb4a
Compare
15dcb4a to
0ecfd41
Compare
|
❌ pre-commit FAILURE in 4m 13s |
0ecfd41 to
62fbfc3
Compare
62fbfc3 to
456b7c4
Compare
b8cc427 to
c41b01b
Compare
c41b01b to
8658472
Compare
|
❌ pre-commit FAILURE in 4m 08s |
5ef359e to
59a0f78
Compare
|
Build succeeded. ✔️ pre-commit SUCCESS in 3m 26s |
c86b868 to
39c96b1
Compare
39c96b1 to
8d94096
Compare
|
Build succeeded. ✔️ pre-commit SUCCESS in 3m 25s |
Co-authored-by: Nikola Forró <nforro@redhat.com>
8d94096 to
fec79e6
Compare
|
Build succeeded. ✔️ pre-commit SUCCESS in 3m 27s |
|
Build succeeded (gate pipeline). ✔️ pre-commit SUCCESS in 3m 31s |
f15b4bc
into
packit:main
RELEASE NOTES BEGIN
Calls to check the rate limit threshold have been added to the Service API and implemented where possible.
RELEASE NOTES END