-
Notifications
You must be signed in to change notification settings - Fork 1.2k
Handle /similar_issue on non-GitHub providers #2158
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
base: main
Are you sure you want to change the base?
Handle /similar_issue on non-GitHub providers #2158
Conversation
PR Compliance Guide 🔍Below is a summary of compliance checks for this PR:
Compliance status legend🟢 - Fully Compliant🟡 - Partial Compliant 🔴 - Not Compliant ⚪ - Requires Further Human Verification 🏷️ - Compliance label |
||||||||||||||||||||||
PR Code Suggestions ✨Explore these optional code suggestions:
|
|||||||||||||||
User description
Summary
Testing
PR Type
Bug fix, Tests
Description
Replace exception with graceful handling for non-GitHub providers
Publish friendly message when /similar_issue invoked outside GitHub
Add comprehensive unit tests for non-GitHub behavior
Diagram Walkthrough
flowchart LR A["Non-GitHub Provider Detected"] --> B["Set supported flag to false"] B --> C["Return early from run method"] C --> D{publish_output enabled?} D -->|Yes| E["Publish friendly message"] D -->|No| F["Return empty string"] E --> FFile Walkthrough
pr_similar_issue.py
Graceful non-GitHub provider handling with messagingpr_agent/tools/pr_similar_issue.py
providers
supportedflag to track GitHub availability__init__for unsupported providersrun()method when providerunsupported
publish_outputis enabledtest_similar_issue_non_github.py
Unit tests for non-GitHub provider behaviortests/unittest/test_similar_issue_non_github.py
publish_outputis enabledpublish_outputis disabled