-
-
Notifications
You must be signed in to change notification settings - Fork 4.2k
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
feat(data-consent): Add region check to data consent option #68315
Conversation
Bundle ReportChanges will decrease total bundle size by 719 bytes ⬇️
|
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.
🚢 🇮🇹
if not request.access.has_scope("org:billing"): | ||
raise serializers.ValidationError("You do not have permission to change this option") | ||
|
||
if get_local_region().name != "us": |
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.
Beyond scope of this PR, but we probably should make region IDs into some kind of StrEnum or something like that, so it would use RegionEnum.US
instead of "us"
.
@@ -326,6 +327,23 @@ def validate_projectRateLimit(self, value): | |||
) | |||
return value | |||
|
|||
def validate_aggregatedDataConsent(self, 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.
style nit: what's with the camel-case?
🐍
This is a temporary fix to disable AI suggested solution in the DE region. A separate PR will update organization settings to disable the option for regions which do not support AI suggested solution. This will all be eventually replaced with Autofix. We'll incorporate AI suggested solution into the same changes we're making in #68315
This is a temporary fix to disable AI suggested solution in the DE region. A separate PR will update organization settings to disable the option for regions which do not support AI suggested solution. This will all be eventually replaced with Autofix. We'll incorporate AI suggested solution into the same changes we're making in #68315
This pull request has gone three weeks without activity. In another week, I will close it. But! If you comment or otherwise update it, I will reset the clock, and if you add the label "A weed is but an unloved flower." ― Ella Wheeler Wilcox 🥀 |
this pr adds a check for the region, since the genAIConsent option is limited to those organizations in the US region