Skip to content

Profile-backed models cause “request canceled” because --profile is passed to app-server #2

Description

@mhulden

CodexMonitor’s profile-model support currently launches the backend approximately as:

codex --profile qwen-local app-server

With Codex CLI 0.153.4, this exits immediately:

Error: --profile only applies to runtime commands and `codex mcp` ...

As a result, CodexMonitor reports the generic error “request canceled.” No request reaches the configured model provider.

This affects any profile-backed model, not only Qwen or local providers.

Environment:

  • Codex CLI: 0.153.4
  • CodexMonitor: current main, commit 96ee2ad
  • Linux ARM64

Expected behavior:

  • Profile-backed models should work in app-server mode.
  • The app-server should receive the profile’s model, model_provider, and other settings.

Possible implementations:

  1. Wait for/support an official Codex app-server profile mechanism, such as the proposed CODEX_CONFIG_PROFILE environment variable.
  2. Translate the selected profile’s values into supported app-server -c key=value arguments.
  3. Detect unsupported --profile app-server combinations and show a useful error.

A current workaround is a launcher shim that converts the Qwen profile into:

codex -c 'model="qwen3.8-flash-next"' \
      -c 'model_provider="qwen-local"' \
      -c 'model_reasoning_effort="medium"' \
      app-server

The bug is general, although our tested local shim currently handles only the Qwen profile. CodexMonitor should ideally support arbitrary profiles rather than hard-coding provider/model values.

There is also an OpenAI Codex issue tracking the missing app-server profile mechanism: OpenAI Codex issue #38104 (openai/codex#38104). Another related issue documents profile/provider problems in app-server mode: OpenAI Codex issue #23417 (openai/codex#23417).

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions