Skip to content

Commit 36edfd1

Browse files
authored
Merge branch 'aws:master' into master
2 parents 5311154 + 196de6f commit 36edfd1

38 files changed

+824
-2035
lines changed

package-lock.json

Lines changed: 357 additions & 1450 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.
Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,18 @@
1+
{
2+
"date": "2025-05-15",
3+
"version": "1.68.0",
4+
"entries": [
5+
{
6+
"type": "Bug Fix",
7+
"description": "Fix Error: 'Amazon Q service is not signed in'"
8+
},
9+
{
10+
"type": "Bug Fix",
11+
"description": "Fix Error: 'Amazon Q Profile is not selected for IDC connection type'"
12+
},
13+
{
14+
"type": "Feature",
15+
"description": "Add inline completion support for abap language"
16+
}
17+
]
18+
}
Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,4 @@
1+
{
2+
"type": "Bug Fix",
3+
"description": "/transform: avoid prompting user for target JDK path unnecessarily"
4+
}

packages/amazonq/.changes/next-release/Feature-31d91f84-30cb-4acd-9e39-9dc153edf0a6.json

Lines changed: 0 additions & 4 deletions
This file was deleted.
Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,4 @@
1+
{
2+
"type": "Removal",
3+
"description": "/transform: remove option to select multiple diffs"
4+
}

packages/amazonq/CHANGELOG.md

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,9 @@
1+
## 1.68.0 2025-05-15
2+
3+
- **Bug Fix** Fix Error: 'Amazon Q service is not signed in'
4+
- **Bug Fix** Fix Error: 'Amazon Q Profile is not selected for IDC connection type'
5+
- **Feature** Add inline completion support for abap language
6+
17
## 1.67.0 2025-05-14
28

39
- **Bug Fix** Previous and subsequent cells are used as context for completion in a Jupyter notebook

packages/amazonq/package.json

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
"name": "amazon-q-vscode",
33
"displayName": "Amazon Q",
44
"description": "The most capable generative AI-powered assistant for building, operating, and transforming software, with advanced capabilities for managing data and AI",
5-
"version": "1.68.0-SNAPSHOT",
5+
"version": "1.69.0-SNAPSHOT",
66
"extensionKind": [
77
"workspace"
88
],
@@ -805,6 +805,11 @@
805805
{
806806
"command": "aws.amazonq.walkthrough.show",
807807
"title": "%AWS.amazonq.welcomeWalkthrough%"
808+
},
809+
{
810+
"command": "aws.amazonq.clearCache",
811+
"title": "%AWS.amazonq.clearCache%",
812+
"category": "%AWS.amazonq.title%"
808813
}
809814
],
810815
"keybindings": [

packages/amazonq/src/commands.ts

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,11 @@
99
import * as vscode from 'vscode'
1010
import { Auth } from 'aws-core-vscode/auth'
1111
import { Commands } from 'aws-core-vscode/shared'
12+
import { clearCacheDeclaration } from './util/clearCache'
1213

1314
export function registerCommands(context: vscode.ExtensionContext) {
14-
context.subscriptions.push(Commands.register('_aws.amazonq.auth.autoConnect', Auth.instance.tryAutoConnect))
15+
context.subscriptions.push(
16+
Commands.register('_aws.amazonq.auth.autoConnect', Auth.instance.tryAutoConnect),
17+
clearCacheDeclaration.register()
18+
)
1519
}

packages/amazonq/src/lsp/auth.ts

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -18,6 +18,7 @@ import { AuthUtil } from 'aws-core-vscode/codewhisperer'
1818
import { Writable } from 'stream'
1919
import { onceChanged } from 'aws-core-vscode/utils'
2020
import { getLogger, oneMinute } from 'aws-core-vscode/shared'
21+
import { isSsoConnection } from 'aws-core-vscode/auth'
2122

2223
export const encryptionKey = crypto.randomBytes(32)
2324

@@ -76,8 +77,8 @@ export class AmazonQLspAuth {
7677
* @param force bypass memoization, and forcefully update the bearer token
7778
*/
7879
async refreshConnection(force: boolean = false) {
79-
const activeConnection = this.authUtil.auth.activeConnection
80-
if (activeConnection?.state === 'valid' && activeConnection?.type === 'sso') {
80+
const activeConnection = this.authUtil.conn
81+
if (this.authUtil.isConnectionValid() && isSsoConnection(activeConnection)) {
8182
// send the token to the language server
8283
const token = await this.authUtil.getBearerToken()
8384
await (force ? this._updateBearerToken(token) : this.updateBearerToken(token))
@@ -118,7 +119,7 @@ export class AmazonQLspAuth {
118119
data: jwt,
119120
metadata: {
120121
sso: {
121-
startUrl: AuthUtil.instance.auth.startUrl,
122+
startUrl: AuthUtil.instance.startUrl,
122123
},
123124
},
124125
encrypted: true,

packages/amazonq/src/lsp/chat/activation.ts

Lines changed: 1 addition & 61 deletions
Original file line numberDiff line numberDiff line change
@@ -12,25 +12,11 @@ import { Commands, getLogger, globals, undefinedIfEmpty } from 'aws-core-vscode/
1212
import { activate as registerLegacyChatListeners } from '../../app/chat/activation'
1313
import { DefaultAmazonQAppInitContext } from 'aws-core-vscode/amazonq'
1414
import { AuthUtil, getSelectedCustomization } from 'aws-core-vscode/codewhisperer'
15-
import {
16-
DidChangeConfigurationNotification,
17-
updateConfigurationRequestType,
18-
} from '@aws/language-server-runtimes/protocol'
15+
import { pushConfigUpdate } from '../config'
1916

2017
export async function activate(languageClient: LanguageClient, encryptionKey: Buffer, mynahUIPath: string) {
2118
const disposables = globals.context.subscriptions
2219

23-
// Make sure we've sent an auth profile to the language server before even initializing the UI
24-
await pushConfigUpdate(languageClient, {
25-
type: 'profile',
26-
profileArn: AuthUtil.instance.regionProfileManager.activeRegionProfile?.arn,
27-
})
28-
// We need to push the cached customization on startup explicitly
29-
await pushConfigUpdate(languageClient, {
30-
type: 'customization',
31-
customization: getSelectedCustomization(),
32-
})
33-
3420
const provider = new AmazonQChatViewProvider(mynahUIPath)
3521

3622
disposables.push(
@@ -79,10 +65,6 @@ export async function activate(languageClient: LanguageClient, encryptionKey: Bu
7965

8066
disposables.push(
8167
AuthUtil.instance.regionProfileManager.onDidChangeRegionProfile(async () => {
82-
void pushConfigUpdate(languageClient, {
83-
type: 'profile',
84-
profileArn: AuthUtil.instance.regionProfileManager.activeRegionProfile?.arn,
85-
})
8668
await provider.refreshWebview()
8769
}),
8870
Commands.register('aws.amazonq.updateCustomizations', () => {
@@ -99,45 +81,3 @@ export async function activate(languageClient: LanguageClient, encryptionKey: Bu
9981
})
10082
)
10183
}
102-
103-
/**
104-
* Push a config value to the language server, effectively updating it with the
105-
* latest configuration from the client.
106-
*
107-
* The issue is we need to push certain configs to different places, since there are
108-
* different handlers for specific configs. So this determines the correct place to
109-
* push the given config.
110-
*/
111-
async function pushConfigUpdate(client: LanguageClient, config: QConfigs) {
112-
switch (config.type) {
113-
case 'profile':
114-
await client.sendRequest(updateConfigurationRequestType.method, {
115-
section: 'aws.q',
116-
settings: { profileArn: config.profileArn },
117-
})
118-
break
119-
case 'customization':
120-
client.sendNotification(DidChangeConfigurationNotification.type.method, {
121-
section: 'aws.q',
122-
settings: { customization: config.customization },
123-
})
124-
break
125-
case 'logLevel':
126-
client.sendNotification(DidChangeConfigurationNotification.type.method, {
127-
section: 'aws.logLevel',
128-
})
129-
break
130-
}
131-
}
132-
type ProfileConfig = {
133-
type: 'profile'
134-
profileArn: string | undefined
135-
}
136-
type CustomizationConfig = {
137-
type: 'customization'
138-
customization: string | undefined
139-
}
140-
type LogLevelConfig = {
141-
type: 'logLevel'
142-
}
143-
type QConfigs = ProfileConfig | CustomizationConfig | LogLevelConfig

0 commit comments

Comments
 (0)