{"record":{"id":"7d3d553c0fa30f20","repo":"paperclipai/paperclip","slug":"select-codex-to-use-the-native-codex-runner","errorCode":null,"errorMessage":"Select Codex to use the native Codex runner.","messagePattern":"Select Codex to use the native Codex runner\\.","errorType":"exception","errorClass":"Error","httpStatus":null,"severity":"error","filePath":"server/src/adapters/registry.ts","lineNumber":408,"sourceCode":"        ? error\n        : new PaperclipRunnerProviderProfileError(\n            \"paperclip_runner_provider_unsupported\",\n            \"Paperclip Runner provider configuration is invalid.\",\n          );\n      return {\n        adapterType: \"paperclip_runner\",\n        status: \"fail\" as const,\n        testedAt: new Date().toISOString(),\n        checks: [{\n          code: profileError.code,\n          level: \"error\" as const,\n          message: profileError.message,\n        }],\n      };\n    }\n    if (profile.provider === \"acpx\") {\n      try {\n        if (profile.acpxAgent !== \"claude\") throw new Error(\"Select Codex to use the native Codex runner.\");\n        const target = context.executionTarget;\n        if (target?.kind === \"remote\") {\n          const probe = await runAdapterExecutionTargetShellCommand(\n            `acpx-platform-${crypto.randomUUID()}`, target, \"uname -s && uname -m\",\n            { cwd: target.remoteCwd, env: {}, timeoutSec: 15 },\n          );\n          if (probe.timedOut || probe.exitCode !== 0) throw new Error(\"Could not verify the remote ACPX runner platform.\");\n          const [os, arch] = probe.stdout.trim().split(/\\s+/);\n          if (!((os === \"Linux\" && arch === \"x86_64\") || (os === \"Darwin\" && [\"arm64\", \"x86_64\"].includes(arch ?? \"\")))) {\n            throw new Error(\"ACPX Claude requires Linux x64 or macOS ARM64/x64.\");\n          }\n          return {\n            adapterType: \"paperclip_runner\", status: \"warn\" as const, testedAt: new Date().toISOString(),\n            checks: [{ code: \"acpx_remote_runtime_unverified\", level: \"warn\" as const,\n              message: \"The remote platform is supported. Runtime package integrity and readiness must still be verified by the remote runner before launch.\" }],\n          };\n        }\n        const { probeAcpxClaudeInstallation } = await import(\"@paperclipai/paperclip-runner/live\");","sourceCodeStart":390,"sourceCodeEnd":426,"githubUrl":"https://github.com/paperclipai/paperclip/blob/01ad8584922b5d85292b1723cae71fa0d9b07a19/server/src/adapters/registry.ts#L390-L426","documentation":"Thrown by `testEnvironment` in the adapter registry when an ACPX profile is being validated but `profile.acpxAgent` is not `\"claude\"`. Despite the wording, the check enforces that only the Claude ACPX agent can use the native Codex runner path; any other acpxAgent value fails environment testing with this message.","triggerScenarios":"Calling the adapter environment-test path with a profile where `provider === \"acpx\"` and `profile.acpxAgent` set to something other than `\"claude\"` (e.g. a codex/other agent value or a stale/typo'd agent name).","commonSituations":"User selected the wrong agent in the ACPX profile UI; profile JSON edited by hand with an unsupported acpxAgent value; older profile created before the acpxAgent field was constrained; migration left an unexpected default.","solutions":["Set `profile.acpxAgent` to `\"claude\"` in the adapter profile and re-run the environment test.","If you intended a non-Claude agent, use the appropriate provider instead of `acpx`.","Fix typos or casing in the acpxAgent value (must be exactly `\"claude\"`).","Re-create the profile through the UI so validation constrains acpxAgent to the supported value."],"exampleFix":"// before\nconst profile = { provider: \"acpx\", acpxAgent: \"codex\" };\n// after\nconst profile = { provider: \"acpx\", acpxAgent: \"claude\" };","handlingStrategy":"validation","validationCode":"if (profile.provider === \"acpx\" && profile.acpxAgent !== \"claude\") {\n  throw new Error(\"ACPX profiles must set acpxAgent to 'claude'\");\n}","typeGuard":"function isSupportedAcpxProfile(profile) {\n  return profile.provider !== \"acpx\" || profile.acpxAgent === \"claude\";\n}","tryCatchPattern":"try {\n  await registry.testEnvironment(profile, context);\n} catch (err) {\n  if (err.message.includes(\"Select Codex to use the native Codex runner\")) {\n    profile.acpxAgent = \"claude\";\n    await registry.testEnvironment(profile, context);\n  } else throw err;\n}","preventionTips":["Constrain acpxAgent to 'claude' at profile-creation time in the UI.","Validate persisted profiles on load and repair stale values.","Never hand-edit adapter profile JSON without re-running validation."],"tags":["configuration","acpx","adapter","validation"],"backgroundTag":"invalid-enum-value","analyzedSha":"01ad8584922b5d85292b1723cae71fa0d9b07a19","analyzedAt":"2026-09-10T03:14:50.855Z","contentChangedAt":"2026-09-10T03:14:50.855Z","schemaVersion":2},"datasetVersion":"2026-09-14T00:17:10.932Z"}