diff --git a/extensions/notebook/src/dialog/configurePython/configurePythonWizard.ts b/extensions/notebook/src/dialog/configurePython/configurePythonWizard.ts index 7df8efb7af..6688d50c4c 100644 --- a/extensions/notebook/src/dialog/configurePython/configurePythonWizard.ts +++ b/extensions/notebook/src/dialog/configurePython/configurePythonWizard.ts @@ -99,6 +99,10 @@ export class ConfigurePythonWizard { }); this._wizard.registerNavigationValidator(async (info) => { + // The pages have not been registered yet + if (pages.size === 0) { + return false; + } let lastPage = pages.get(info.lastPage); let newPage = pages.get(info.newPage);