Skip to content

Commit d588462

Browse files
committed
imports tasks, setup-tasks and system in pint/index.ts
1 parent d175ef8 commit d588462

File tree

2 files changed

+17
-3
lines changed

2 files changed

+17
-3
lines changed

src/PintClient/index.ts

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,7 @@ import { SandboxSession } from "../types";
44
import { Disposable } from "../utils/disposable";
55
import { Client, createClient, createConfig } from "../api-clients/pint/client";
66
import {PintFsClient} from "./fs";
7+
import { PintClientTasks, PintClientSetup, PintClientSystem } from "./tasks";
78
import {
89
IAgentClient,
910
IAgentClientPorts,
@@ -117,9 +118,9 @@ export class PintClient implements IAgentClient {
117118
this.ports = new PintPortsClient(apiClient, this.sandboxId);
118119
this.shells = {} as IAgentClientShells; // Not implemented for Pint
119120
this.fs = new PintFsClient(apiClient);
120-
this.tasks = {} as IAgentClientTasks; // Not implemented for Pint
121-
this.setup = {} as IAgentClientSetup; // Not implemented for Pint
122-
this.system = {} as IAgentClientSystem; // Not implemented for Pint
121+
this.tasks = new PintClientTasks(apiClient);
122+
this.setup = new PintClientSetup(apiClient);
123+
this.system = new PintClientSystem(apiClient);
123124
}
124125

125126
ping(): void {}

src/PintClient/tasks.ts

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,7 @@
11
import {
22
IAgentClientTasks,
33
IAgentClientSetup,
4+
IAgentClientSystem,
45
} from "../agent-client-interface";
56
import { Client } from "../api-clients/pint/client";
67
import {
@@ -11,6 +12,7 @@ import {
1112
} from "../api-clients/pint";
1213
import { task, setup } from "../pitcher-protocol";
1314
import { Emitter } from "../utils/event";
15+
import { system } from "../pitcher-protocol";
1416
export class PintClientTasks implements IAgentClientTasks {
1517
private onTaskUpdateEmitter = new Emitter<task.TaskDTO>();
1618
onTaskUpdate = this.onTaskUpdateEmitter.event;
@@ -222,4 +224,15 @@ export class PintClientSetup implements IAgentClientSetup {
222224

223225
return progress;
224226
}
227+
}
228+
229+
export class PintClientSystem implements IAgentClientSystem {
230+
private onInitStatusUpdateEmitter = new Emitter<system.InitStatus>();
231+
onInitStatusUpdate = this.onInitStatusUpdateEmitter.event;
232+
233+
constructor(private apiClient: Client) {}
234+
235+
async update(): Promise<Record<string, undefined>> {
236+
return {};
237+
}
225238
}

0 commit comments

Comments
 (0)