From 949db54f05db2c7c26fdc23a61639ad250d35374 Mon Sep 17 00:00:00 2001 From: bracesproul Date: Mon, 9 Dec 2024 16:46:33 -0800 Subject: [PATCH] chore: lint files --- libs/checkpoint/src/memory.ts | 32 ++++++++++++++----------- libs/langgraph/src/tests/pregel.test.ts | 6 +++-- 2 files changed, 22 insertions(+), 16 deletions(-) diff --git a/libs/checkpoint/src/memory.ts b/libs/checkpoint/src/memory.ts index 1a10b3df..415f9120 100644 --- a/libs/checkpoint/src/memory.ts +++ b/libs/checkpoint/src/memory.ts @@ -78,13 +78,15 @@ export class MemorySaver extends BaseCheckpointSaver { pending_sends, }; const pendingWrites: CheckpointPendingWrite[] = await Promise.all( - Object.values(this.writes[key] || {}).map(async ([taskId, channel, value]) => { - return [ - taskId, - channel, - await this.serde.loadsTyped("json", value), - ]; - }) + Object.values(this.writes[key] || {}).map( + async ([taskId, channel, value]) => { + return [ + taskId, + channel, + await this.serde.loadsTyped("json", value), + ]; + } + ) ); const checkpointTuple: CheckpointTuple = { config, @@ -126,13 +128,15 @@ export class MemorySaver extends BaseCheckpointSaver { pending_sends, }; const pendingWrites: CheckpointPendingWrite[] = await Promise.all( - Object.values(this.writes[key] || {}).map(async ([taskId, channel, value]) => { - return [ - taskId, - channel, - await this.serde.loadsTyped("json", value), - ]; - }) + Object.values(this.writes[key] || {}).map( + async ([taskId, channel, value]) => { + return [ + taskId, + channel, + await this.serde.loadsTyped("json", value), + ]; + } + ) ); const checkpointTuple: CheckpointTuple = { config: { diff --git a/libs/langgraph/src/tests/pregel.test.ts b/libs/langgraph/src/tests/pregel.test.ts index 96eba684..5d6fa01c 100644 --- a/libs/langgraph/src/tests/pregel.test.ts +++ b/libs/langgraph/src/tests/pregel.test.ts @@ -9188,7 +9188,7 @@ export function runPregelTests( }); }); - it.only("can throw a node interrupt multiple times in a single node", async () => { + it("can throw a node interrupt multiple times in a single node", async () => { const GraphAnnotation = Annotation.Root({ myKey: Annotation({ reducer: (a, b) => a + b, @@ -9251,7 +9251,9 @@ export function runPregelTests( config ) ); - expect(thirdResult[thirdResult.length - 1].myKey).toEqual("DEanswer 1 answer 2"); + expect(thirdResult[thirdResult.length - 1].myKey).toEqual( + "DEanswer 1 answer 2" + ); const thirdState = await graph.getState(config); expect(thirdState.tasks).toHaveLength(0); });