Skip to content

Commit 48223ad

Browse files
authored
Merge staging into feature/mde
2 parents 6701ebd + d7f7383 commit 48223ad

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

56 files changed

+2477
-744
lines changed

.changes/1.56.0.json

Lines changed: 26 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,26 @@
1+
{
2+
"date": "2022-11-28",
3+
"version": "1.56.0",
4+
"entries": [
5+
{
6+
"type": "Feature",
7+
"description": "Amazon CodeWhisperer now adds new access methods with AWS Builder ID and AWS IAM Identity Center to enable and get started. "
8+
},
9+
{
10+
"type": "Feature",
11+
"description": "Amazon CodeWhisperer recommendations are more context aware. We are removing the overlaps from CodeWhisperer suggestions specifically when the cursor is inside a code block."
12+
},
13+
{
14+
"type": "Feature",
15+
"description": "Amazon CodeWhisperer now supports TypeScript and C# programming languages."
16+
},
17+
{
18+
"type": "Feature",
19+
"description": "Amazon CodeWhisperer is now available as a supported feature and no longer an experimental feature."
20+
},
21+
{
22+
"type": "Feature",
23+
"description": "Amazon CodeWhisperer now supports JavaScript for Security Scan to catch security vulnerabilities."
24+
}
25+
]
26+
}

.eslintignore

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,7 @@ node_modules/**
22
**/*.json
33
src/shared/telemetry/clienttelemetry.d.ts
44
src/codewhisperer/client/codewhispererclient.d.ts
5+
src/codewhisperer/client/codewhispereruserclient.d.ts
56
types/clientcodecatalyst.d.ts
67
**/*.gen.ts
78
src/testFixtures/workspaceFolder/ts-plain-sam-app/

.gitignore

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -26,6 +26,7 @@ src/shared/telemetry/vscodeTelemetry.json
2626
# Auto generated type definitions
2727
src/shared/telemetry/clienttelemetry.d.ts
2828
src/codewhisperer/client/codewhispererclient.d.ts
29+
src/codewhisperer/client/codewhispereruserclient.d.ts
2930
types/clientcodecatalyst.d.ts
3031

3132
# Generated by tests

CHANGELOG.md

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,11 @@
1+
## 1.56.0 2022-11-28
2+
3+
- **Feature** Amazon CodeWhisperer now adds new access methods with AWS Builder ID and AWS IAM Identity Center to enable and get started.
4+
- **Feature** Amazon CodeWhisperer recommendations are more context aware. We are removing the overlaps from CodeWhisperer suggestions specifically when the cursor is inside a code block.
5+
- **Feature** Amazon CodeWhisperer now supports TypeScript and C# programming languages.
6+
- **Feature** Amazon CodeWhisperer is now available as a supported feature and no longer an experimental feature.
7+
- **Feature** Amazon CodeWhisperer now supports JavaScript for Security Scan to catch security vulnerabilities.
8+
19
## 1.55.0 2022-11-23
210

311
- **Bug Fix** logging: `aws.viewLogsAtMessage` no longer fails when the log message cannot be found

package-lock.json

Lines changed: 8 additions & 8 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

package.json

Lines changed: 24 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
"name": "aws-toolkit-vscode",
33
"displayName": "AWS Toolkit",
44
"description": "Amazon Web Services toolkit for browsing and updating cloud resources",
5-
"version": "1.56.0-SNAPSHOT",
5+
"version": "1.57.0-SNAPSHOT",
66
"extensionKind": [
77
"workspace"
88
],
@@ -273,18 +273,13 @@
273273
"markdownDescription": "%AWS.configuration.description.experiments%",
274274
"default": {
275275
"jsonResourceModification": false,
276-
"CodeWhisperer": true,
277276
"samSyncCode": false
278277
},
279278
"properties": {
280279
"jsonResourceModification": {
281280
"type": "boolean",
282281
"default": false
283282
},
284-
"CodeWhisperer": {
285-
"type": "boolean",
286-
"default": true
287-
},
288283
"samSyncCode": {
289284
"type": "boolean",
290285
"default": false
@@ -824,6 +819,10 @@
824819
"command": "aws.codecatalyst.removeConnection",
825820
"when": "false"
826821
},
822+
{
823+
"command": "aws.codeWhisperer.removeConnection",
824+
"when": "false"
825+
},
827826
{
828827
"command": "aws.downloadSchemaItemCode",
829828
"when": "false"
@@ -1830,14 +1829,24 @@
18301829
},
18311830
{
18321831
"command": "aws.codeWhisperer.configure",
1833-
"when": "viewItem == awsCodeWhispererNode && !isCloud9",
1832+
"when": "viewItem =~ /^awsCodeWhispererNode/ && !isCloud9",
18341833
"group": "inline@2"
18351834
},
18361835
{
18371836
"command": "aws.codeWhisperer.introduction",
1838-
"when": "viewItem == awsCodeWhispererNode && !isCloud9 && CODEWHISPERER_TERMS_ACCEPTED",
1837+
"when": "viewItem =~ /^awsCodeWhispererNode/ && !isCloud9 && CODEWHISPERER_TERMS_ACCEPTED",
18391838
"group": "inline@1"
18401839
},
1840+
{
1841+
"command": "aws.codeWhisperer.removeConnection",
1842+
"when": "viewItem == awsCodeWhispererNodeSaved",
1843+
"group": "0@1"
1844+
},
1845+
{
1846+
"command": "aws.codeWhisperer.removeConnection",
1847+
"when": "viewItem == awsCodeWhispererNodeSaved",
1848+
"group": "inline@3"
1849+
},
18411850
{
18421851
"command": "aws.cdk.refresh",
18431852
"when": "viewItem == awsCdkRootNode",
@@ -3112,6 +3121,12 @@
31123121
}
31133122
}
31143123
},
3124+
{
3125+
"command": "aws.codeWhisperer.removeConnection",
3126+
"title": "%AWS.command.codewhisperer.removeConnection%",
3127+
"category": "%AWS.title%",
3128+
"icon": "$(debug-disconnect)"
3129+
},
31153130
{
31163131
"command": "aws.dev.openMenu",
31173132
"title": "Open Developer Menu",
@@ -3483,7 +3498,7 @@
34833498
"report": "nyc report --reporter=html --reporter=json"
34843499
},
34853500
"devDependencies": {
3486-
"@aws-toolkits/telemetry": "^1.0.79",
3501+
"@aws-toolkits/telemetry": "^1.0.80",
34873502
"@cspotcode/source-map-support": "^0.8.1",
34883503
"@sinonjs/fake-timers": "^8.1.0",
34893504
"@types/adm-zip": "^0.4.34",

package.nls.json

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@
1818
"AWS.configuration.description.suppressPrompts": "Prompts which ask for confirmation. Checking an item suppresses the prompt.",
1919
"AWS.configuration.enableCodeLenses": "Enable SAM hints in source files",
2020
"AWS.configuration.description.resources.enabledResources": "AWS resources to display in the 'Resources' portion of the explorer.",
21-
"AWS.configuration.description.experiments": "Try experimental features and give feedback. Note that experimental features may be removed at any time.\n * `jsonResourceModification` - Enables basic create, update, and delete support for cloud resources via the JSON Resources explorer component \n * `CodeWhisperer` - CodeWhisperer helps improve efficiency by providing real-time code suggestions from AI models. [Learn More](https://aws.amazon.com/codewhisperer). Use a keyboard shortcut to request suggestions from CodeWhisperer while writing code. Default keyboard shortcut is [Alt(Option) + C], can be updated in Keyboard Shortcuts.\n * `samSyncCode` - Adds an additional code-only option when synchronizing SAM applications. Code-only synchronizations are faster but can cause drift in the CloudFormation stack. Does nothing when using the legacy SAM deploy feature.",
21+
"AWS.configuration.description.experiments": "Try experimental features and give feedback. Note that experimental features may be removed at any time.\n * `jsonResourceModification` - Enables basic create, update, and delete support for cloud resources via the JSON Resources explorer component.\n * `samSyncCode` - Adds an additional code-only option when synchronizing SAM applications. Code-only synchronizations are faster but can cause drift in the CloudFormation stack. Does nothing when using the legacy SAM deploy feature.",
2222
"AWS.stepFunctions.asl.format.enable.desc": "Enables the default formatter used with Amazon States Language files",
2323
"AWS.stepFunctions.asl.maxItemsComputed.desc": "The maximum number of outline symbols and folding regions computed (limited for performance reasons).",
2424
"AWS.configuration.description.awssam.debug.api": "API Gateway configuration",
@@ -74,7 +74,7 @@
7474
"AWS.command.apig.copyUrl": "Copy URL",
7575
"AWS.command.apig.invokeRemoteRestApi": "Invoke on AWS",
7676
"AWS.command.apig.invokeRemoteRestApi.cn": "Invoke on Amazon",
77-
"AWS.command.auth.addConnection": "Add new Connection",
77+
"AWS.command.auth.addConnection": "Add New Connection",
7878
"AWS.command.auth.switchConnections": "Switch Connections",
7979
"AWS.command.auth.signout": "Sign out",
8080
"AWS.command.github": "View Source on GitHub",
@@ -185,6 +185,7 @@
185185
"AWS.command.resources.configure": "Show Resources...",
186186
"AWS.command.codewhisperer.introduction": "What is CodeWhisperer?",
187187
"AWS.command.codewhisperer.configure": "CodeWhisperer Settings",
188+
"AWS.command.codewhisperer.removeConnection": "Remove Connection from Tool",
188189
"AWS.lambda.explorerTitle": "Explorer",
189190
"AWS.developerTools.explorerTitle": "Developer Tools",
190191
"AWS.cloudWatchLogs.limit.desc": "Maximum amount of log entries pulled per request from CloudWatch Logs (max 10000)",
Lines changed: 29 additions & 23 deletions
Original file line numberDiff line numberDiff line change
@@ -1,37 +1,43 @@
1-
## How to Use Amazon CodeWhisperer
1+
## Using Amazon CodeWhisperer
22

3-
Welcome to the Amazon CodeWhisperer preview! CodeWhisperer uses machine learning to generate code suggestions
4-
from the existing code and comments in your IDE. Supported languages include: **Java, Python, and JavaScript**.
3+
CodeWhisperer uses machine learning to generate code suggestions from the existing code and comments in your IDE. Supported languages include **Java, Python, JavaScript, C# and TypeScript**.
54

6-
### TAB. Left Arrow. Right Arrow. That’s all!
5+
---
76

8-
You should automatically see inline code suggestions. Use the **TAB key to accept** a suggestion. CodeWhisperer may
9-
provide multiple suggestions to choose from, use **[left arrow] and [right arrow] to navigate** between suggestions.
7+
**Navigating with the tab and arrow keys**
108

11-
That’s all you need to know. If you don’t like the suggestions you see, simply keep typing (or hit ESC key).
12-
The suggestions will go away and CodeWhisperer will generate new ones at a later point based on the additional context.
9+
As you enter your code, CodeWhisperer will offer inline code suggestions. Use **TAB to accept** a suggestion. CodeWhisperer may provide multiple suggestions to choose from. Use **[left arrow] and [right arrow] to navigate** between suggestions.
1310

14-
### Requesting Suggestions Manually
11+
If you don’t like the suggestions you see, keep typing (or hit ESC). The suggestions will disappear, and CodeWhisperer will generate new ones at a later point based on the additional context.
1512

16-
You can also request a suggestion at any time, use **Option C** on Mac and **ALT C** on Windows. Once you receive
17-
the suggestions use TAB to accept and the Arrow keys to navigate.
13+
<img src="twosum_vsc.gif" style="max-height:400px;" alt="twosum">
1814

19-
### How to get the best recommendations
15+
---
2016

21-
- More context = better recommendations. You will see better recommendations when your current file has more
22-
existing code.
17+
**Requesting suggestions manually**
2318

24-
- Write more comments and be more descriptive. “Function to upload a file to S3” will get better results than
25-
“Upload a file.”
19+
You can request suggestions at any time. Use **Option-C** on Mac or **ALT-C** on Windows. After you receive suggestions, use TAB to accept and arrow keys to navigate.
2620

27-
- Try to specify the libraries you prefer by inserting import statements.
21+
---
2822

29-
- Use descriptive names for variable and functions. A function called “upload_file_to_S3” will get better results
30-
than a function called “file_upload”
23+
**Getting the best recommendations**
3124

32-
- Break down complex tasks into smaller tasks and write descriptive comments.
25+
For best results, follow these practices.
3326

34-
### How to provide feedback
27+
- Give CodeWhisperer something to work with. The more code your file contains, the more context CodeWhisperer has for generating recommendations.
28+
- Write descriptive comments. “Function to upload a file to S3” will get better results than “Upload a file”.
29+
- Specify the libraries you prefer by using import statements.
30+
- Use descriptive names for variable and functions. A function called “upload_file_to_S3” will get better results than a function called “file_upload”.
31+
- Break down complex tasks into simpler tasks.
3532

36-
CodeWhisperer is in preview, let us know what your think by sharing feedback (using the AWS Toolkit
37-
feedback button) or reaching out to [[email protected]](mailto:[email protected]) .
33+
---
34+
35+
**Further reading**
36+
37+
To learn more about working with CodeWhisperer and VS Code, see [CodeWhisperer for VS Code](https://docs.aws.amazon.com/toolkit-for-vscode/latest/userguide/codewhisperer.html).
38+
39+
---
40+
41+
**Providing feedback**
42+
43+
CodeWhisperer is in preview. Let us know what you think by sharing feedback (using the AWS Toolkit feedback button) or by reaching out to [[email protected]](mailto:[email protected]).

resources/markdown/twosum_vsc.gif

256 KB
Loading

scripts/build/generateServiceClient.ts

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -218,6 +218,10 @@ ${fileContents}
218218
serviceJsonPath: 'src/codewhisperer/client/service-2.json',
219219
serviceName: 'CodeWhispererClient',
220220
},
221+
{
222+
serviceJsonPath: 'src/codewhisperer/client/user-service-2.json',
223+
serviceName: 'CodeWhispererUserClient',
224+
},
221225
]
222226
await generateServiceClients(serviceClientDefinitions)
223227
})()

0 commit comments

Comments
 (0)