@@ -5,11 +5,9 @@ import { inject, injectable } from 'inversify';
5
5
import { IExtensionSingleActivationService } from '../activation/types' ;
6
6
import { IApplicationShell , ICommandManager , IWorkspaceService } from '../common/application/types' ;
7
7
import { Commands } from '../common/constants' ;
8
- import { ContextKey } from '../common/contextKey' ;
9
- import { NativeTensorBoard } from '../common/experiments/groups' ;
10
8
import { traceError , traceInfo } from '../common/logger' ;
11
9
import { IProcessServiceFactory } from '../common/process/types' ;
12
- import { IDisposableRegistry , IExperimentService , IInstaller } from '../common/types' ;
10
+ import { IDisposableRegistry , IInstaller } from '../common/types' ;
13
11
import { TensorBoard } from '../common/utils/localize' ;
14
12
import { IInterpreterService } from '../interpreter/contracts' ;
15
13
import { sendTelemetryEvent } from '../telemetry' ;
@@ -26,34 +24,25 @@ export class TensorBoardSessionProvider implements IExtensionSingleActivationSer
26
24
@inject ( IWorkspaceService ) private readonly workspaceService : IWorkspaceService ,
27
25
@inject ( ICommandManager ) private readonly commandManager : ICommandManager ,
28
26
@inject ( IDisposableRegistry ) private readonly disposables : IDisposableRegistry ,
29
- @inject ( IExperimentService ) private readonly experimentService : IExperimentService ,
30
27
@inject ( IProcessServiceFactory ) private readonly processServiceFactory : IProcessServiceFactory ,
31
28
) { }
32
29
33
30
public async activate ( ) : Promise < void > {
34
- this . activateInternal ( ) . ignoreErrors ( ) ;
35
- }
36
-
37
- private async activateInternal ( ) {
38
- if ( await this . experimentService . inExperiment ( NativeTensorBoard . experiment ) ) {
39
- this . disposables . push (
40
- this . commandManager . registerCommand (
41
- Commands . LaunchTensorBoard ,
42
- (
43
- entrypoint : TensorBoardEntrypoint = TensorBoardEntrypoint . palette ,
44
- trigger : TensorBoardEntrypointTrigger = TensorBoardEntrypointTrigger . palette ,
45
- ) => {
46
- sendTelemetryEvent ( EventName . TENSORBOARD_SESSION_LAUNCH , undefined , {
47
- trigger,
48
- entrypoint,
49
- } ) ;
50
- return this . createNewSession ( ) ;
51
- } ,
52
- ) ,
53
- ) ;
54
- const contextKey = new ContextKey ( 'python.isInNativeTensorBoardExperiment' , this . commandManager ) ;
55
- contextKey . set ( true ) . ignoreErrors ( ) ;
56
- }
31
+ this . disposables . push (
32
+ this . commandManager . registerCommand (
33
+ Commands . LaunchTensorBoard ,
34
+ (
35
+ entrypoint : TensorBoardEntrypoint = TensorBoardEntrypoint . palette ,
36
+ trigger : TensorBoardEntrypointTrigger = TensorBoardEntrypointTrigger . palette ,
37
+ ) => {
38
+ sendTelemetryEvent ( EventName . TENSORBOARD_SESSION_LAUNCH , undefined , {
39
+ trigger,
40
+ entrypoint,
41
+ } ) ;
42
+ return this . createNewSession ( ) ;
43
+ } ,
44
+ ) ,
45
+ ) ;
57
46
}
58
47
59
48
private async createNewSession ( ) : Promise < TensorBoardSession | undefined > {
0 commit comments