authorgravatar for julius0216@outlook.comJulius Marminge <julius0216@outlook.com> 2026-04-01 08:57:31-07:00
committergravatar for noreply@github.comGitHub <noreply@github.com> 2026-04-01 15:57:31+00:00
log67ca528fea4a90638811105929248fe565d0a27e
tree76fad0310b50f5f0f792a83ffe7a78c75ebeefb5
parent6d9b21c5d042ff992b26493563096459cb9158ac
signature Signed by PGP key B5690EEEBB952194

[codex] migrate Effect.fn in apps/server/src/provider/Layers/ClaudeProvider.ts (#1634)

Co-authored-by: codex <codex@users.noreply.github.com>

1 files changed, 9 insertions(+), 10 deletions(-)

apps/server/src/provider/Layers/ClaudeProvider.ts+9-10
......@@ -427,17 +427,16 @@ const probeClaudeCapabilities = (binaryPath: string) => {
427427 );
428428};
429429
430const runClaudeCommand = (args: ReadonlyArray<string>) =>
431 Effect.gen(function* () {
432 const claudeSettings = yield* Effect.service(ServerSettingsService).pipe(
433 Effect.flatMap((service) => service.getSettings),
434 Effect.map((settings) => settings.providers.claudeAgent),
435 );
436 const command = ChildProcess.make(claudeSettings.binaryPath, [...args], {
437 shell: process.platform === "win32",
438 });
439 return yield* spawnAndCollect(claudeSettings.binaryPath, command);
430const runClaudeCommand = Effect.fn("runClaudeCommand")(function* (args: ReadonlyArray<string>) {
431 const claudeSettings = yield* Effect.service(ServerSettingsService).pipe(
432 Effect.flatMap((service) => service.getSettings),
433 Effect.map((settings) => settings.providers.claudeAgent),
434 );
435 const command = ChildProcess.make(claudeSettings.binaryPath, [...args], {
436 shell: process.platform === "win32",
440437 });
438 return yield* spawnAndCollect(claudeSettings.binaryPath, command);
439});
441440
442441export const checkClaudeProviderStatus = Effect.fn("checkClaudeProviderStatus")(function* (
443442 resolveSubscriptionType?: (binaryPath: string) => Effect.Effect<string | undefined>,