Skip to content

Commit cf6ddc2

Browse files
test(server): JSONL history store tests pass on macOS temp paths
Co-Authored-By: Claude Fable 5.2 <[email protected]>
1 parent ce43a26 commit cf6ddc2

1 file changed

Lines changed: 7 additions & 7 deletions

File tree

‎apps/server/src/project/externalHistory/JsonlHistoryStore.test.ts‎

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@ it.layer(Layer.mergeAll(NodeServices.layer, NodeCrypto.layer))("local JSONL hist
1414
() =>
1515
Effect.gen(function* () {
1616
const fs = yield* FileSystem.FileSystem;
17-
const root = yield* fs.makeTempDirectoryScoped();
17+
const root = yield* fs.realPath(yield* fs.makeTempDirectoryScoped());
1818
const project = `${root}/projects/project`;
1919
yield* fs.makeDirectory(project, { recursive: true });
2020
const file = `${project}/session.jsonl`;
@@ -105,7 +105,7 @@ it.layer(Layer.mergeAll(NodeServices.layer, NodeCrypto.layer))("local JSONL hist
105105
it.effect("keeps valid messages around malformed and undecodable records", () =>
106106
Effect.gen(function* () {
107107
const fs = yield* FileSystem.FileSystem;
108-
const root = yield* fs.makeTempDirectoryScoped();
108+
const root = yield* fs.realPath(yield* fs.makeTempDirectoryScoped());
109109
const project = `${root}/projects/project`;
110110
yield* fs.makeDirectory(project, { recursive: true });
111111
const message = (uuid: string, content = "needle") =>
@@ -141,7 +141,7 @@ it.layer(Layer.mergeAll(NodeServices.layer, NodeCrypto.layer))("local JSONL hist
141141
it.effect("isolates unreadable entries and retries incomplete listings after recovery", () =>
142142
Effect.gen(function* () {
143143
const fs = yield* FileSystem.FileSystem;
144-
const root = yield* fs.makeTempDirectoryScoped();
144+
const root = yield* fs.realPath(yield* fs.makeTempDirectoryScoped());
145145
const directory = `${root}/projects`;
146146
for (const project of ["good", "blocked"]) {
147147
yield* fs.makeDirectory(`${directory}/${project}`, { recursive: true });
@@ -215,7 +215,7 @@ it.layer(Layer.mergeAll(NodeServices.layer, NodeCrypto.layer))("local JSONL hist
215215
it.effect("searches sessions larger than the old allocation cap and verifies their source", () =>
216216
Effect.gen(function* () {
217217
const fs = yield* FileSystem.FileSystem;
218-
const root = yield* fs.makeTempDirectoryScoped();
218+
const root = yield* fs.realPath(yield* fs.makeTempDirectoryScoped());
219219
const project = `${root}/projects/project`;
220220
yield* fs.makeDirectory(project, { recursive: true });
221221
const file = `${project}/large.jsonl`;
@@ -262,7 +262,7 @@ it.layer(Layer.mergeAll(NodeServices.layer, NodeCrypto.layer))("local JSONL hist
262262
it.effect("finds queries split across read chunks and queries that JSON escapes", () =>
263263
Effect.gen(function* () {
264264
const fs = yield* FileSystem.FileSystem;
265-
const root = yield* fs.makeTempDirectoryScoped();
265+
const root = yield* fs.realPath(yield* fs.makeTempDirectoryScoped());
266266
const project = `${root}/projects/project`;
267267
yield* fs.makeDirectory(project, { recursive: true });
268268
const head = '{"type":"user","uuid":"split","message":{"content":"';
@@ -298,7 +298,7 @@ it.layer(Layer.mergeAll(NodeServices.layer, NodeCrypto.layer))("local JSONL hist
298298
it.effect("refreshes newest-first order when an existing session is appended", () =>
299299
Effect.gen(function* () {
300300
const fs = yield* FileSystem.FileSystem;
301-
const root = yield* fs.makeTempDirectoryScoped();
301+
const root = yield* fs.realPath(yield* fs.makeTempDirectoryScoped());
302302
const project = `${root}/projects/project`;
303303
yield* fs.makeDirectory(project, { recursive: true });
304304
const message = (uuid: string) =>
@@ -330,7 +330,7 @@ it.layer(Layer.mergeAll(NodeServices.layer, NodeCrypto.layer))("local JSONL hist
330330
it.effect("excludes T3 Claude sessions and follows the active Pi branch", () =>
331331
Effect.gen(function* () {
332332
const fs = yield* FileSystem.FileSystem;
333-
const root = yield* fs.makeTempDirectoryScoped();
333+
const root = yield* fs.realPath(yield* fs.makeTempDirectoryScoped());
334334
const project = `${root}/projects/project`;
335335
yield* fs.makeDirectory(project, { recursive: true });
336336
yield* fs.writeFileString(

0 commit comments

Comments
 (0)