GH#4097: Make partial results explicit in contributor-activity-helper.sh#4108
Conversation
When person_stats() hits GitHub Search API rate limits mid-run, it now: - Returns exit code 75 (EX_TEMPFAIL) instead of 0, so callers like pulse-wrapper.sh can distinguish complete from truncated results - Emits <!-- partial-results --> HTML comment in markdown output for machine-readable detection by callers that suppress stderr - JSON output already had "partial": true (unchanged) cross_repo_person_stats() now: - Handles EX_PARTIAL from sub-calls and propagates the flag - Correctly extracts .data array from person_stats JSON wrapper - Includes partial flag in both JSON and markdown output Addresses CodeRabbit review feedback from PR #4094.
Summary of ChangesHello, 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 Highlights
Changelog
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
|
|
Caution Review failedPull request was closed or merged during review WalkthroughThe PR implements explicit partial-result handling in the contributor-activity-helper.sh script by introducing a distinct exit code (EX_PARTIAL=75), emitting partial indicators in JSON and markdown outputs, and propagating partial-result state through per-repo and cross-repo aggregation functions to prevent callers from treating rate-limited data as complete. Changes
Estimated code review effort🎯 3 (Moderate) | ⏱️ ~20 minutes Possibly related PRs
Suggested labels
Poem
🚥 Pre-merge checks | ✅ 5✅ Passed checks (5 passed)
✏️ Tip: You can configure your own custom pre-merge checks in the settings. ✨ Finishing Touches
🧪 Generate unit tests (beta)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
🔍 Code Quality Report�[0;35m[MONITOR]�[0m Code Review Monitoring Report �[0;34m[INFO]�[0m Latest Quality Status: �[0;34m[INFO]�[0m Recent monitoring activity: 📈 Current Quality Metrics
Generated on: Wed Mar 11 02:26:23 UTC 2026 Generated by AI DevOps Framework Code Review Monitoring |
|
There was a problem hiding this comment.
Code Review
This pull request introduces a mechanism to explicitly handle partial results from the GitHub Search API when rate limits are encountered. The changes are well-implemented, adding a new exit code and updating both JSON and markdown outputs to indicate when results are incomplete. This improves the script's robustness and provides clearer feedback to its callers. The code is clean, well-documented, and I have no concerns with the proposed changes.
Note: Security Review did not run due to the size of the PR.



Summary
person_stats()hits GitHub Search API rate limits mid-run, it now returns exit code 75 (EX_TEMPFAIL) and emits<!-- partial-results -->HTML comment, so callers can distinguish complete from truncated resultscross_repo_person_stats()now handles EX_PARTIAL from sub-calls and propagates the flag in both JSON and markdown outputCloses #4097
Summary by CodeRabbit
New Features
Improvements