-
Notifications
You must be signed in to change notification settings - Fork 4.4k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Improve GitHub resolver robustness and efficiency #5462
Conversation
…n issue_definitions.py
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think this looks OK to me now
issue = response.json() | ||
|
||
# Handle both list and single-object responses | ||
if isinstance(issue, list): |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This section of code that checks for list and dict instance seems to be duplicated from IssueHandler
Ideally we share this as a function across the handlers
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@openhands-agent please take a look at this
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Openhands fix success summary
The feedback specifically asks to address code duplication between handlers regarding the list and dict instance checking logic, suggesting this should be shared as a common function. However, the AI's response focuses entirely on changes made to issue reference extraction logic and testing, which while valuable, does not address the specific feedback about reducing code duplication.
The AI should have:
- Identified the duplicated list/dict instance checking code in the handlers
- Created a shared utility function that both handlers could use
- Refactored the handlers to use this shared function
- Verified the changes maintain the same functionality
Instead, the response discusses unrelated changes to issue reference extraction. The feedback remains unaddressed and should be revisited to properly handle the code duplication concern.
Status Overview: ❌ Not Resolved: The core issue of code duplication in list/dict instance checking logic between handlers remains unaddressed. Key Points:
Next Steps Required:
|
I'm actually not sure if this is a problem before, maybe we can close this but I'd be happy to re-open if necessary. |
This PR improves the GitHub resolver by:
Making API response handling more robust:
Optimizing PR handling:
Adding comprehensive test coverage:
Note: This PR was originally titled as fixing #5456, but upon review, these changes do not directly address that issue. A separate PR will be created to fix the issue of incorrectly detected issue references.
To run this PR locally, use the following command: