Skip to content

Guard OpenAI tool registration when bridging#106

Merged
hackall360 merged 1 commit intomultifamilyfrom
codex/add-tool-assumption-checks-and-comments
Sep 15, 2025
Merged

Guard OpenAI tool registration when bridging#106
hackall360 merged 1 commit intomultifamilyfrom
codex/add-tool-assumption-checks-and-comments

Conversation

@hackall360
Copy link
Owner

Summary

  • extend the OpenAI tools configuration with provider tooling capability flags so we can skip plan/apply_patch/web search registration when a JSON bridge is required
  • short circuit the OpenAI tool list builder when native tooling is unavailable and cover the bridging case with a dedicated unit test
  • plumb provider tooling metadata from turn context construction so every ToolsConfig::new call knows when to defer to the JSON bridge

Testing

  • just fix -p codex-core (fails: codex-ollama does not compile because serde_json::Error::custom is unavailable and ResponseEvent lacks Clone)
  • cargo test -p codex-core (fails: codex-ollama does not compile because serde_json::Error::custom is unavailable and ResponseEvent lacks Clone)

https://chatgpt.com/codex/tasks/task_b_68c85e82d89c832f93d409b768aa4ded

@hackall360 hackall360 merged commit 9b99542 into multifamily Sep 15, 2025
3 of 6 checks passed
@hackall360 hackall360 deleted the codex/add-tool-assumption-checks-and-comments branch September 15, 2025 19:21
Copy link

@chatgpt-codex-connector chatgpt-codex-connector bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Codex Review: Here are some suggestions.

if supports_native_tools
&& matches!(approval_policy, AskForApproval::OnRequest)
&& !use_streamable_shell_tool

[P0] Dereference missing in streamable shell guard

The new ToolsConfig::new condition that switches to ShellWithRequest now uses !use_streamable_shell_tool, but use_streamable_shell_tool is a &bool because params is destructured from &ToolsConfigParams. Applying ! to a reference does not compile (Not is not implemented for &bool). The previous code dereferenced the value, and the other branches still use *use_streamable_shell_tool. As written, codex-core will fail to build once compilation reaches this module. Change the condition to !*use_streamable_shell_tool (or bind a value instead of a reference) so the code compiles.


Reply with @codex fix comments to fix any unresolved comments.

About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you open a pull request for review, mark a draft as ready, or comment "@codex review". If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex fix this CI failure" or "@codex address that feedback".

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

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant