Skip to content

Commit 5076210

Browse files
authored
fix(codewhisperer): tutorial state not persisted on ESC #4593
Problem Missing set(inlinehintKey, this._currentState.id, globals.context.globalState) call Solution Add set(inlinehintKey, this._currentState.id, globals.context.globalState) call
1 parent b3bb083 commit 5076210

File tree

2 files changed

+5
-2
lines changed

2 files changed

+5
-2
lines changed
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": "CodeWhisperer: Inline tutorial state not persisted when user press ESC to skip the tutorial"
4+
}

packages/core/src/codewhisperer/views/lineAnnotationController.ts

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -262,8 +262,7 @@ export class LineAnnotationController implements vscode.Disposable {
262262
try {
263263
telemetry.ui_click.emit({ elementId: `dismiss_${this._currentState.id}` })
264264
} catch (_) {}
265-
this._currentState = new EndState()
266-
await vscode.commands.executeCommand('setContext', inlinehintWipKey, false)
265+
await this.markTutorialDone()
267266
getLogger().debug(`codewhisperer: user dismiss tutorial.`)
268267
}
269268
})

0 commit comments

Comments
 (0)