Skip to content

Commit

Permalink
removed Notebook creation from extension since it is moving to built-…
Browse files Browse the repository at this point in the history
…in (#9311)

* removed Notebook creation from extension since it is moving to built-in

* removed 3rd party integration tests

* added news file

* updated vscode engine version

* fixed walkthrough text and re-deleted unused file
  • Loading branch information
amunger authored Mar 15, 2022
1 parent 317507a commit 502897a
Show file tree
Hide file tree
Showing 10 changed files with 5 additions and 229 deletions.
1 change: 1 addition & 0 deletions news/2 Fixes/9250.md
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
Removed the "Create new Jupyter notebook" Command since it has moved to the built-in ipynb extension in VS Code.
25 changes: 4 additions & 21 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@
"theme": "light"
},
"engines": {
"vscode": "^1.64.0"
"vscode": "^1.66.0-insider"
},
"keywords": [
"jupyter",
Expand Down Expand Up @@ -55,7 +55,6 @@
"onCommand:jupyter.exportToHTML",
"onCommand:jupyter.exportToPDF",
"onCommand:jupyter.notebookeditor.export",
"onCommand:jupyter.createnewnotebook",
"onCommand:jupyter.createnewinteractive",
"onCommand:jupyter.importnotebook",
"onCommand:jupyter.importnotebookfile",
Expand Down Expand Up @@ -89,15 +88,15 @@
"when": "false",
"steps": [
{
"id": "jupyter.createNewNotebook",
"id": "ipynb.newUntitledIpynb",
"title": "Create or open a Jupyter Notebook",
"description": "Right click in the file explorer and create a new file with an .ipynb extension. Or, open the [Command Palette](command:workbench.action.showCommands) and run the command \n``Jupyter: Create New Jupyter Notebook``.\n[Create New Jupyter Notebook](command:toSide:jupyter.createnewnotebook)\n If you have an existing project, you can also [open a folder](command:toSide:workbench.action.files.openFolder) and/or clone a project from GitHub: [clone a Git repository](command:toSide:git.clone).",
"description": "Right click in the file explorer and create a new file with an .ipynb extension. Or, open the [Command Palette](command:workbench.action.showCommands) and run the command \n``Create: New Jupyter Notebook``.\n[Create New Jupyter Notebook](command:toSide:ipynb.newUntitledIpynb)\n If you have an existing project, you can also [open a folder](command:toSide:workbench.action.files.openFolder) and/or clone a project from GitHub: [clone a Git repository](command:toSide:git.clone).",
"media": {
"svg": "resources/walkthroughs/opennotebook.svg",
"altText": "Creating a new Jupyter notebook"
},
"completionEvents": [
"onCommand:jupyter.createnewnotebook",
"onCommand:ipynb.newUntitledIpynb",
"onCommand:jupyter.createnewinteractive",
"onCommand:workbench.action.files.openFolder",
"onCommand:workbench.action.files.openFileFolder"
Expand Down Expand Up @@ -702,12 +701,6 @@
"title": "%jupyter.command.jupyter.addcellbelow.title%",
"category": "Jupyter"
},
{
"command": "jupyter.createnewnotebook",
"title": "%jupyter.command.jupyter.createnewnotebook.title%",
"shortTitle": "%jupyter.command.jupyter.createnewnotebook.shortTitle%",
"category": "Jupyter"
},
{
"command": "jupyter.scrolltocell",
"title": "%jupyter.command.jupyter.scrolltocell.title%",
Expand Down Expand Up @@ -1037,11 +1030,6 @@
"group": "Jupyter"
}
],
"file/newFile": [
{
"command": "jupyter.createnewnotebook"
}
],
"commandPalette": [
{
"command": "jupyter.replayPylanceLog",
Expand Down Expand Up @@ -1385,11 +1373,6 @@
"category": "Jupyter",
"when": "jupyter.hascodecells && jupyter.ispythonornativeactive"
},
{
"command": "jupyter.createnewnotebook",
"title": "%jupyter.command.jupyter.createnewnotebook.title%",
"category": "Jupyter"
},
{
"command": "jupyter.runtoline",
"category": "Jupyter",
Expand Down
2 changes: 0 additions & 2 deletions package.nls.json
Original file line number Diff line number Diff line change
Expand Up @@ -122,8 +122,6 @@
"jupyter.command.jupyter.collapseallcells.shorttitle": "Collapse",
"jupyter.command.jupyter.addcellbelow.title": "Add Empty Cell to File",
"jupyter.command.jupyter.scrolltocell.title": "Scroll Cell Into View",
"jupyter.command.jupyter.createnewnotebook.title": "Create New Jupyter Notebook",
"jupyter.command.jupyter.createnewnotebook.shortTitle": "Jupyter Notebook",
"jupyter.command.jupyter.selectJupyterInterpreter.title": "Select Interpreter to start Jupyter server",
"jupyter.command.jupyter.createGitHubIssue.title": "Create GitHub Issue",
"jupyter.command.jupyter.submitGitHubIssue.title": "Submit GitHub Issue",
Expand Down
1 change: 0 additions & 1 deletion package.nls.zh-cn.json
Original file line number Diff line number Diff line change
Expand Up @@ -99,7 +99,6 @@
"jupyter.command.jupyter.collapseallcells.shorttitle": "折叠",
"jupyter.command.jupyter.addcellbelow.title": "添加空单元到文件",
"jupyter.command.jupyter.scrolltocell.title": "滚动至单元",
"jupyter.command.jupyter.createnewnotebook.title": "创建新的空白 Jupyter 笔记本",
"jupyter.command.jupyter.selectJupyterInterpreter.title": "选择解释器来启动 Jupyter 服务器",
"jupyter.command.jupyter.createGitHubIssue.title": "创建 GitHub Issue",
"jupyter.command.jupyter.submitGitHubIssue.title": "提交 GitHub Issue",
Expand Down
1 change: 0 additions & 1 deletion package.nls.zh-tw.json
Original file line number Diff line number Diff line change
Expand Up @@ -77,7 +77,6 @@
"jupyter.command.jupyter.runfromline.title": "在互動式視窗中執行到此行",
"jupyter.command.jupyter.execSelectionInteractive.title": "在互動式視窗中執行選取內容/行",
"jupyter.command.jupyter.clearSavedJupyterUris.title": "清除遠端 Jupyter 伺服器清單",
"jupyter.command.jupyter.createnewnotebook.title": "新增 Jupyter Notebook",
"jupyter.command.jupyter.openOutlineView.title": "顯示目錄(大綱欄位)",
"jupyter.command.jupyter.openOutlineView.shorttitle": "大綱",
"jupyter.command.jupyter.debug.title": "偵錯",
Expand Down
1 change: 0 additions & 1 deletion src/client/common/application/commands.ts
Original file line number Diff line number Diff line change
Expand Up @@ -52,7 +52,6 @@ interface ICommandNameWithoutArgumentTypeMapping {
[DSCommands.CollapseAllCells]: [];
[DSCommands.ExportOutputAsNotebook]: [];
[DSCommands.AddCellBelow]: [];
[DSCommands.CreateNewNotebook]: [];
[DSCommands.EnableDebugLogging]: [];
[DSCommands.ResetLoggingLevel]: [];
[DSCommands.OpenVariableView]: [];
Expand Down
7 changes: 0 additions & 7 deletions src/interactive-window/commands/commandRegistry.ts
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,6 @@ import { DebugProtocol } from 'vscode-debugprotocol';
import { IShowDataViewerFromVariablePanel } from '../../extension/messageTypes';
import { IKernelProvider } from '../../kernels/types';
import { convertDebugProtocolVariableToIJupyterVariable } from '../../kernels/variables/debuggerVariables';
import { NotebookCreator } from '../../notebooks/notebookCreator';
import { DataViewerChecker } from '../../webviews/dataviewer/dataViewerChecker';
import { ICommandNameArgumentTypeMapping } from '../../client/common/application/commands';
import {
Expand Down Expand Up @@ -66,7 +65,6 @@ export class CommandRegistry implements IDisposable {
@inject(IDataViewerFactory) private readonly dataViewerFactory: IDataViewerFactory,
@inject(IJupyterServerUriStorage) private readonly serverUriStorage: IJupyterServerUriStorage,
@inject(IJupyterVariables) @named(Identifiers.DEBUGGER_VARIABLES) private variableProvider: IJupyterVariables,
@inject(NotebookCreator) private readonly nativeNotebookCreator: NotebookCreator,
@inject(IWorkspaceService) private readonly workspace: IWorkspaceService,
@inject(IInteractiveWindowProvider) private readonly interactiveWindowProvider: IInteractiveWindowProvider,
@inject(IDataScienceErrorHandler) private readonly errorHandler: IDataScienceErrorHandler,
Expand Down Expand Up @@ -96,7 +94,6 @@ export class CommandRegistry implements IDisposable {
this.registerCommand(Commands.GotoNextCellInFile, this.gotoNextCellInFile);
this.registerCommand(Commands.GotoPrevCellInFile, this.gotoPrevCellInFile);
this.registerCommand(Commands.AddCellBelow, this.addCellBelow);
this.registerCommand(Commands.CreateNewNotebook, this.createNewNotebook);
this.registerCommand(Commands.ViewJupyterOutput, this.viewJupyterOutput);
this.registerCommand(Commands.LatestExtension, this.openPythonExtensionPage);
this.registerCommand(Commands.EnableDebugLogging, this.enableDebugLogging);
Expand Down Expand Up @@ -482,10 +479,6 @@ export class CommandRegistry implements IDisposable {
}
}

private async createNewNotebook(): Promise<void> {
await this.nativeNotebookCreator.createNewNotebook();
}

private viewJupyterOutput() {
this.jupyterOutput.show(true);
}
Expand Down
58 changes: 0 additions & 58 deletions src/notebooks/notebookCreator.ts

This file was deleted.

4 changes: 0 additions & 4 deletions src/notebooks/serviceRegistry.ts
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,6 @@ import { NotebookCellBangInstallDiagnosticsProvider } from '../intellisense/diag
import { EmptyNotebookCellLanguageService } from '../intellisense/emptyNotebookCellLanguageService';
import { IntellisenseProvider } from '../intellisense/intellisenseProvider';
import { PythonKernelCompletionProvider } from '../intellisense/pythonKernelCompletionProvider';
import { CreationOptionService } from '../kernels/common/creationOptionsService';
import { KernelProvider } from '../kernels/kernelProvider';
import { IKernelProvider } from '../kernels/types';
import { KernelFilterService } from './controllers/kernelFilter/kernelFilterService';
Expand All @@ -22,7 +21,6 @@ import { NotebookControllerManager } from './controllers/notebookControllerManag
import { RemoteSwitcher } from './controllers/remoteSwitcher';
import { CellOutputDisplayIdTracker } from './execution/cellDisplayIdTracker';
import { NotebookCommandListener } from './notebookCommandListener';
import { NotebookCreator } from './notebookCreator';
import { NotebookEditorProvider } from './notebookEditorProvider';
import { ErrorRendererCommunicationHandler } from './outputs/errorRendererComms';
import { PlotSaveHandler } from './outputs/plotSaveHandler';
Expand Down Expand Up @@ -57,8 +55,6 @@ export function registerTypes(serviceManager: IServiceManager) {
);
serviceManager.addSingleton<INotebookLanguageClientProvider>(INotebookLanguageClientProvider, IntellisenseProvider);
serviceManager.addBinding(INotebookLanguageClientProvider, IExtensionSingleActivationService);
serviceManager.addSingleton<CreationOptionService>(CreationOptionService, CreationOptionService);
serviceManager.addSingleton<NotebookCreator>(NotebookCreator, NotebookCreator);
serviceManager.addSingleton<INotebookControllerManager>(INotebookControllerManager, NotebookControllerManager);
serviceManager.addSingleton<PlotSaveHandler>(PlotSaveHandler, PlotSaveHandler);
serviceManager.addSingleton<PlotViewHandler>(PlotViewHandler, PlotViewHandler);
Expand Down
134 changes: 0 additions & 134 deletions src/test/datascience/notebook/creation/notebookCreation.vscode.test.ts

This file was deleted.

0 comments on commit 502897a

Please sign in to comment.