Skip to content

Commit b4e2249

Browse files
committed
fix options
1 parent 5e8a70d commit b4e2249

File tree

4 files changed

+5
-23
lines changed

4 files changed

+5
-23
lines changed

src/sentry/api/serializers/models/organization.py

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -542,7 +542,6 @@ class DetailedOrganizationSerializerResponse(_DetailedOrganizationSerializerResp
542542
githubPRBot: bool
543543
githubNudgeInvite: bool
544544
gitlabPRBot: bool
545-
gitlabOpenPRBot: bool
546545
aggregatedDataConsent: bool
547546
genAIConsent: bool
548547
isDynamicallySampled: bool
@@ -665,9 +664,6 @@ def serialize( # type: ignore[override]
665664
obj.get_option("sentry:github_nudge_invite", GITHUB_COMMENT_BOT_DEFAULT)
666665
),
667666
"gitlabPRBot": bool(obj.get_option("sentry:gitlab_pr_bot", GITLAB_COMMENT_BOT_DEFAULT)),
668-
"gitlabOpenPRBot": bool(
669-
obj.get_option("sentry:gitlab_open_pr_bot", GITLAB_COMMENT_BOT_DEFAULT)
670-
),
671667
"genAIConsent": bool(
672668
obj.get_option("sentry:gen_ai_consent_v2024_11_14", DATA_CONSENT_DEFAULT)
673669
),

src/sentry/apidocs/examples/organization_examples.py

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -290,10 +290,9 @@ class OrganizationExamples:
290290
"relayPiiConfig": None,
291291
"codecovAccess": False,
292292
"hideAiFeatures": False,
293-
"githubPRBot": True,
293+
"githubPRBot": False,
294294
"githubNudgeInvite": True,
295-
"gitlabPRBot": True,
296-
"gitlabOpenPRBot": True,
295+
"gitlabPRBot": False,
297296
"aggregatedDataConsent": False,
298297
"defaultAutofixAutomationTuning": AutofixAutomationTuningSettings.OFF,
299298
"defaultSeerScannerAutomation": True,

src/sentry/core/endpoints/organization_details.py

Lines changed: 0 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -194,12 +194,6 @@
194194
bool,
195195
GITLAB_COMMENT_BOT_DEFAULT,
196196
),
197-
(
198-
"gitlabOpenPRBot",
199-
"sentry:gitlab_open_pr_bot",
200-
bool,
201-
GITLAB_COMMENT_BOT_DEFAULT,
202-
),
203197
(
204198
"issueAlertsThreadFlag",
205199
"sentry:issue_alerts_thread_flag",
@@ -307,7 +301,6 @@ class OrganizationSerializer(BaseOrganizationSerializer):
307301
githubNudgeInvite = serializers.BooleanField(required=False)
308302
githubPRBot = serializers.BooleanField(required=False)
309303
gitlabPRBot = serializers.BooleanField(required=False)
310-
gitlabOpenPRBot = serializers.BooleanField(required=False)
311304
issueAlertsThreadFlag = serializers.BooleanField(required=False)
312305
metricAlertsThreadFlag = serializers.BooleanField(required=False)
313306
require2FA = serializers.BooleanField(required=False)
@@ -894,10 +887,6 @@ class OrganizationDetailsPutSerializer(serializers.Serializer):
894887
help_text="Specify `true` to allow Sentry to comment on recent pull requests suspected of causing issues. Requires a GitLab integration.",
895888
required=False,
896889
)
897-
gitlabOpenPRBot = serializers.BooleanField(
898-
help_text="Specify `true` to allow Sentry to comment on open pull requests to show recent error issues for the code being changed. Requires a GitLab integration.",
899-
required=False,
900-
)
901890

902891
# slack features
903892
issueAlertsThreadFlag = serializers.BooleanField(

tests/sentry/core/endpoints/test_organization_details.py

Lines changed: 3 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -755,10 +755,9 @@ def test_various_options(self, mock_get_repositories: MagicMock) -> None:
755755
"allowSuperuserAccess": False,
756756
"allowMemberInvite": False,
757757
"hideAiFeatures": True,
758-
"githubNudgeInvite": False,
759-
"githubPRBot": False,
760-
"gitlabPRBot": False,
761-
"gitlabOpenPRBot": False,
758+
"githubNudgeInvite": True,
759+
"githubPRBot": True,
760+
"gitlabPRBot": True,
762761
"allowSharedIssues": False,
763762
"enhancedPrivacy": True,
764763
"dataScrubber": True,
@@ -851,7 +850,6 @@ def test_various_options(self, mock_get_repositories: MagicMock) -> None:
851850
assert "to {}".format(data["githubPRBot"]) in log.data["githubPRBot"]
852851
assert "to {}".format(data["githubNudgeInvite"]) in log.data["githubNudgeInvite"]
853852
assert "to {}".format(data["gitlabPRBot"]) in log.data["gitlabPRBot"]
854-
assert "to {}".format(data["gitlabOpenPRBot"]) in log.data["gitlabOpenPRBot"]
855853
assert "to {}".format(data["issueAlertsThreadFlag"]) in log.data["issueAlertsThreadFlag"]
856854
assert "to {}".format(data["metricAlertsThreadFlag"]) in log.data["metricAlertsThreadFlag"]
857855
assert "to Default Mode" in log.data["samplingMode"]

0 commit comments

Comments
 (0)