fix: fixing the handling of historyLength being set to 0 by default in gRPC.#436
Conversation
Summary of ChangesHello @ehsavoie, 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 addresses an issue where the Highlights
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 correctly refactors the handling of historyLength from a nullable Integer to a primitive int, with a default value of 0. This change is consistently applied across the codebase, including the TaskQueryParams record, gRPC and REST transports, and associated handlers and tests. The new logic, where historyLength = 0 signifies a request for the full task history, is correctly implemented in DefaultRequestHandler. I've added one comment to fix a pre-existing bug in the history truncation logic that is closely related to the changes in this PR. Overall, this is a good fix that improves clarity and correctness.
|
@gemini-code-assist review |
|
@ehsavoie, thanks for tagging me! I've completed a detailed review of your pull request. Overall, the changes are well-implemented and align perfectly with the stated objective of handling Here's a breakdown of my observations: General Feedback
Detailed Review Comments
|
bbaa944 to
865d6a1
Compare
| * Unit tests for DefaultRequestHandler using Mockito. | ||
| * These tests focus on individual methods and edge cases, particularly the history truncation logic. | ||
| */ | ||
| public class DefaultRequestHandlerTestCase { |
There was a problem hiding this comment.
Can you find another name, we already have DefaultRequestHandlerTest so it overlaps a bit
…n gRPC. * Using int instead of Integer and setting the default value to 0. * If historyLength == 0 then we should return the full history * Removing the handling of null * Adding more tests Issue: a2aproject#423 Signed-off-by: Emmanuel Hugonnet <ehugonne@redhat.com>
865d6a1 to
0575c42
Compare
Issue: #423
Fixes #423 🦕