Skip to content

fix(codex): replace dead --enable web_search_cached flag with --search#2249

Open
kinoko-studio wants to merge 1 commit into
garrytan:mainfrom
kinoko-studio:fix/codex-web-search-flag
Open

fix(codex): replace dead --enable web_search_cached flag with --search#2249
kinoko-studio wants to merge 1 commit into
garrytan:mainfrom
kinoko-studio:fix/codex-web-search-flag

Conversation

@kinoko-studio

@kinoko-studio kinoko-studio commented Jul 12, 2026

Copy link
Copy Markdown

Summary

  • codex-cli 0.144.1 marks web_search_cached deprecated (codex features list) and prints, on every invocation that still passes --enable web_search_cached:
    deprecated: `[features].web_search_cached` is deprecated because web search is enabled by default.
    Set `web_search` to "live", "indexed", "cached", or "disabled" ... in config.toml if you want to override it.
    
  • Live-tested: codex exec with no search-related flag at all still performs real web searches successfully. So the old flag wasn't keeping search on — it was just inert, printing a noisy warning on every gstack codex pass (autoplan, codex, design-consultation, design-review, document-release, office-hours, plan-ceo-review, plan-design-review, plan-devex-review, plan-eng-review, review, ship, plus two scripts/resolvers/*.ts files and the .tmpl counterparts).
  • This PR replaces the dead flag with --search rather than dropping it outright (see Drop deprecated --enable web_search_cached from codex calls #2224 for the bare-removal alternative). Rationale for the explicit flag over relying on codex's implicit default: codex-cli has already changed this exact mechanism once (the old features.web_search_cached boolean → the new web_search config key), so pinning search on explicitly is more robust to it changing again than depending on whatever the built-in default happens to be.
  • Also corrects the "Web search" doc note in codex/SKILL.md(.tmpl), which described the old flag as "OpenAI's cached index" — inaccurate for --search's live lookup via the native Responses web_search tool.

Test plan

  • Verified web_search_cached is deprecated via codex features list and the live stderr warning on codex-cli 0.144.1
  • Verified codex exec performs successful real web searches with no search flag at all (rules out "the old flag was required for search to work")
  • grep -r "enable web_search_cached" returns zero matches post-fix
  • Confirmed --search is present at every prior call site
  • bun test test/host-config.test.ts (golden-file regression) — green
  • Full bun test browse/test/ test/ make-pdf/test/ ... — exit 0
  • bun run skill:check clean across all host targets after bun run gen:skill-docs --host all

Supersedes #2224 (bare removal) — closing that one with this rationale.

🤖 Generated with Claude Code

@trunk-io

trunk-io Bot commented Jul 12, 2026

Copy link
Copy Markdown

Merging to main in this repository is managed by Trunk.

  • To merge this pull request, check the box to the left or comment /trunk merge below.

After your PR is submitted to the merge queue, this comment will be automatically updated with its status. If the PR fails, failure details will also be posted here

codex-cli 0.144.1 marks the web_search_cached feature deprecated
(codex features list) and prints, on every invocation that still
passes it:

  deprecated: `[features].web_search_cached` is deprecated because
  web search is enabled by default. Set `web_search` to "live",
  "indexed", "cached", or "disabled" ... in config.toml if you want
  to override it.

Live-tested: `codex exec` with no search-related flag at all still
performs real web searches successfully, so the old flag was inert
(just a noisy warning), not the thing keeping search on. This PR
replaces it with `--search` instead of dropping it outright, to pin
live web search explicitly rather than lean on codex's implicit
default — codex-cli has already changed this exact mechanism once
(the old features-flag system to the new web_search config key), so
an explicit flag is more robust to it changing again. Also corrects
the "Web search" doc note in codex/SKILL.md(.tmpl), which described
the old flag as "OpenAI's cached index" — inaccurate for --search's
live lookup via the native Responses web_search tool.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant