Skip to content

Remove the Python SDK's native CA conversion cache - #6083

Closed
markstuart-oai wants to merge 1 commit into
feat/codex-harnessfrom
codex/remove-ca-conversion-cache
Closed

markstuart-oai wants to merge 1 commit into
feat/codex-harnessfrom
codex/remove-ca-conversion-cache

Conversation

@markstuart-oai

Copy link
Copy Markdown
Contributor

Why

The SDK keeps converted CA certificates for reuse across clients, even though it must read the trust file each time. This PR drops that cache and builds each new client's trust list from the current file.

Summary

The TLS verifier, proxy rules and HTTP pool stay the same. The change cuts the extra production code in custom_ca.rs from 258 lines over stock to 174. No API changes.

The tradeoff is slower setup for a fresh client. In a local test that built a client and made one TLS request, the median cost rose by 0.13 ms with one root. With a large CA bundle it rose by about 15 ms. That test did not measure pooled requests or live service traffic.

Test plan

  • Ran 26 Rust tests on the old and new CA modules. Both trusted the new CA after a file swap and rejected the old one. A missing file or bad cert still failed, and restoring the file let the next request pass.
  • Replayed all 111 patches from the pinned source. The result matched the Git tree in the manifest. Undoing just this change gave back the old tree.
  • The full local SDK suite has not passed yet. The first run stopped at build setup: Rust 1.95.0 was missing on the host.

Issue number

None.

Checks

  • I've added new tests, if relevant
  • I've run the applicable checks in AGENTS.md, including .agents/skills/code-change-verification/scripts/run.sh when required
  • I've confirmed all required checks pass
  • I've completed the review required by AGENTS.md

@markstuart-oai
markstuart-oai marked this pull request as ready for review November 19, 2026 02:21
@markstuart-oai
markstuart-oai requested review from a team, rm-openai and seratch as code owners November 19, 2026 02:21
@chatgpt-codex-connector

chatgpt-codex-connector Bot commented Nov 19, 2026 •

Copy link
Copy Markdown
Codex Review Summary: ✅ Completed

This comment shows the latest Codex review activity on this pull request.

Review Status Commit Review trigger
📝 Code Review ✅ Completed 2026-11-19T02:22:59.446552Z fb92271 Draft marked ready
🔒 Security Review ✅ Completed 2026-11-19T02:23:50.936753Z fb92271 Draft marked ready
ℹ️ 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
  • Comment "@codex review" or "@codex security review".

Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings.

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