-
Notifications
You must be signed in to change notification settings - Fork 681
Merge from master #7804
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
Merge from master #7804
Conversation
…ble deployment from WFS (#7315) ## Problem - Save telemetry was being recorded for all document saves in VS Code, not just for the active workflow studio document. - Save & Deploy functionality required closing Workflow Studio before starting deployment ## Solution - Add URI comparison check to ensure telemetry is only recorded when the saved document matches the current workflow studio document. - Refactored publishStateMachine.ts to accept an optional TextDocument parameter and updated activation.ts to support new interface - Removed closeCustomEditorMessageHandler call from saveFileAndDeployMessageHandler --- - Treat all work as PUBLIC. Private `feature/x` branches will not be squash-merged at release time. - Your code changes must meet the guidelines in [CONTRIBUTING.md](https://github.com/aws/aws-toolkit-vscode/blob/master/CONTRIBUTING.md#guidelines). - License: I confirm that my contribution is made under the terms of the Apache 2.0 license. --------- Co-authored-by: Diler Zaza <[email protected]>
## Problem Instead of running `mvn dependency:copy-dependencies` and `mvn clean install`, we have a JAR that we can execute which will gather all of the project dependencies as well as some important metadata stored in a `compilations.json` file which our service will use to improve the quality of transformations. ## Solution Remove Maven shell commands; add custom JAR execution. --- - Treat all work as PUBLIC. Private `feature/x` branches will not be squash-merged at release time. - Your code changes must meet the guidelines in [CONTRIBUTING.md](https://github.com/aws/aws-toolkit-vscode/blob/master/CONTRIBUTING.md#guidelines). - License: I confirm that my contribution is made under the terms of the Apache 2.0 license. --------- Co-authored-by: David Hasani <[email protected]>
fix(amazonq): migrate process.env proxy setting handling to proxyUtil.ts
## Problem Minor text update request. ## Solution Update text. --- - Treat all work as PUBLIC. Private `feature/x` branches will not be squash-merged at release time. - Your code changes must meet the guidelines in [CONTRIBUTING.md](https://github.com/aws/aws-toolkit-vscode/blob/master/CONTRIBUTING.md#guidelines). - License: I confirm that my contribution is made under the terms of the Apache 2.0 license. Co-authored-by: David Hasani <[email protected]>
fix(amazonq): fix for amazon q app initialization failure on sagemaker
fix(amazonq): Re-enable experimental proxy support
## Problem step functions still uses sdk v2 ## Solution - Refactor `DefaultStepFunctionsClient` to `StepFunctionsClient` using ClientWrapper. - Refactor references to `DefaultStepFunctionsClient` with `StepFunctionsClient` and reference sdk v3 types ## Verification - Verified CreateStateMachine, UpdateStateMachine works and creates/updates StateMachine - Verified AWS Explorer lists all StateMachines using ListStateMachine - Verified StartExecution works - Verified TestState, ListIAMRoles works in Workflow Studio, which also fixes the bug that variables cannot be used in TestState in Workflow Studio - fixes #6819  --- - Treat all work as PUBLIC. Private `feature/x` branches will not be squash-merged at release time. - Your code changes must meet the guidelines in [CONTRIBUTING.md](https://github.com/aws/aws-toolkit-vscode/blob/master/CONTRIBUTING.md#guidelines). - License: I confirm that my contribution is made under the terms of the Apache 2.0 license.
fix(amazonq): Remove incompatible Node 18 flag
#7792) ## Problem The unifiedDiff from suggestionResponse is outdated due to the change of context, resulting to the wrong line getting highlighted while rendering. ## Solution Calculate the addedLines and removedLines using the current code content and new code suggestion. --- - Treat all work as PUBLIC. Private `feature/x` branches will not be squash-merged at release time. - Your code changes must meet the guidelines in [CONTRIBUTING.md](https://github.com/aws/aws-toolkit-vscode/blob/master/CONTRIBUTING.md#guidelines). - License: I confirm that my contribution is made under the terms of the Apache 2.0 license.
## Problem if token is not available or the target branch is not master, then coverage upload command will report failure additionally, coverage upload failure should not fail the build ## Solution suppress failure --- - Treat all work as PUBLIC. Private `feature/x` branches will not be squash-merged at release time. - Your code changes must meet the guidelines in [CONTRIBUTING.md](https://github.com/aws/aws-toolkit-vscode/blob/master/CONTRIBUTING.md#guidelines). - License: I confirm that my contribution is made under the terms of the Apache 2.0 license.
…7780) ## Problem During the inline completion migration to Flare, the timeout handling of inline completion API was lost. It was there in earlier versions. The IDE -> Flare call is a local network call that should have a timeout. ## Solution Add the inline completion call with timeout back. See https://github.com/aws/aws-toolkit-vscode/blob/amazonq/v1.74.0/packages/core/src/codewhisperer/util/commonUtil.ts#L21 --- - Treat all work as PUBLIC. Private `feature/x` branches will not be squash-merged at release time. - Your code changes must meet the guidelines in [CONTRIBUTING.md](https://github.com/aws/aws-toolkit-vscode/blob/master/CONTRIBUTING.md#guidelines). - License: I confirm that my contribution is made under the terms of the Apache 2.0 license.
#7802) … to menu string ## Problem Customer reported issue here: #7796 ## Solution Fix next edit suggestion, inline accept and reject edit to menu string ## Testing <img width="608" height="87" alt="Screenshot 2025-08-01 at 2 37 51 PM" src="https://github.com/user-attachments/assets/0004dc9b-32b9-40fb-a5c4-528a8b15c2a2" /> <img width="608" height="105" alt="Screenshot 2025-08-01 at 2 38 54 PM" src="https://github.com/user-attachments/assets/783b4065-a1ae-40df-b16d-55c747b38489" /> <img width="608" height="105" alt="Screenshot 2025-08-01 at 2 39 17 PM" src="https://github.com/user-attachments/assets/31578cf4-2e46-4c30-a6b4-e762543e5252" /> --- - Treat all work as PUBLIC. Private `feature/x` branches will not be squash-merged at release time. - Your code changes must meet the guidelines in [CONTRIBUTING.md](https://github.com/aws/aws-toolkit-vscode/blob/master/CONTRIBUTING.md#guidelines). - License: I confirm that my contribution is made under the terms of the Apache 2.0 license.
) | ||
} catch (err) { | ||
const error = err as SageMakerServiceException | ||
console.error(`Failed to start SageMaker session for ${connectionIdentifier}:`, err) |
Check failure
Code scanning / CodeQL
Use of externally-controlled format string High
user-provided value
Show autofix suggestion
Hide autofix suggestion
Copilot Autofix
AI 11 days ago
To fix the problem, we should avoid passing user-controlled data as part of the format string to console.error
. Instead, we should use a static format string with a %s
specifier and pass the user-controlled value as a separate argument. This ensures that any format specifiers in the user input are treated as literal strings, not as formatting instructions. Specifically, in packages/core/src/awsService/sagemaker/detached-server/routes/getSession.ts
, line 49 should be changed from:
console.error(`Failed to start SageMaker session for ${connectionIdentifier}:`, err)
to:
console.error('Failed to start SageMaker session for %s:', connectionIdentifier, err)
No additional imports or definitions are needed.
-
Copy modified line R49
@@ -48,3 +48,3 @@ | ||
const error = err as SageMakerServiceException | ||
console.error(`Failed to start SageMaker session for ${connectionIdentifier}:`, err) | ||
console.error('Failed to start SageMaker session for %s:', connectionIdentifier, err) | ||
const errorTitle = getVSCodeErrorTitle(error) |
const strictSSL = config.proxyStrictSSL | ||
// Handle SSL certificate verification | ||
if (!strictSSL) { | ||
process.env.NODE_TLS_REJECT_UNAUTHORIZED = '0' |
Check failure
Code scanning / CodeQL
Disabling certificate validation High
Show autofix suggestion
Hide autofix suggestion
Copilot Autofix
AI 11 days ago
To fix this issue, we should never set process.env.NODE_TLS_REJECT_UNAUTHORIZED = '0'
in production code. Instead, we should always enforce certificate validation by either omitting this environment variable or explicitly setting it to '1'
. If there is a legitimate need to disable certificate validation (e.g., for local development or testing), this should be gated behind a clear and explicit check for a development environment, and accompanied by a strong warning to the user. In this case, the best fix is to remove the code that sets NODE_TLS_REJECT_UNAUTHORIZED = '0'
and always enforce certificate validation. If the user provides a custom certificate authority, it should be set via NODE_EXTRA_CA_CERTS
and AWS_CA_BUNDLE
as already done. The change should be made in the setProxyEnvironmentVariables
method in packages/core/src/shared/utilities/proxyUtil.ts
, specifically by removing lines 90-94.
-
Copy modified lines R89-R90
@@ -88,8 +88,4 @@ | ||
const strictSSL = config.proxyStrictSSL | ||
// Handle SSL certificate verification | ||
if (!strictSSL) { | ||
process.env.NODE_TLS_REJECT_UNAUTHORIZED = '0' | ||
this.logger.info('SSL verification disabled via VS Code settings') | ||
return // No need to set CA certs when SSL verification is disabled | ||
} | ||
// Always enforce SSL certificate verification. Do not disable certificate validation. | ||
// If a custom certificate authority is provided, set it below. | ||
|
#7786) ## Problem In order to set appropriate Origin Info on LSP side for SMUS CodeEditor, [link](https://github.com/aws/language-servers/blob/68adf18d7ec46a7ecf9c66fd9d52b1b8f7bc236e/server/aws-lsp-codewhisperer/src/shared/utils.ts#L377), clientInfo needs to be distinct and with current logic that uses ```vscode.env.appName``` whose value will be same for all sagemaker codeeditor instances ## Solution - To check if the environment is SageMaker and a Unified Studio instance and set corresponding clientInfo Name which is AmazonQ-For-SMUS-CE ## Testing - Built artefact locally using ```npm run compile && npm run package``` and tested on a SMUS CE space - LSP logs are attached to show the respective client Info details ``` [Trace - 9:55:46 PM] Sending request 'initialize - (0)'. Params: { "processId": 6395, "clientInfo": { "name": "vscode", "version": "1.90.1" }, .... "initializationOptions": { "aws": { "clientInfo": { "name": "AmazonQ-For-SMUS-CE", "version": "1.90.1", "extension": { "name": "AmazonQ-For-VSCode", ..... ``` - Tested the debug artefact in SMUS and SMAI spaces As observed below, the sign out was only disabled for SMUS case initially with [this](https://github.com/parameja1/aws-toolkit-vscode/blob/f5fa7989be44238d4d27b8c9e7fed967c05bc0e9/packages/core/src/codewhisperer/ui/statusBarMenu.ts#L96) change, a [CR](f5cf3bd) followed up which overrode the logic in isSageMaker and returned true for all cases irrespective of the appName passed SMUS ------ <img width="720" height="383" alt="image" src="https://github.com/user-attachments/assets/49504777-0922-49b8-942a-12efacfd4311" /> SMAI ----- <img width="720" height="383" alt="image" src="https://github.com/user-attachments/assets/e50c30df-f275-4f7b-bff0-11177a7fed0a" /> - Observing Q sendMessage failure in SMAI CE instance due to missing permissions, again unrelated to this change --- - Treat all work as PUBLIC. Private `feature/x` branches will not be squash-merged at release time. - Your code changes must meet the guidelines in [CONTRIBUTING.md](https://github.com/aws/aws-toolkit-vscode/blob/master/CONTRIBUTING.md#guidelines). - License: I confirm that my contribution is made under the terms of the Apache 2.0 license.
## Problem Need to enable and support findings coming in from the displayFindings tool Also - Agentic scans are supposed to use the CodeAnalysisScope of AGENTIC, which needed to be added ## Solution Set feature flag for displayFindings to be true Listen for displayFindings messageId from FLARE similarly to how is being done for CodeReview tool. Treat displayFindings findings and CodeReview findings separately, so they do not overwrite one another. <img width="435" height="1363" alt="image" src="https://github.com/user-attachments/assets/17a2e571-65c9-45d5-b89d-bccafda76fe2" /> --- - Treat all work as PUBLIC. Private `feature/x` branches will not be squash-merged at release time. - Your code changes must meet the guidelines in [CONTRIBUTING.md](https://github.com/aws/aws-toolkit-vscode/blob/master/CONTRIBUTING.md#guidelines). - License: I confirm that my contribution is made under the terms of the Apache 2.0 license. --------- Co-authored-by: Blake Lazarine <[email protected]> Co-authored-by: Nitish <[email protected]>
## Problem In SMAI remote ssh space, Q chat request failed as IAM creds not found ## Solution Discussed with SMAI team, for SMAI remote ssh space, not set the default auth mode as IAM. ## Test before tested with the latest version v1.87.0 https://github.com/user-attachments/assets/7a4f8b23-fb64-453c-830a-bfc58fc8394c after tested with a local build version https://github.com/user-attachments/assets/765c772c-13b2-444f-bada-eb9eb5068d55 --- - Treat all work as PUBLIC. Private `feature/x` branches will not be squash-merged at release time. - Your code changes must meet the guidelines in [CONTRIBUTING.md](https://github.com/aws/aws-toolkit-vscode/blob/master/CONTRIBUTING.md#guidelines). - License: I confirm that my contribution is made under the terms of the Apache 2.0 license.
## Problem aws/language-server-runtimes#638 The workspace.getAllTextDocuments() API only returns the open tabs that were clicked during this IDE session. If you open, close, reopen IDE, this API returns empty unless user re-click those files again. So we need to let IDE compute the list of open tab files and send it to language server ## Solution Pass open tabs from the IDE to language server. This is not customer facing so there is no change log needed. It merely brings back old functional code. --- - Treat all work as PUBLIC. Private `feature/x` branches will not be squash-merged at release time. - Your code changes must meet the guidelines in [CONTRIBUTING.md](https://github.com/aws/aws-toolkit-vscode/blob/master/CONTRIBUTING.md#guidelines). - License: I confirm that my contribution is made under the terms of the Apache 2.0 license.
…d studio #7786 (#7813) Reverts #7786 This revert PR will fix the failing tests here: https://d1ihu6zq92vp9p.cloudfront.net/c6d9931c-1deb-46ae-ae59-a3d205835a39/report.html Linux Unit Tests are passing 4252/4252: https://d1ihu6zq92vp9p.cloudfront.net/e705989e-fe51-45e4-9772-7ed2ef7eb3fb/report.html
…me interrupted jobs (#7781) ## Problem Users cannot see previous job details (status, project name, job id, etc) and cannot access the final diff patch. Network issues can cause jobs to fail on client side while they continue on the backend, and users have no way to access those artifacts. ## Solution Repurpose the job status table to show most recent 10 jobs run in the last 30 days, including links to final diff patch and summary files. Allow users to retrieve missing artifacts for jobs and to resume incomplete jobs via refresh button. <img width="1133" height="290" alt="History Table - New Text" src="https://github.com/user-attachments/assets/5aea4f3d-5fd6-4109-997a-af7ed737ea32" /> <img width="313" height="274" alt="View History Button" src="https://github.com/user-attachments/assets/216ee214-df39-4e95-bf03-1f9f448faf1f" /> --- - Treat all work as PUBLIC. Private `feature/x` branches will not be squash-merged at release time. - Your code changes must meet the guidelines in [CONTRIBUTING.md](https://github.com/aws/aws-toolkit-vscode/blob/master/CONTRIBUTING.md#guidelines). - License: I confirm that my contribution is made under the terms of the Apache 2.0 license. --------- Co-authored-by: Laxman Reddy <[email protected]> Co-authored-by: chungjac <[email protected]>
… on acceptance (#7814) ## Problem For Edits pagination case, we always send discard telemetry even though there are pending Edits suggestions. The root cause is due to prefix matching logic (we always send discard telemetry if the prefix does not match). ## Solution Skip prefix matching for Edits suggestions that trigger on acceptance (pagination case) --- - Treat all work as PUBLIC. Private `feature/x` branches will not be squash-merged at release time. - Your code changes must meet the guidelines in [CONTRIBUTING.md](https://github.com/aws/aws-toolkit-vscode/blob/master/CONTRIBUTING.md#guidelines). - License: I confirm that my contribution is made under the terms of the Apache 2.0 license.
## Problem Failing 1 test ## Solution Fixed it --- - Treat all work as PUBLIC. Private `feature/x` branches will not be squash-merged at release time. - Your code changes must meet the guidelines in [CONTRIBUTING.md](https://github.com/aws/aws-toolkit-vscode/blob/master/CONTRIBUTING.md#guidelines). - License: I confirm that my contribution is made under the terms of the Apache 2.0 license.
## Problem Developers frequently encounter compilation errors, linting issues, and other diagnostic problems while coding in VS Code. Currently, they need to manually copy error messages and switch to Amazon Q chat to get help fixing these issues, creating friction in the development workflow and breaking their coding flow. ## Solution This PR introduces Amazon Q Auto Debug, a new feature that seamlessly integrates diagnostic problem-solving directly into the VS Code editor experience. The feature provides three main interaction methods: Quick Fix Integration: When hovering over diagnostic errors/warnings, developers see Amazon Q options in the quick fix menu including "Fix Problem", "Fix All Errors", and "Explain Problem" actions. Command Palette Access: Three new commands are registered (amazonq.01.fixWithQ, amazonq.02.fixAllWithQ, amazonq.03.explainProblem) that can be triggered from the command palette or bound to keyboard shortcuts. Intelligent Error Processing: The system automatically captures diagnostic information from VS Code's language servers, formats error context with surrounding code snippets, and sends structured prompts to Amazon Q chat. For "Fix All" operations, it processes up to 15 errors at once to avoid overwhelming the AI system. The workflow operates through a controller-based architecture that monitors VS Code diagnostics, formats error context with file paths and line numbers, and communicates directly with the Amazon Q chat panel via LSP client messaging. When users trigger a fix action, the system automatically focuses the Amazon Q panel and submits a formatted prompt containing the error details and surrounding code context, enabling Amazon Q to provide targeted solutions without requiring manual context switching. ## Video Demos Fix single problem https://github.com/user-attachments/assets/c73b7a63-8806-4016-b7af-03f239f07bba Explain single problem https://github.com/user-attachments/assets/367137aa-8362-4a08-a12b-27d892c0b6e6 Fix all errors https://github.com/user-attachments/assets/95eb5691-d3be-499a-8e8c-76f4b77c57dd --------- Co-authored-by: aws-toolkit-automation <[email protected]> Co-authored-by: aws-toolkit-automation <> Co-authored-by: Will Lo <[email protected]> Co-authored-by: Diler Zaza <[email protected]> Co-authored-by: Diler Zaza <[email protected]> Co-authored-by: David <[email protected]> Co-authored-by: David Hasani <[email protected]> Co-authored-by: samgst-amazon <[email protected]> Co-authored-by: Ashish Reddy Podduturi <[email protected]> Co-authored-by: Tyrone Smith <[email protected]> Co-authored-by: zelzhou <[email protected]> Co-authored-by: Ralph Flora <[email protected]> Co-authored-by: Jingyuan Li <[email protected]> Co-authored-by: Rile Ge <[email protected]> Co-authored-by: Aidan Ton <[email protected]> Co-authored-by: Lei Gao <[email protected]> Co-authored-by: Laxman Reddy <[email protected]> Co-authored-by: invictus <[email protected]> Co-authored-by: chungjac <[email protected]>
## Problem ## Solution --- - Treat all work as PUBLIC. Private `feature/x` branches will not be squash-merged at release time. - Your code changes must meet the guidelines in [CONTRIBUTING.md](https://github.com/aws/aws-toolkit-vscode/blob/master/CONTRIBUTING.md#guidelines). - License: I confirm that my contribution is made under the terms of the Apache 2.0 license.
…dio case (#7817) ## Problem In order to set appropriate Origin Info on LSP side for SMUS CodeEditor, [link](https://github.com/aws/language-servers/blob/68adf18d7ec46a7ecf9c66fd9d52b1b8f7bc236e/server/aws-lsp-codewhisperer/src/shared/utils.ts#L377), clientInfo needs to be distinct and with current logic that uses ```vscode.env.appName``` whose value will be same for all sagemaker codeeditor instances - The original PR was reverted [here](https://github.com/aws/aws-toolkit-vscode/pull/7813/commits) due to failing unit tests - Unit test failure was due to env variable ```SERVICE_NAME``` being modified directly from test code causing failure in other tests which identified the environment to be SMUS without clean isolation - Fixed the test failure by using sinon stub instead of modifying env vars in node process ## Solution - To check if the environment is SageMaker and a Unified Studio instance and set corresponding clientInfo Name which is ```AmazonQ-For-SMUS-CE``` ## Testing - Built artefact locally using ```npm run compile && npm run package``` and tested on a SMUS CE space - Ran ```npm run test -w packages/toolkit``` which succeeded - LSP logs are attached to show the respective client Info details ``` [Trace - 9:55:46 PM] Sending request 'initialize - (0)'. Params: { "processId": 6395, "clientInfo": { "name": "vscode", "version": "1.90.1" }, .... "initializationOptions": { "aws": { "clientInfo": { "name": "AmazonQ-For-SMUS-CE", "version": "1.90.1", "extension": { "name": "AmazonQ-For-VSCode", ..... ``` - Tested the debug artefact in SMUS and SMAI spaces As observed below, the sign out was only disabled for SMUS case initially with [this](https://github.com/parameja1/aws-toolkit-vscode/blob/f5fa7989be44238d4d27b8c9e7fed967c05bc0e9/packages/core/src/codewhisperer/ui/statusBarMenu.ts#L96) change, a [CR](f5cf3bd) followed up which overrode the logic in isSageMaker and returned true for all cases irrespective of the appName passed SMUS ------ <img width="720" height="383" alt="image" src="https://github.com/user-attachments/assets/49504777-0922-49b8-942a-12efacfd4311" /> SMAI ----- <img width="720" height="383" alt="image" src="https://github.com/user-attachments/assets/e50c30df-f275-4f7b-bff0-11177a7fed0a" /> - Observing Q sendMessage failure in SMAI CE instance due to missing permissions, again unrelated to this change --- - Treat all work as PUBLIC. Private `feature/x` branches will not be squash-merged at release time. - Your code changes must meet the guidelines in [CONTRIBUTING.md](https://github.com/aws/aws-toolkit-vscode/blob/master/CONTRIBUTING.md#guidelines). - License: I confirm that my contribution is made under the terms of the Apache 2.0 license. --------- Co-authored-by: Laxman Reddy <[email protected]>
## Problem There is no change log for the auto debug feature. ## Solution Add the needed logs. --- - Treat all work as PUBLIC. Private `feature/x` branches will not be squash-merged at release time. - Your code changes must meet the guidelines in [CONTRIBUTING.md](https://github.com/aws/aws-toolkit-vscode/blob/master/CONTRIBUTING.md#guidelines). - License: I confirm that my contribution is made under the terms of the Apache 2.0 license.
## Problem related aws/language-servers#2058 Edits as a newly introduced feature, previously the implementation was living in the same flow as Completion. However the 2 suggestion types have few different product requirements, thus we decided to completely separate these 2 suggestions out in terms of their code path. Key difference - Language server will process Completion request on receiving request from IDE clients, and will BLOCK following requests if in-flight request is not fulfilled yet. Edits, on the other hand, it debounces/delay the execution time for the sake of "latest" file context to ensure the suggestion reflects the CORRECT changes users attempt to make. - Triggering heuristic. For example, Completion is not supposed to be invoked when users are deleting the code, whereas Edits allow such scenario to go through. ## Solution - Introduce a new `onEditCompletion` language server API which is purely for Edits suggestion. - Invoke 2 Flare API and serve the response which first arrives (First come first served). - Allow Edits suggestion on code deletion --- - Treat all work as PUBLIC. Private `feature/x` branches will not be squash-merged at release time. - Your code changes must meet the guidelines in [CONTRIBUTING.md](https://github.com/aws/aws-toolkit-vscode/blob/master/CONTRIBUTING.md#guidelines). - License: I confirm that my contribution is made under the terms of the Apache 2.0 license.
## Problem Sometimes a `.yaml` file QCT asks for from the customer is malformed and users don't see what exactly is wrong. ## Solution Validate the file and provide a more specific error message. --- - Treat all work as PUBLIC. Private `feature/x` branches will not be squash-merged at release time. - Your code changes must meet the guidelines in [CONTRIBUTING.md](https://github.com/aws/aws-toolkit-vscode/blob/master/CONTRIBUTING.md#guidelines). - License: I confirm that my contribution is made under the terms of the Apache 2.0 license. --------- Co-authored-by: David Hasani <[email protected]> Co-authored-by: invictus <[email protected]> Co-authored-by: Laxman Reddy <[email protected]>
## Problem Job history-related code is scattered throughout various files, making it difficult to review and understand. ## Solution Centralize existing history functions in a new file and add helper functions to declutter transformation flow. Update and simplify unit tests accordingly. --- - Treat all work as PUBLIC. Private `feature/x` branches will not be squash-merged at release time. - Your code changes must meet the guidelines in [CONTRIBUTING.md](https://github.com/aws/aws-toolkit-vscode/blob/master/CONTRIBUTING.md#guidelines). - License: I confirm that my contribution is made under the terms of the Apache 2.0 license.
## Problem discard when it's not yet shown. reject when user's typing and makes the diff invalid. ## Solution --- - Treat all work as PUBLIC. Private `feature/x` branches will not be squash-merged at release time. - Your code changes must meet the guidelines in [CONTRIBUTING.md](https://github.com/aws/aws-toolkit-vscode/blob/master/CONTRIBUTING.md#guidelines). - License: I confirm that my contribution is made under the terms of the Apache 2.0 license.
…or agentic chat (#7857) ## Problem In order to set appropriate Origin Info on LSP side for SMAI CodeEditor, [link](https://github.com/aws/language-servers/blob/68adf18d7ec46a7ecf9c66fd9d52b1b8f7bc236e/server/aws-lsp-codewhisperer/src/shared/utils.ts#L377), clientInfo needs to be distinct - related [PR to support SMUS](#7817) ## Solution - To check if the environment is SageMaker and a Unified Studio instance and set corresponding clientInfo Name which is ```AmazonQ-For-SMUS-CE``` ## Testing - Built artefact locally using ```npm run compile && npm run package``` and tested on a SMAI CE space - Ran ```npm run test -w packages/toolkit``` which succeeded - LSP logs show the respective client Info details ``` --- - Treat all work as PUBLIC. Private `feature/x` branches will not be squash-merged at release time. - Your code changes must meet the guidelines in [CONTRIBUTING.md](https://github.com/aws/aws-toolkit-vscode/blob/master/CONTRIBUTING.md#guidelines). - License: I confirm that my contribution is made under the terms of the Apache 2.0 license. Co-authored-by: Laxman Reddy <[email protected]>
…7839) ## Problem Inline completion suggestions were being shown even when edit suggestions were active, creating a confusing user experience where both types of suggestions could appear simultaneously. ## Solution 1. Added conflict prevention logic in provideInlineCompletionItems() to check for active edit suggestions using the existing aws.amazonq.editSuggestionActive context flag 1. Created isEditSuggestionActive() method to encapsulate context checking 1. Implemented DISCARD telemetry for completion suggestions that can't be shown due to active edits 1. Added unit tests covering the new functionality, including edge cases for mixed suggestion types and items without IDs 1. Updated displayImage.ts to properly set/unset the context flag when edit suggestions are displayed/cleared 1. The solution ensures only one type of suggestion is active at a time while maintaining telemetry compliance and following existing codebase patterns. --- Treat all work as PUBLIC. Private feature/x branches will not be squash-merged at release time. Your code changes must meet the guidelines in [CONTRIBUTING.md](https://github.com/aws/aws-toolkit-vscode/blob/master/CONTRIBUTING.md#guidelines). License: I confirm that my contribution is made under the terms of the Apache 2.0 license.
Merge from master
feature/x
branches will not be squash-merged at release time.