Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions src/kernels/deepnote/deepnoteSharedToolkitInstaller.node.ts
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ import { IOutputChannel, IExtensionContext } from '../../platform/common/types';
import { STANDARD_OUTPUT_CHANNEL } from '../../platform/common/constants';
import { IFileSystem } from '../../platform/common/platform/types';
import { Cancellation } from '../../platform/common/cancellation';
import { DEEPNOTE_TOOLKIT_WHEEL_URL, DEEPNOTE_TOOLKIT_VERSION } from './types';
import { DEEPNOTE_TOOLKIT_VERSION } from './types';

/**
* Manages a shared installation of deepnote-toolkit in a versioned extension directory.
Expand Down Expand Up @@ -220,7 +220,7 @@ export class DeepnoteSharedToolkitInstaller {
'--target',
this.sharedInstallationPath.fsPath,
'--upgrade',
`deepnote-toolkit[server] @ ${DEEPNOTE_TOOLKIT_WHEEL_URL}`
`deepnote-toolkit[server]==${DEEPNOTE_TOOLKIT_VERSION}`
],
{ throwOnStdErr: false }
);
Expand Down
10 changes: 5 additions & 5 deletions src/kernels/deepnote/deepnoteToolkitInstaller.node.ts
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
import { inject, injectable, named } from 'inversify';
import { CancellationToken, Uri, workspace } from 'vscode';
import { PythonEnvironment } from '../../platform/pythonEnvironments/info';
import { IDeepnoteToolkitInstaller, DEEPNOTE_TOOLKIT_WHEEL_URL, DEEPNOTE_TOOLKIT_VERSION } from './types';
import { IDeepnoteToolkitInstaller, DEEPNOTE_TOOLKIT_VERSION } from './types';
import { IProcessServiceFactory } from '../../platform/common/process/types.node';
import { logger } from '../../platform/logging';
import { IOutputChannel, IExtensionContext } from '../../platform/common/types';
Expand Down Expand Up @@ -189,7 +189,7 @@ export class DeepnoteToolkitInstaller implements IDeepnoteToolkitInstaller {
Cancellation.throwIfCanceled(token);

// Install deepnote-toolkit and ipykernel in venv
logger.info(`Installing deepnote-toolkit and ipykernel in venv from ${DEEPNOTE_TOOLKIT_WHEEL_URL}`);
logger.info(`Installing deepnote-toolkit (${DEEPNOTE_TOOLKIT_VERSION}) and ipykernel in venv from PyPI`);
this.outputChannel.appendLine('Installing deepnote-toolkit and ipykernel...');

const installResult = await venvProcessService.exec(
Expand All @@ -199,7 +199,7 @@ export class DeepnoteToolkitInstaller implements IDeepnoteToolkitInstaller {
'pip',
'install',
'--upgrade',
`deepnote-toolkit[server] @ ${DEEPNOTE_TOOLKIT_WHEEL_URL}`,
`deepnote-toolkit[server]==${DEEPNOTE_TOOLKIT_VERSION}`,
'ipykernel'
],
{ throwOnStdErr: false }
Expand Down Expand Up @@ -260,7 +260,7 @@ export class DeepnoteToolkitInstaller implements IDeepnoteToolkitInstaller {
throw new DeepnoteToolkitInstallError(
venvInterpreter.uri.fsPath,
venvPath.fsPath,
DEEPNOTE_TOOLKIT_WHEEL_URL,
DEEPNOTE_TOOLKIT_VERSION,
installResult.stdout || '',
installResult.stderr || 'Package installation completed but verification failed'
);
Expand All @@ -278,7 +278,7 @@ export class DeepnoteToolkitInstaller implements IDeepnoteToolkitInstaller {
throw new DeepnoteToolkitInstallError(
baseInterpreter.uri.fsPath,
venvPath.fsPath,
DEEPNOTE_TOOLKIT_WHEEL_URL,
DEEPNOTE_TOOLKIT_VERSION,
'',
ex instanceof Error ? ex.message : String(ex),
ex instanceof Error ? ex : undefined
Expand Down
3 changes: 1 addition & 2 deletions src/kernels/deepnote/types.ts
Original file line number Diff line number Diff line change
Expand Up @@ -156,7 +156,6 @@ export interface IDeepnoteKernelAutoSelector {
ensureKernelSelected(notebook: vscode.NotebookDocument, token?: vscode.CancellationToken): Promise<void>;
}

export const DEEPNOTE_TOOLKIT_VERSION = '0.2.30.post30';
export const DEEPNOTE_TOOLKIT_WHEEL_URL = `https://deepnote-staging-runtime-artifactory.s3.amazonaws.com/deepnote-toolkit-packages/${DEEPNOTE_TOOLKIT_VERSION}/deepnote_toolkit-${DEEPNOTE_TOOLKIT_VERSION}-py3-none-any.whl`;
export const DEEPNOTE_TOOLKIT_VERSION = '1.0.0rc2';
export const DEEPNOTE_DEFAULT_PORT = 8888;
export const DEEPNOTE_NOTEBOOK_TYPE = 'deepnote';
4 changes: 2 additions & 2 deletions src/platform/errors/deepnoteKernelErrors.ts
Original file line number Diff line number Diff line change
Expand Up @@ -99,7 +99,7 @@ export class DeepnoteToolkitInstallError extends DeepnoteKernelError {
constructor(
public readonly pythonPath: string,
public readonly venvPath: string,
public readonly packageUrl: string,
public readonly packageVersion: string,
public readonly stdout: string,
public readonly stderr: string,
cause?: Error
Expand All @@ -112,7 +112,7 @@ export class DeepnoteToolkitInstallError extends DeepnoteKernelError {
this.technicalDetails = [
`Python interpreter: ${pythonPath}`,
`Virtual environment: ${venvPath}`,
`Package URL: ${packageUrl}`,
`Package version: ${packageVersion}`,
stdout ? `Installation output:\n${stdout}` : '',
stderr ? `Error output:\n${stderr}` : 'No error output available',
cause ? `Underlying error: ${cause.message}` : ''
Expand Down