-
Notifications
You must be signed in to change notification settings - Fork 273
feat(amazonq): add q config to lsp/configuration #5520
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
Conversation
| const val LSP_Q_CONFIGURATION_KEY = "aws.q" | ||
| const val LSP_OPT_OUT_TELEMETRY_CONFIGURATION_KEY = "optOutTelemetry" | ||
| const val LSP_ENABLE_TELEMETRY_EVENTS_CONFIGURATION_KEY = "enableTelemetryEventsToDestination" | ||
| const val LSP_CUSTOMIZATION_CONFIGURATION_KEY = "customization"; |
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.
Was not sure what value this was tracking -- on the server side I see
if (qConfig) { fallbackCodeWhispererService.customizationArn = textUtils.undefinedIfEmpty(qConfig.customization) codePercentageTracker.customizationArn = textUtils.undefinedIfEmpty(qConfig.customization)
Does this mean the customization value we are sending should just be this:
Line 170 in a4f5c07
| override fun activeCustomization(project: Project): CodeWhispererCustomization? { |
?
| @SerializedName(AmazonQLspConstants.LSP_OPT_OUT_TELEMETRY_CONFIGURATION_KEY) | ||
| val optOutTelemetry: Boolean? = null, | ||
|
|
||
| @SerializedName(AmazonQLspConstants.LSP_ENABLE_TELEMETRY_EVENTS_CONFIGURATION_KEY) |
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.
The flag enableTelemetryEventsToDestination is set to true temporarily. It's value will be determined through destination configuration post all events migration to STE. It'll be replaced by qConfig['enableTelemetryEventsToDestination'] === true
This is not currently being used but will be in future migrations. not exactly sure what it should be pointing to in current codebase
Qodana Community for JVM28 new problems were found
💡 Qodana analysis was run in the pull request mode: only the changed files were checked Contact Qodana teamContact us at [email protected]
|
|
/retryBuilds |
.../toolkits/jetbrains/services/codewhisperer/customization/CodeWhispererCustomizationDialog.kt
Fixed
Show fixed
Hide fixed
Conflicts: plugins/amazonq/codewhisperer/jetbrains-community/src/software/aws/toolkits/jetbrains/services/codewhisperer/credentials/CodeWhispererClientAdaptor.kt plugins/amazonq/shared/jetbrains-community/src/software/aws/toolkits/jetbrains/services/codewhisperer/customization/CodeWhispererCustomizationDialog.kt plugins/amazonq/shared/jetbrains-community/src/software/aws/toolkits/jetbrains/services/codewhisperer/customization/CodeWhispererModelConfigurator.kt
...ws/toolkits/jetbrains/services/codewhisperer/customization/CodeWhispererModelConfigurator.kt
Fixed
Show fixed
Hide fixed
| import software.amazon.awssdk.services.codewhispererruntime.model.CodeWhispererRuntimeException | ||
|
|
||
| object CustomizationConstants { | ||
| private const val noAccessToCustomizationMessage = "Your account is not authorized to use CodeWhisperer Enterprise." |
Check notice
Code scanning / QDJVMC
Const property naming convention Note
|
|
||
| object CustomizationConstants { | ||
| private const val noAccessToCustomizationMessage = "Your account is not authorized to use CodeWhisperer Enterprise." | ||
| private const val invalidCustomizationMessage = "You are not authorized to access" |
Check notice
Code scanning / QDJVMC
Const property naming convention Note
...ty/src/software/aws/toolkits/jetbrains/services/codewhisperer/util/CustomizationConstants.kt
Fixed
Show fixed
Hide fixed
...software/aws/toolkits/jetbrains/services/codewhisperer/settings/CodeWhispererConfigurable.kt
Fixed
Show fixed
Hide fixed
...software/aws/toolkits/jetbrains/services/codewhisperer/settings/CodeWhispererConfigurable.kt
Fixed
Show fixed
Hide fixed
| rowComment( | ||
| message( | ||
| "codewhisperer.custom.dialog.option.customization.description.no_customization", | ||
| "https://docs.aws.amazon.com/amazonq/latest/qdeveloper-ug/customizations.html" |
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.
Should this be a const or do we expect this value to be updated?
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.
honestly it should probably just be in the localization bundle
Add q config section per: https://github.com/aws/language-servers/blob/780be3fdb92917e58524472ea5967f405f802db5/server/aws-lsp-codewhisperer/src/language-server/codeWhispererServer.ts#L629
Types of changes
Description
Checklist
License
I confirm that my contribution is made under the terms of the Apache 2.0 license.