diff --git a/README.md b/README.md index 1a6e48d1..52df14b1 100644 --- a/README.md +++ b/README.md @@ -1,6 +1,6 @@ # Python Debugger extension for Visual Studio Code -A [Visual Studio Code](https://code.visualstudio.com/) [extension](https://marketplace.visualstudio.com/VSCode) that supports Python debugging with debugpy. Python Debugger provides a seamless debugging experience by allowing you to set breakpoints, step through code, inspect variables, and perform other essential debugging tasks. The debugy extension offers debugging support for various types of Python applications including scripts, web applications, remote processes, and multi-threaded processes. +A [Visual Studio Code](https://code.visualstudio.com/) [extension](https://marketplace.visualstudio.com/VSCode) that supports Python debugging with debugpy. Python Debugger provides a seamless debugging experience by allowing you to set breakpoints, step through code, inspect variables, and perform other essential debugging tasks. The debugpy extension offers debugging support for various types of Python applications including scripts, web applications, remote processes, and multi-threaded processes. Note: - The Python extension offers the python debugger extension as an optional installation, including it during the setup process. @@ -52,4 +52,4 @@ You can reference the table below to find the most recent Python Debugger extens ## Data and telemetry -The Debubpy Extension for Visual Studio Code collects usage data and sends it to Microsoft to help improve our products and services. Read our [privacy statement](https://privacy.microsoft.com/privacystatement) to learn more. This extension respects the `telemetry.enableTelemetry` setting which you can learn more about at https://code.visualstudio.com/docs/supporting/faq#_how-to-disable-telemetry-reporting. +The Debugpy Extension for Visual Studio Code collects usage data and sends it to Microsoft to help improve our products and services. Read our [privacy statement](https://privacy.microsoft.com/privacystatement) to learn more. This extension respects the `telemetry.enableTelemetry` setting which you can learn more about at https://code.visualstudio.com/docs/supporting/faq#_how-to-disable-telemetry-reporting. diff --git a/package.json b/package.json index b58cb357..3a4cd382 100644 --- a/package.json +++ b/package.json @@ -253,7 +253,7 @@ "properties": { "args": { "default": [], - "description": "Command line arguments passed to the program. For string type arguments, it will pass through the shell as is, and therefore all shell variable expansions will apply. But for the array type, tha values will be shell-escaped.", + "description": "Command line arguments passed to the program. For string type arguments, it will pass through the shell as is, and therefore all shell variable expansions will apply. But for the array type, the values will be shell-escaped.", "items": { "type": "string" }, @@ -496,7 +496,7 @@ "format-check": "prettier --check 'src/**/*.ts' 'build/**/*.yml' '.github/**/*.yml'", "format-fix": "prettier --write 'src/**/*.ts' 'build/**/*.yml' '.github/**/*.yml'", "test": "node ./out/test/runTest.js", - "vsce-package": "vsce package -o pyhton-debugger.vsix" + "vsce-package": "vsce package -o python-debugger.vsix" }, "devDependencies": { "@types/chai": "^4.3.4", diff --git a/src/extension/common/persistentState.ts b/src/extension/common/persistentState.ts index b996b1cc..9e26889f 100644 --- a/src/extension/common/persistentState.ts +++ b/src/extension/common/persistentState.ts @@ -41,7 +41,7 @@ export class PersistentState implements IPersistentState { await this.storage.update(this.key, newValue); } if (retryOnce && JSON.stringify(this.value) !== JSON.stringify(newValue)) { - // Due to a VSCode bug sometimes the changes are not reflected in the storage, atleast not immediately. + // Due to a VSCode bug sometimes the changes are not reflected in the storage, at least not immediately. // It is noticed however that if we reset the storage first and then update it, it works. // https://github.com/microsoft/vscode/issues/171827 traceVerbose('Storage update failed for key', this.key, ' retrying by resetting first'); diff --git a/src/extension/debugger/configuration/launch.json/updaterServiceHelper.ts b/src/extension/debugger/configuration/launch.json/updaterServiceHelper.ts index ca181d86..080998d4 100644 --- a/src/extension/debugger/configuration/launch.json/updaterServiceHelper.ts +++ b/src/extension/debugger/configuration/launch.json/updaterServiceHelper.ts @@ -82,7 +82,7 @@ export class LaunchJsonUpdaterServiceHelper { ): string { const json = JSON.stringify(config); if (cursorPosition === 'AfterItem') { - // If we already have a comma immediatley before the cursor, then no need of adding a comma. + // If we already have a comma immediately before the cursor, then no need of adding a comma. return commaPosition === 'BeforeCursor' ? json : `,${json}`; } if (cursorPosition === 'BeforeItem') { diff --git a/src/extension/debugger/helpers/protocolParser.ts b/src/extension/debugger/helpers/protocolParser.ts index b59b06c7..d946a606 100644 --- a/src/extension/debugger/helpers/protocolParser.ts +++ b/src/extension/debugger/helpers/protocolParser.ts @@ -82,9 +82,9 @@ export class ProtocolParser implements IProtocolParser { break; } case 'response': { - const reponse = message as DebugProtocol.Response; - if (typeof reponse.command === 'string') { - this.events.emit(`${message.type}_${reponse.command}`, reponse); + const response = message as DebugProtocol.Response; + if (typeof response.command === 'string') { + this.events.emit(`${message.type}_${response.command}`, response); } break; } diff --git a/src/extension/extensionInit.ts b/src/extension/extensionInit.ts index d8a5fd3f..ba739292 100644 --- a/src/extension/extensionInit.ts +++ b/src/extension/extensionInit.ts @@ -97,8 +97,8 @@ export async function registerDebugger(context: IExtensionContext): Promise { } export async function closeActiveWindows(): Promise { await closeActiveNotebooks(); - await closeWindowsInteral(); + await closeWindowsInternal(); } export async function closeActiveNotebooks(): Promise { if (!vscode.env.appName.toLowerCase().includes('insiders') || !isANotebookOpen()) { @@ -74,14 +74,14 @@ export async function closeActiveNotebooks(): Promise { // Hence keep trying. for (let counter = 0; counter <= 5 && isANotebookOpen(); counter += 1) { await sleep(counter * 100); - await closeWindowsInteral(); + await closeWindowsInternal(); } } -async function closeWindowsInteral() { +async function closeWindowsInternal() { return new Promise((resolve, reject) => { // Attempt to fix #1301. - // Lets not waste too much time. + // Let's not waste too much time. const timer = setTimeout(() => { reject(new Error("Command 'workbench.action.closeAllEditors' timed out")); }, 15000); diff --git a/src/test/unittest/configuration/launch.json/updaterServerHelper.unit.test.ts b/src/test/unittest/configuration/launch.json/updaterServerHelper.unit.test.ts index 551be79a..0dd4cb7a 100644 --- a/src/test/unittest/configuration/launch.json/updaterServerHelper.unit.test.ts +++ b/src/test/unittest/configuration/launch.json/updaterServerHelper.unit.test.ts @@ -390,7 +390,7 @@ suite('Debugging - launch.json Updater Service', () => { document.verifyAll(); assert.strictEqual(debugConfigInserted, true); }); - test('If cursor is at the begining of line 1 then there is no comma before cursor', async () => { + test('If cursor is at the beginning of line 1 then there is no comma before cursor', async () => { sandbox.restore(); const document = typemoq.Mock.ofType(); const position = new Position(1, 0); diff --git a/src/test/unittest/extensionInit.unit.test.ts b/src/test/unittest/extensionInit.unit.test.ts index 25487683..8ed5739d 100644 --- a/src/test/unittest/extensionInit.unit.test.ts +++ b/src/test/unittest/extensionInit.unit.test.ts @@ -33,7 +33,7 @@ suite('Debugging - register Debugging', () => { let loggingFactory: IDebugSessionLoggingFactory; let debuggerPromptFactory: IOutdatedDebuggerPromptFactory; let descriptorFactory: IDebugAdapterDescriptorFactory; - let persistantState: IPersistentStateFactory; + let persistentState: IPersistentStateFactory; let debugSessionTelemetry: vscode.DebugAdapterTrackerFactory; let completionProvider: LaunchJsonCompletionProvider; @@ -48,9 +48,9 @@ suite('Debugging - register Debugging', () => { debuggerPromptFactory = new OutdatedDebuggerPromptFactory(); debugSessionTelemetry = new DebugSessionTelemetry(); completionProvider = new LaunchJsonCompletionProvider(); - persistantState = new PersistentStateFactory(context.object.globalState, context.object.workspaceState); + persistentState = new PersistentStateFactory(context.object.globalState, context.object.workspaceState); registerCompletionItemProviderStub = sinon.stub(vscode.languages, 'registerCompletionItemProvider'); - descriptorFactory = new DebugAdapterDescriptorFactory(persistantState); + descriptorFactory = new DebugAdapterDescriptorFactory(persistentState); context.setup((c) => c.subscriptions).returns(() => []); }); teardown(() => { diff --git a/src/test/unittest/utils.ts b/src/test/unittest/utils.ts index 858982ac..66b3fd77 100644 --- a/src/test/unittest/utils.ts +++ b/src/test/unittest/utils.ts @@ -72,7 +72,7 @@ class DebugAdapterTracker { // * onError(error: Error): void; private onDAPMessage(src: DAPSource, msg: DebugProtocol.ProtocolMessage) { - // Unomment this to see the DAP messages sent between VS Code and debugpy: + // Uncomment this to see the DAP messages sent between VS Code and debugpy: //console.log(`| DAP (${src === 'vscode' ? 'VS Code -> debugpy' : 'debugpy -> VS Code'})\n`, msg, '\n| DAP'); // See: https://microsoft.github.io/debug-adapter-protocol/specification @@ -194,7 +194,7 @@ class DebuggerSession { // Un-comment this to see the debug config used in this session: //console.log('|', session.config, '|'); const started = await vscode.debug.startDebugging(this.wsRoot, this.config); - expect(started).to.be.equal(true, 'Debugger did not sart'); + expect(started).to.be.equal(true, 'Debugger did not start'); this.raw = debuggers.getSession(this.id); expect(this.raw).to.not.equal(undefined, 'session not set'); }