refactor: transition to opaque workspace identifiers

This commit is contained in:
Mohamed Boudra
2026-04-15 17:59:09 +07:00
parent beeb315c8d
commit e6044264e2
34 changed files with 462 additions and 382 deletions
@@ -239,7 +239,7 @@ describe("DaemonClient", () => {
wrapSessionMessage({
type: "workspace_setup_progress",
payload: {
workspaceId: "/tmp/project/.paseo/worktrees/feature-a",
workspaceId: "ws-feature-a",
status: "running",
detail: {
type: "worktree_setup",
@@ -264,9 +264,9 @@ describe("DaemonClient", () => {
expect(events).toContainEqual({
type: "workspace_setup_progress",
workspaceId: "/tmp/project/.paseo/worktrees/feature-a",
workspaceId: "ws-feature-a",
payload: {
workspaceId: "/tmp/project/.paseo/worktrees/feature-a",
workspaceId: "ws-feature-a",
status: "running",
detail: {
type: "worktree_setup",
@@ -309,7 +309,7 @@ describe("DaemonClient", () => {
const createPromise = client.createAgent({
provider: "codex",
cwd: "/tmp/project/.paseo/worktrees/feature-a",
workspaceId: "/tmp/project/.paseo/worktrees/feature-a",
workspaceId: "ws-feature-a",
title: "Compat agent",
modeId: "default",
});
@@ -326,7 +326,7 @@ describe("DaemonClient", () => {
expect(request.message).toEqual(
expect.objectContaining({
type: "create_agent_request",
workspaceId: "/tmp/project/.paseo/worktrees/feature-a",
workspaceId: "ws-feature-a",
}),
);
+2 -2
View File
@@ -210,7 +210,7 @@ export type CreateAgentRequestOptions = {
config?: AgentSessionConfig;
provider?: AgentProvider;
cwd?: string;
workspaceId?: string | number;
workspaceId?: string;
initialPrompt?: string;
clientMessageId?: string;
outputSchema?: Record<string, unknown>;
@@ -1400,7 +1400,7 @@ export class DaemonClient {
}
async archiveWorkspace(
workspaceId: string | number,
workspaceId: string,
requestId?: string,
): Promise<ArchiveWorkspacePayload> {
return this.sendCorrelatedSessionRequest({