Quietly truncate extra default prompts

Open 💬 1 comment Opened Jun 26, 2026 by MadKangYu

Verified fix branch

I prepared a tested fix branch here:

https://github.com/openai/codex/compare/main...MadKangYu:codex:lazycodex/defaultprompt-truncate-quietly

The branch changes codex-rs/core-plugins/src/manifest.rs so interface.defaultPrompt arrays are still truncated to three prompts, but an otherwise valid fourth prompt no longer emits:

ignoring interface.defaultPrompt: maximum of 3 prompts is supported

Invalid prompt entries still warn and are ignored.

Reproduction

Failing-before test added on 2026-06-27:

just test -p codex-core-plugins plugin_interface_truncates_default_prompt_array_without_warning

Before the fix, that test failed because the fourth valid prompt caused the warning above.

Verification

  • just fmt
  • just fix -p codex-core-plugins
  • just test -p codex-core-plugins plugin_interface_truncates_default_prompt_array_without_warning
  • just test -p codex-core-plugins plugin_interface_normalizes_default_prompt_array
  • just test -p codex-core-plugins does_not_reload_marketplace_per_plugin
  • HOME=/tmp/lazycodex-clean-home-TfSVLP CODEX_HOME=/tmp/lazycodex-clean-home-TfSVLP/.codex just test -p codex-core-plugins

The clean-home crate run passed all 298 tests.

Note: I attempted to open the PR directly against openai/codex, but GitHub rejected both the GraphQL and REST PR creation paths for this account. The branch is pushed and ready for PR creation from the compare URL above.

Tag: lazycodex-generated

View original on GitHub ↗

This issue has 1 comment on GitHub. Read the full discussion on GitHub ↗