Fix writeMessage guard to check session map and remove redundant stripLineColumnSuffix
Co-authored-by: Julius Marminge <[email protected]>
This commit is contained in:
1 parent
4119c721fc
commit
894ae64a78
2 files changed
+2
-2
No files matched your search
@@ -847,7 +847,7 @@ export class CodexAppServerManager extends EventEmitter<CodexAppServerManagerEve
|
||||
|
||||
private async writeMessage(context: CodexSessionContext, message: unknown): Promise<void> {
|
||||
const encoded = JSON.stringify(message);
|
||||
if (context.stopping) {
|
||||
if (context.stopping || !this.sessions.has(context.session.sessionId)) {
|
||||
throw new Error("Cannot write to codex app-server stdin.");
|
||||
}
|
||||
await this.runPromise(
|
||||
|
||||
@@ -354,7 +354,7 @@ export const resolveEditorLaunch = Effect.fnUntraced(function* (
|
||||
let target = stripLineColumnSuffix(input.cwd);
|
||||
if (runtimeEnvironment.windowsInteropMode === "wsl-hosted" && command === "explorer.exe") {
|
||||
target = yield* Effect.try({
|
||||
try: () => stripLineColumnSuffix(translateWslPathToWindows(target)),
|
||||
try: () => translateWslPathToWindows(target),
|
||||
catch: (cause) =>
|
||||
new OpenError({
|
||||
message: "Failed to translate WSL path for Windows file manager launch",
|
||||
|
||||
Reference in new issue
Block a user