-
-
Notifications
You must be signed in to change notification settings - Fork 4.4k
[ft] Add an org seer toggle for PR review and test gen in Seer #95547
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
[ft] Add an org seer toggle for PR review and test gen in Seer #95547
Conversation
…nnakota/test-gen-pr-review-toggle
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.
help: tct( | ||
'Use AI to generate feedback and tests in pull requests [link:Learn more]', | ||
{ | ||
link: <ExternalLink href="https://github.com/apps/seer-by-sentry/" />, | ||
} |
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.
would a link to docs be more appropriate?
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 agree
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.
Updated
Codecov ReportAll modified and coverable lines are covered by tests ✅ ✅ All tests successful. No failed tests found. Additional details and impacted files@@ Coverage Diff @@
## master #95547 +/- ##
===========================================
- Coverage 87.73% 77.28% -10.45%
===========================================
Files 10548 10546 -2
Lines 607769 607667 -102
Branches 23817 23817
===========================================
- Hits 533215 469664 -63551
- Misses 74258 137707 +63449
Partials 296 296 |
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.
Bug: AI Feature Toggle Logic Inverted
The visible
callback for the new enablePrReviewTestGeneration
field returns hideAiFeatures
directly. This inverts the intended logic: the field is displayed when AI features are hidden and hidden when they are enabled. Consequently, users cannot enable the "Enable PR Review and Test Generation" toggle when AI features are active. The callback should return !hideAiFeatures
.
static/app/data/forms/organizationGeneralSettings.tsx#L47-L66
sentry/static/app/data/forms/organizationGeneralSettings.tsx
Lines 47 to 66 in 4aad704
{ | |
name: 'enablePrReviewTestGeneration', | |
type: 'boolean', | |
label: tct('Enable PR Review and Test Generation [badge]', { | |
badge: <FeatureBadge type="beta" style={{marginBottom: '2px'}} />, | |
}), | |
help: tct( | |
'Use AI to generate feedback and tests in pull requests [link:Learn more]', | |
{ | |
link: ( | |
<ExternalLink href="https://docs.sentry.io/product/ai-in-sentry/sentry-prevent-ai/" /> | |
), | |
} | |
), | |
visible: ({model}) => { | |
// Show field when AI features are enabled (hideAiFeatures is false) | |
const hideAiFeatures = model.getValue('hideAiFeatures'); | |
return hideAiFeatures; | |
}, | |
}, |
Was this report helpful? Give feedback by reacting with 👍 or 👎
visible: ({model}) => { | ||
// Show field when AI features are enabled (hideAiFeatures is false) | ||
const hideAiFeatures = model.getValue('hideAiFeatures'); | ||
return hideAiFeatures; |
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 is backwards?
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.
It's very confusing. The logic was inverted at some point, you can test on the UI
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 we need to change the variable name, but it touches a lot of other areas as well
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.
sentry/static/app/views/settings/organizationGeneralSettings/aiFeatureSettings.tsx
Line 30 in 0b995e8
return !value; |
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.
ack ok
<!-- Describe your PR here. --> Is consumed by `seer_rpc` while communicating with Seer. This PR must be merged AFTER #95456 is deployed. <img width="1011" height="558" alt="Screenshot 2025-07-14 at 1 06 24 PM" src="https://github.com/user-attachments/assets/0822e352-0a04-473d-b477-57ef3e3a8e3f" /> <!-- Sentry employees and contractors can delete or ignore the following. --> ### Legal Boilerplate Look, I get it. The entity doing business as "Sentry" was incorporated in the State of Delaware in 2015 as Functional Software, Inc. and is gonna need some rights from me in order to utilize my contributions in this here PR. So here's the deal: I retain all rights, title and interest in and to my contributions, and by keeping this boilerplate intact I confirm that Sentry can use, modify, copy, and redistribute my contributions, under Sentry's choice of terms.
<!-- Describe your PR here. --> Is consumed by `seer_rpc` while communicating with Seer. This PR must be merged AFTER #95456 is deployed. <img width="1011" height="558" alt="Screenshot 2025-07-14 at 1 06 24 PM" src="https://github.com/user-attachments/assets/0822e352-0a04-473d-b477-57ef3e3a8e3f" /> <!-- Sentry employees and contractors can delete or ignore the following. --> ### Legal Boilerplate Look, I get it. The entity doing business as "Sentry" was incorporated in the State of Delaware in 2015 as Functional Software, Inc. and is gonna need some rights from me in order to utilize my contributions in this here PR. So here's the deal: I retain all rights, title and interest in and to my contributions, and by keeping this boilerplate intact I confirm that Sentry can use, modify, copy, and redistribute my contributions, under Sentry's choice of terms.
Is consumed by
seer_rpc
while communicating with Seer. This PR must be merged AFTER #95456 is deployed.Legal Boilerplate
Look, I get it. The entity doing business as "Sentry" was incorporated in the State of Delaware in 2015 as Functional Software, Inc. and is gonna need some rights from me in order to utilize my contributions in this here PR. So here's the deal: I retain all rights, title and interest in and to my contributions, and by keeping this boilerplate intact I confirm that Sentry can use, modify, copy, and redistribute my contributions, under Sentry's choice of terms.