Wire pipeline DAG execution to manager with events and project context
This commit is contained in:
@@ -161,6 +161,10 @@ export class FileSystemStateContextManager {
|
||||
return this.rootDirectory;
|
||||
}
|
||||
|
||||
getSessionStatePath(sessionId: string): string {
|
||||
return toStatePath(this.rootDirectory, sessionId);
|
||||
}
|
||||
|
||||
async initializeSession(
|
||||
sessionId: string,
|
||||
initialState: Partial<StoredSessionState> = {},
|
||||
@@ -205,6 +209,7 @@ export class FileSystemStateContextManager {
|
||||
flags?: Record<string, boolean>;
|
||||
metadata?: JsonObject;
|
||||
historyEvent?: SessionHistoryEntry;
|
||||
historyEvents?: SessionHistoryEntry[];
|
||||
},
|
||||
): Promise<StoredSessionState> {
|
||||
const current = await this.readState(sessionId);
|
||||
@@ -218,6 +223,9 @@ export class FileSystemStateContextManager {
|
||||
if (patch.historyEvent) {
|
||||
current.history.push(patch.historyEvent);
|
||||
}
|
||||
if (patch.historyEvents && patch.historyEvents.length > 0) {
|
||||
current.history.push(...patch.historyEvents);
|
||||
}
|
||||
|
||||
await this.writeState(sessionId, current);
|
||||
return current;
|
||||
|
||||
Reference in New Issue
Block a user