Commit Graph

3066 Commits

  • chore(apply-patch) unicode scenario (#8141)
    ## Summary
    Adds a unicode scenario, and fills in files on failing scenarios to
    ensure directory state is unchanged, for completeness
    
    ## Testing
    - [x] only changes tests
  • [app-server] add new RawResponseItem v2 event (#8152)
    ``codex/event/raw_response_item` (v1) -> `rawResponseItem/completed`
    (v1).
    
    test client log:
    ````
    < {
    <   "method": "codex/event/raw_response_item",
    <   "params": {
    <     "conversationId": "019b29f7-b089-7140-a535-3fe681562c15",
    <     "id": "0",
    <     "msg": {
    <       "item": {
    <         "arguments": "{\"command\":\"sed -n '1,160p' Cargo.toml\",\"workdir\":\"/Users/celia/code/codex/codex-rs\"}",
    <         "call_id": "call_DrqbdB2jPxezPWc19YVEEt3h",
    <         "name": "shell_command",
    <         "type": "function_call"
    <       },
    <       "type": "raw_response_item"
    <     }
    <   }
    < }
    < {
    <   "method": "rawResponseItem/completed",
    <   "params": {
    <     "item": {
    <       "arguments": "{\"command\":\"sed -n '1,160p' Cargo.toml\",\"workdir\":\"/Users/celia/code/codex/codex-rs\"}",
    <       "call_id": "call_DrqbdB2jPxezPWc19YVEEt3h",
    <       "name": "shell_command",
    <       "type": "function_call"
    <     },
    <     "threadId": "019b29f7-b089-7140-a535-3fe681562c15",
    <     "turnId": "0"
    <   }
    < }
    ```
  • chore: update listMcpServers to listMcpServerStatus (#8114)
    ### Summary
    * rename app server `listMcpServers` to `listMcpServerStatuses`.
  • docs: refine tui2 viewport roadmap (#8122)
    Update the tui2 viewport/history design doc with current status and a
    prioritized roadmap (scroll feel, selection/copy correctness, streaming
    wrap polish, terminal integration, and longer-term per-cell
    interactivity ideas).
  • chore(apply-patch) move invocation tests (#8111)
    ## Summary:
    This PR is a pure copy and paste of tests from lib.rs into
    invocation.rs, to colocate logic and tests.
    
    ## Testing
    - [x] Purely a test refactor
  • Revert "chore: review in read-only (#7593)" (#8127)
    This reverts commit 291b54a762.
    
    This commit was intended to prevent the model from making code changes
    during `/review`, which is sometimes does. Unfortunately, it has other
    unintended side effects that cause `/review` to fail in a variety of
    ways. See #8115 and #7815. We've therefore decided to revert this
    change.
  • fix tui2 compile error (#8124)
    I'm not sure if this fix is ​​correct for the intended change in #7601,
    but at least the compilation error is fixed.
    
    regression: #7601
    
    ```
    error[E0004]: non-exhaustive patterns: `TuiEvent::Mouse(_)` not covered
       --> tui2/src/update_prompt.rs:57:19
        |
     57 |             match event {
        |                   ^^^^^ pattern `TuiEvent::Mouse(_)` not covered
        |
    note: `TuiEvent` defined here
       --> tui2/src/tui.rs:122:10
        |
    122 | pub enum TuiEvent {
        |          ^^^^^^^^
    ...
    126 |     Mouse(crossterm::event::MouseEvent),
        |     ----- not covered
        = note: the matched value is of type `TuiEvent`
    help: ensure that all possible cases are being handled by adding a match arm with a wildcard pattern or an explicit pattern as shown
        |
     64 ~                 },
     65 +                 TuiEvent::Mouse(_) => todo!()
        |
    ```
    
    Signed-off-by: Koichi Shiraishi <zchee.io@gmail.com>
  • chore(apply-patch) move invocation parsing (#8110)
    lib.rs has grown quite large, and mixes two responsibilities:
    1. executing patch operations
    2. parsing apply_patch invocations via a shell command
    
    This PR splits out (2) into its own file, so we can work with it more
    easily. We are explicitly NOT moving tests in this PR, to ensure
    behavior stays the same and we can avoid losing coverage via merge
    conflicts. Tests are moved in a subsequent PR.
    
    ---
    [//]: # (BEGIN SAPLING FOOTER)
    Stack created with [Sapling](https://sapling-scm.com). Best reviewed
    with [ReviewStack](https://reviewstack.dev/openai/codex/pull/8110).
    * #8111
    * __->__ #8110
  • bug fixes and perf improvements for elevated sandbox setup (#8094)
    a few fixes based on testing feedback:
    * ensure cap_sid file is always written by elevated setup.
    * always log to same file whether using elevated sandbox or not
    * process potentially slow ACE write operations in parallel
    * dedupe write roots so we don't double process any
    * don't try to create read/write ACEs on the same directories, due to
    race condition
  • nit: trace span for regular task (#8053)
    Logs are too spammy
    
    ---------
    
    Co-authored-by: Anton Panasenko <apanasenko@openai.com>
  • feat: unified exec footer (#8067)
    <img width="452" height="205" alt="Screenshot 2025-12-15 at 17 54 44"
    src="https://github.com/user-attachments/assets/9ece0b1c-8387-4dfc-b883-c6a68ea1b663"
    />
  • refactor TUI event loop to enable dropping + recreating crossterm event stream (#7961)
    Introduces an `EventBroker` between the crossterm `EventStream` source
    and the consumers in the TUI. This enables dropping + recreating the
    `crossterm_events` without invalidating the consumer.
    
    Dropping and recreating the crossterm event stream enables us to fully
    relinquish `stdin` while the app keeps running. If the stream is not
    dropped, it will continue to read from `stdin` even when it is not
    actively being polled, potentially stealing input from other processes.
    See
    [here](https://www.reddit.com/r/rust/comments/1f3o33u/myterious_crossterm_input_after_running_vim/?utm_source=chatgpt.com)
    and [here](https://ratatui.rs/recipes/apps/spawn-vim/) for details.
    
    ### Tests
    Added tests for new `EventBroker` setup, existing tests pass, tested
    locally.
  • feat: if .codex is a sub-folder of a writable root, then make it read-only to the sandbox (#8088)
    In preparation for in-repo configuration support, this updates
    `WritableRoot::get_writable_roots_with_cwd()` to include the `.codex`
    subfolder in `WritableRoot.read_only_subpaths`, if it exists, as we
    already do for `.git`.
    
    As noted, currently, like `.git`, `.codex` will only be read-only under
    macOS Seatbelt, but we plan to bring support to other OSes, as well.
    
    Updated the integration test in `seatbelt.rs` so that it actually
    attempts to run the generated Seatbelt commands, verifying that:
    
    - trying to write to `.codex/config.toml` in a writable root fails
    - trying to write to `.git/hooks/pre-commit` in a writable root fails
    - trying to write to the writable root containing the `.codex` and
    `.git` subfolders succeeds
  • refactor(tui2): make transcript line metadata explicit (#8089)
    This is a pure refactor only change.
    
    Replace the flattened transcript line metadata from `Option<(usize,
    usize)>` to an explicit
    `TranscriptLineMeta::{CellLine { cell_index, line_in_cell }, Spacer}`
    enum.
    
    This makes spacer rows unambiguous, removes “tuple semantics” from call
    sites, and keeps the
    scroll anchoring model clearer and aligned with the viewport/history
    design notes.
    
    Changes:
    - Introduce `TranscriptLineMeta` and update `TranscriptScroll` helpers
    to consume it.
    - Update `App::build_transcript_lines` and downstream consumers
    (scrolling, row classification, ANSI rendering).
    - Refresh scrolling module docs to describe anchors + spacer semantics
    in context.
    - Add tests and docs about the behavior
    
    Tests:
    - just fmt
    - cargo test -p codex-tui2 tui::scrolling
    
    Manual testing:
    - Scroll the inline transcript with mouse wheel + PgUp/PgDn/Home/End,
    then resize the terminal while staying scrolled up; verify the same
    anchored content stays in view and you don’t jump to bottom
    unexpectedly.
    - Create a gap case (multiple non-continuation cells) and scroll so a
    blank spacer row is at/near the top; verify scrolling doesn’t get stuck
    on spacers and still anchors to nearby real lines.
    - Start a selection while the assistant is streaming; verify the view
    stops auto-following, the selection stays on the intended content, and
    subsequent scrolling still behaves normally.
    - Exit the TUI and confirm scrollback rendering still styles user rows
    as blocks (background padding) and non-user rows as expected.
  • chore(shell_command) fix freeform timeout output (#7791)
    ## Summary
    Adding an additional integration test for timeout_ms
    
    ## Testing
    - [x] these are tests
  • feat: merge remote models instead of destructing (#7997)
    - merge remote models instead of destructing
    - make config values have more precedent over remote values
  • WIP: Rework TUI viewport, history printing, and selection/copy (#7601)
    > large behavior change to how the TUI owns its viewport, history, and
    suspend behavior.
    > Core model is in place; a few items are still being polished before
    this is ready to merge.
    
    We've moved this over to a new tui2 crate from being directly on the tui
    crate.
    To enable use --enable tui2 (or the equivalent in your config.toml). See
    https://developers.openai.com/codex/local-config#feature-flags
    
    Note that this serves as a baseline for the changes that we're making to
    be applied rapidly. Tui2 may not track later changes in the main tui.
    It's experimental and may not be where we land on things.
    
    ---
    
    ## Summary
    
    This PR moves the Codex TUI off of “cooperating” with the terminal’s
    scrollback and onto a model
    where the in‑memory transcript is the single source of truth. The TUI
    now owns scrolling, selection,
    copy, and suspend/exit printing based on that transcript, and only
    writes to terminal scrollback in
    append‑only fashion on suspend/exit. It also fixes streaming wrapping so
    streamed responses reflow
    with the viewport, and introduces configuration to control whether we
    print history on suspend or
    only on exit.
    
    High‑level goals:
    
    - Ensure history is complete, ordered, and never silently dropped.
    - Print each logical history cell at most once into scrollback, even
    with resizes and suspends.
    - Make scrolling, selection, and copy match the visible transcript, not
    the terminal’s notion of
      scrollback.
    - Keep suspend/alt‑screen behavior predictable across terminals.
    
    ---
    
    ## Core Design Changes
    
    ### Transcript & viewport ownership
    
    - Treat the transcript as a list of **cells** (user prompts, agent
    messages, system/info rows,
      streaming segments).
    - On each frame:
    - Compute a **transcript region** as “full terminal frame minus the
    bottom input area”.
    - Flatten all cells into visual lines plus metadata (which cell + which
    line within that cell).
    - Use scroll state to choose which visual line is at the top of the
    region.
      - Clear that region and draw just the visible slice of lines.
    - The terminal’s scrollback is no longer part of the live layout
    algorithm; it is only ever written
      to when we decide to print history.
    
    ### User message styling
    
    - User prompts now render as clear blocks with:
      - A blank padding line above and below.
    - A full‑width background for every line in the block (including the
    prompt line itself).
    - The same block styling is used when we print history into scrollback,
    so the transcript looks
    consistent whether you are in the TUI or scrolling back after
    exit/suspend.
    
    ---
    
    ## Scrolling, Mouse, Selection, and Copy
    
    ### Scrolling
    
    - Scrolling is defined in terms of the flattened transcript lines:
      - Mouse wheel scrolls up/down by fixed line increments.
      - PgUp/PgDn/Home/End operate on the same scroll model.
    - The footer shows:
      - Whether you are “following live output” vs “scrolled up”.
      - Current scroll position (line / total).
    - When there is no history yet, the bottom pane is **pegged high** and
    gradually moves down as the
      transcript fills, matching the existing UX.
    
    ### Selection
    
    - Click‑and‑drag defines a **linear selection** over transcript
    line/column coordinates, not raw
      screen rows.
    - Selection is **content‑anchored**:
    - When you scroll, the selection moves with the underlying lines instead
    of sticking to a fixed
        Y position.
    - This holds both when scrolling manually and when new content streams
    in, as long as you are in
        “follow” mode.
    - The selection only covers the “transcript text” area:
      - Left gutter/prefix (bullets, markers) is intentionally excluded.
    - This keeps copy/paste cleaner and avoids including structural margin
    characters.
    
    ### Copy (`Ctrl+Y`)
    
    - Introduce a small clipboard abstraction (`ClipboardManager`‑style) and
    use a cross‑platform
      clipboard crate under the hood.
    - When `Ctrl+Y` is pressed and a non‑empty selection exists:
    - Re‑render the transcript region off‑screen using the same wrapping as
    the visible viewport.
    - Walk the selected line/column range over that buffer to reconstruct
    the exact text:
        - Includes spaces between words.
        - Preserves empty lines within the selection.
      - Send the resulting text to the system clipboard.
    - Show a short status message in the footer indicating success/failure.
    - Copy is **best‑effort**:
    - Clipboard failures (headless environment, sandbox, remote sessions)
    are handled gracefully via
        status messages; they do not crash the TUI.
    - Copy does *not* insert a new history entry; it only affects the status
    bar.
    
    ---
    
    ## Streaming and Wrapping
    
    ### Previous behavior
    
    Previously, streamed markdown:
    
    - Was wrapped at a fixed width **at commit time** inside the streaming
    collector.
    - Those wrapped `Line<'static>` values were then wrapped again at
    display time.
    - As a result, streamed paragraphs could not “un‑wrap” when the terminal
    width increased; they were
      permanently split according to the width at the start of the stream.
    
    ### New behavior
    
    This PR implements the first step from
    `codex-rs/tui/streaming_wrapping_design.md`:
    
    - Streaming collector is constructed **without** a fixed width for
    wrapping.
      - It still:
        - Buffers the full markdown source for the current stream.
        - Commits only at newline boundaries.
        - Emits logical lines as new content becomes available.
    - Agent message cells now wrap streamed content only at **display
    time**, based on the current
      viewport width, just like non‑streaming messages.
    - Consequences:
      - Streamed responses reflow correctly when the terminal is resized.
    - Animation steps are per logical line instead of per “pre‑wrapped”
    visual line; this makes some
    commits slightly larger but keeps the behavior simple and predictable.
    
    Streaming responses are still represented as a sequence of logical
    history entries (first line +
    continuations) and integrate with the same scrolling, selection, and
    printing model.
    
    ---
    
    ## Printing History on Suspend and Exit
    
    ### High‑water mark and append‑only scrollback
    
    - Introduce a **cell‑based high‑water mark** (`printed_history_cells`)
    on the transcript:
    - Represents “how many cells at the front of the transcript have already
    been printed”.
      - Completely independent of wrapped line counts or terminal geometry.
    - Whenever we print history (suspend or exit):
    - Take the suffix of `transcript_cells` beyond `printed_history_cells`.
      - Render just that suffix into styled lines at the **current** width.
      - Write those lines to stdout.
      - Advance `printed_history_cells` to cover all cells we just printed.
    - Older cells are never re‑rendered for scrollback. They stay in
    whatever wrapping they had when
    printed, which is acceptable as long as the logical content is present
    once.
    
    ### Suspend (`Ctrl+Z`)
    
    - On suspend:
      - Leave alt screen if active and restore normal terminal modes.
    - Render the not‑yet‑printed suffix of the transcript and append it to
    normal scrollback.
      - Advance the high‑water mark.
      - Suspend the process.
    - On resume (`fg`):
      - Re‑enter the TUI mode (alt screen + input modes).
    - Clear the viewport region and fully redraw from in‑memory transcript
    and state.
    
    This gives predictable behavior across terminals without trying to
    maintain scrollback live.
    
    ### Exit
    
    - On exit:
      - Render any remaining unprinted cells once and write them to stdout.
    - Add an extra blank line after the final Codex history cell before
    printing token usage, so the
        transcript and usage info are visually separated.
    - If you never suspended, exit prints the entire transcript exactly
    once.
    - If you suspended one or more times, exit prints only the cells
    appended after the last suspend.
    
    ---
    
    ## Configuration: Suspend Printing
    
    This PR also adds configuration to control **when** we print history:
    
    - New TUI config option to gate printing on suspend:
      - At minimum:
    - `print_on_suspend = true` – current behavior: print new history at
    each suspend *and* on exit.
        - `print_on_suspend = false` – only print on exit.
    - Default is tuned to preserve current behavior, but this can be
    revisited based on feedback.
    - The config is respected in the suspend path:
    - If disabled, suspend only restores terminal modes and stops rendering
    but does not print new
        history.
      - Exit still prints the full not‑yet‑printed suffix once.
    
    This keeps the core viewport logic agnostic to preference, while letting
    users who care about
    quiet scrollback opt out of suspend printing.
    
    ---
    
    ## Tradeoffs
    
    What we gain:
    
    - A single authoritative history model (the in‑memory transcript).
    - Deterministic viewport rendering independent of terminal quirks.
    - Suspend/exit flows that:
      - Print each logical history cell exactly once.
      - Work across resizes and different terminals.
      - Interact cleanly with alt screen and raw‑mode toggling.
    - Consistent, content‑anchored scrolling, selection, and copy.
    - Streaming messages that reflow correctly with the viewport width.
    
    What we accept:
    
    - Scrollback may contain older cells wrapped differently than newer
    ones.
    - Streaming responses appear in scrollback as a sequence of blocks
    corresponding to their streaming
      structure, not as a single retroactively reflowed paragraph.
    - We do not attempt to rewrite or reflow already‑printed scrollback.
    
    For deeper rationale and diagrams, see
    `docs/tui_viewport_and_history.md` and
    `codex-rs/tui/streaming_wrapping_design.md`.
    
    ---
    
    ## Still to Do Before This PR Is Ready
    
    These are scoped to this PR (not long‑term future work):
    
    - [ ] **Streaming wrapping polish**
      - Double‑check all streaming paths use display‑time wrapping only.
      - Ensure tests cover resizing after streaming has started.
    
    - [ ] **Suspend printing config**
    - Finalize config shape and default (keep existing behavior vs opt‑out).
    - Wire config through TUI startup and document it in the appropriate
    config docs.
    
    - [x] **Bottom pane positioning**
    - Ensure the bottom pane is pegged high when there’s no history and
    smoothly moves down as the
    transcript fills, matching the current behavior across startup and
    resume.
    
    - [x] **Transcript mouse scrolling**
    - Re‑enable wheel‑based transcript scrolling on top of the new scroll
    model.
    - Make sure mouse scroll does not get confused with “alternate scroll”
    modes from terminals.
    
    - [x] **Mouse selection vs streaming**
    - When selection is active, stop auto‑scrolling on streaming so the
    selection remains stable on
        the selected content.
    - Ensure that when streaming continues after selection is cleared,
    “follow latest output” mode
        resumes correctly.
    
    - [ ] **Auto‑scroll during drag**
    - While the user is dragging a selection, auto‑scroll when the cursor is
    at/near the top or bottom
    of the transcript viewport to allow selecting beyond the current visible
    window.
    
    - [ ] **Feature flag / rollout**
    - Investigate gating the new viewport/history behavior behind a feature
    flag for initial rollout,
    so we can fall back to the old behavior if needed during early testing.
    
    - [ ] **Before/after videos**
      - Capture short clips showing:
        - Scrolling (mouse + keys).
        - Selection and copy.
        - Streaming behavior under resize.
        - Suspend/resume and exit printing.
      - Use these to validate UX and share context in the PR discussion.
  • chore(app-server): remove stubbed thread/compact API (#8086)
    We want to rely on server-side auto-compaction instead of having the
    client trigger context compaction manually. This API was stubbed as a
    placeholder and never implemented.
  • chore: persist comments in edit (#7931)
    This PR makes sure that inline comment is preserved for mcp server
    config and arbitrary key/value setPath config.
    
    ---------
    
    Co-authored-by: celia-oai <celia@openai.com>
  • exec-server: additional context for errors (#7935)
    Add a .context() on some exec-server errors for debugging CI flakes.
    
    Also, "login": false in the test to make the test not affected by user
    profile.
  • better name for windows sandbox features (#8077)
    `--enable enable...` is a bad look
  • Fix: Skip Option<()> schema generation to avoid invalid Windows filenames (#7479) (#7969)
    ## Problem
    
    When generating JSON schemas on Windows, the `codex app-server
    generate-json-schema` command fails with a filename error:
    ```text
    Error: Failed to write JSON schema for Option<()>
    Caused by:
        0: Failed to write .\Option<()>.json
        1: The filename, directory name, or volume label syntax is incorrect. (os error 123)
    ```
    This occurs because Windows doesn't allow certain characters in
    filenames, specifically the angle brackets **<>** used in the
    **Option<()>** type name.
    
    ## Root Cause
    
    The schema generation process attempts to create individual JSON files
    for each schema definition, including `Option<()>`. However, the
    characters `<` and `>` are invalid in Windows filenames, causing the
    file creation to fail.
    
    ## Solution
    
    The fix extends the existing `IGNORED_DEFINITIONS` constant (which was
    already being used in the **bundle generation**) to also skip
    `Option<()>` when generating individual JSON schema files. This
    maintains consistency with the existing behavior where `Option<()>` is
    excluded from the bundled schema.
    
    ---
    
    close #7479
  • feat: ghost snapshot v2 (#8055)
    This PR updates ghost snapshotting to avoid capturing oversized
    untracked artifacts while keeping undo safe. Snapshot creation now
    builds a temporary index from `git status --porcelain=2 -z`, writes a
    tree and detached commit without touching refs, and records any ignored
    large files/dirs in the snapshot report. Undo uses that metadata to
    preserve large local artifacts while still cleaning up new transient
    files.
  • fix: Don't trigger keybindings view on input burst (#7980)
    Human TL;DR - in some situations, pasting/rapidly inputting text will
    currently cause `?` characters to be stripped from the input message
    content, and display the key bindings helper. For instance, writing
    "Where is X defined? Can we do Y?" results in "Where is X defined Can we
    do Y" being added to the message draft area. This is mildly annoying.
    
    The fix was a simple one line addition. Added a test, ran linters, and
    all looks good to me. I didn't create an issue to link to in this PR - I
    had submitted this bug as a report a while ago but can't seem to find it
    now. Let me know if it's an absolute must for the PR to be accepted.
    
    I have read the CLA Document and I hereby sign the CLA
    
    Below is Codex's summary.
    
    ---
    
    # `?` characters toggling shortcuts / being dropped
    
    ## Symptom
    
    On Termux (and potentially other terminal environments), composing text
    in the native input field and sending it to the TTY can cause:
    
    - The shortcuts overlay to appear (as if `?` was pressed on an empty
    prompt), and
    - All of the literal `?` characters in the text to be **missing** from
    the composer input,
      even when `?` is not the first character.
    
    This typically happens when the composer was previously empty and the
    terminal delivers the text as a rapid sequence of key events rather than
    a single bracketed paste event.
    
    ## Root cause
    
    The TUI has two relevant behaviors:
    
    1. **Shortcut toggle on `?` when empty**
    - `ChatComposer::handle_shortcut_overlay_key` treats a plain `?` press
    as a toggle between the shortcut summary and the full shortcut overlay,
    but only when the composer is empty.
    - When it toggles, it consumes the key event (so `?` is *not* inserted
    into the text input).
    
    2. **“Paste burst” buffering for fast key streams**
    - The TUI uses a heuristic to detect “paste-like” input bursts even when
    the terminal doesn’t send an explicit paste event.
    - During that burst detection, characters can be buffered (and the text
    area can remain empty temporarily) while the system decides whether to
    treat the stream as paste-like input.
    
    In Termux’s “send composed text all at once” mode, the input often
    arrives as a very fast stream of `KeyCode::Char(...)` events. While that
    stream is being buffered as a burst, the visible textarea can still be
    empty. If a `?` arrives during this window, it matches “empty composer”
    and is interpreted as “toggle shortcuts” instead of “insert literal
    `?`”, so the `?` is dropped.
    
    ## Fix
    
    Make the `?` toggle conditional on not being in any paste-burst
    transient state.
    
    Implementation:
    
    - `ChatComposer::handle_shortcut_overlay_key` now checks
    `!self.is_in_paste_burst()` in addition to `self.is_empty()` before
    toggling.
    - This ensures that when input is arriving as a fast burst (including
    the “pending first char” case), `?` is treated as normal text input
    rather than a UI toggle.
    
    ## Test coverage
    
    Added a test that simulates a Termux-like fast stream:
    
    - Sends `h i ? t h e r e` as immediate successive `KeyEvent::Char`
    events (no delays).
    - Asserts that a paste burst is active and the textarea is still empty
    while buffering.
    - Flushes the burst and verifies:
      - The final text contains the literal `?` (`"hi?there"`), and
      - The footer mode is not `ShortcutOverlay`.
    
    ## Notes
    
    This fix intentionally keeps the existing UX:
    
    - `?` still toggles shortcuts when the composer is genuinely empty and
    the user is not in the middle of entering text.
    - `?` typed while composing content (including IME/native-input fast
    streams) remains literal.
  • chore(deps): bump lru from 0.12.5 to 0.16.2 in /codex-rs (#8045)
    Bumps [lru](https://github.com/jeromefroe/lru-rs) from 0.12.5 to 0.16.2.
    <details>
    <summary>Changelog</summary>
    <p><em>Sourced from <a
    href="https://github.com/jeromefroe/lru-rs/blob/master/CHANGELOG.md">lru's
    changelog</a>.</em></p>
    <blockquote>
    <h2><a
    href="https://github.com/jeromefroe/lru-rs/tree/0.16.2">v0.16.2</a> -
    2025-10-14</h2>
    <ul>
    <li>Upgrade hashbrown dependency to 0.16.0.</li>
    </ul>
    <h2><a
    href="https://github.com/jeromefroe/lru-rs/tree/0.16.1">v0.16.1</a> -
    2025-09-08</h2>
    <ul>
    <li>Fix <code>Clone</code> for unbounded cache.</li>
    </ul>
    <h2><a
    href="https://github.com/jeromefroe/lru-rs/tree/0.16.0">v0.16.0</a> -
    2025-07-02</h2>
    <ul>
    <li>Implement <code>Clone</code> for caches with custom hashers.</li>
    </ul>
    <h2><a
    href="https://github.com/jeromefroe/lru-rs/tree/0.15.0">v0.15.0</a> -
    2025-06-26</h2>
    <ul>
    <li>Return bool from <code>promote</code> and <code>demote</code> to
    indicate whether key was found.</li>
    </ul>
    <h2><a
    href="https://github.com/jeromefroe/lru-rs/tree/0.14.0">v0.14.0</a> -
    2025-04-12</h2>
    <ul>
    <li>Use <code>NonZeroUsize::MAX</code> instead of <code>unwrap()</code>,
    and update MSRV to 1.70.0.</li>
    </ul>
    <h2><a
    href="https://github.com/jeromefroe/lru-rs/tree/0.13.0">v0.13.0</a> -
    2025-01-27</h2>
    <ul>
    <li>Add <code>peek_mru</code> and <code>pop_mru</code> methods, upgrade
    dependency on <code>hashbrown</code> to 0.15.2, and update MSRV to
    1.65.0.</li>
    </ul>
    </blockquote>
    </details>
    <details>
    <summary>Commits</summary>
    <ul>
    <li><a
    href="https://github.com/jeromefroe/lru-rs/commit/c1f843ded02d718138483df6ed8da4961accc201"><code>c1f843d</code></a>
    Merge pull request <a
    href="https://redirect.github.com/jeromefroe/lru-rs/issues/223">#223</a>
    from jeromefroe/jerome/prepare-0-16-2-release</li>
    <li><a
    href="https://github.com/jeromefroe/lru-rs/commit/fc4f30953e75e4315d9d965a3e4b7f0968788d2a"><code>fc4f309</code></a>
    Prepare 0.16.2 release</li>
    <li><a
    href="https://github.com/jeromefroe/lru-rs/commit/e91ea2bd85eabfc0769f1117bbba22699e766cb0"><code>e91ea2b</code></a>
    Merge pull request <a
    href="https://redirect.github.com/jeromefroe/lru-rs/issues/222">#222</a>
    from torokati44/hashbrown-0.16</li>
    <li><a
    href="https://github.com/jeromefroe/lru-rs/commit/90d05feff3d795016c4f5a2e44215b35ee5816f7"><code>90d05fe</code></a>
    Update hashbrown to 0.16</li>
    <li><a
    href="https://github.com/jeromefroe/lru-rs/commit/c699209232539c72035d942888750878e590ab46"><code>c699209</code></a>
    Merge pull request <a
    href="https://redirect.github.com/jeromefroe/lru-rs/issues/220">#220</a>
    from jeromefroe/jerome/prepare-0-16-1-release</li>
    <li><a
    href="https://github.com/jeromefroe/lru-rs/commit/2bd820703080f0ee840dce10e7bd447fa8d2c83d"><code>2bd8207</code></a>
    Prepare 0.16.1 release</li>
    <li><a
    href="https://github.com/jeromefroe/lru-rs/commit/1b21bf1c5917e172edbfd0f5f87b2f6d94130724"><code>1b21bf1</code></a>
    Merge pull request <a
    href="https://redirect.github.com/jeromefroe/lru-rs/issues/219">#219</a>
    from wqfish/bk</li>
    <li><a
    href="https://github.com/jeromefroe/lru-rs/commit/3ec42b6369082c00da2836fe033db20cb52a36fc"><code>3ec42b6</code></a>
    Fix clone implementation for unbounded cache</li>
    <li><a
    href="https://github.com/jeromefroe/lru-rs/commit/e2e3e47c33386672fc715deabf3494b071b8d04c"><code>e2e3e47</code></a>
    Merge pull request <a
    href="https://redirect.github.com/jeromefroe/lru-rs/issues/218">#218</a>
    from jeromefroe/jerome/prepare-0-16-0-release</li>
    <li><a
    href="https://github.com/jeromefroe/lru-rs/commit/17fe4f328aa4149814849ede11c283ff7ee27d31"><code>17fe4f3</code></a>
    Prepare 0.16.0 release</li>
    <li>Additional commits viewable in <a
    href="https://github.com/jeromefroe/lru-rs/compare/0.12.5...0.16.2">compare
    view</a></li>
    </ul>
    </details>
    <br />
    
    
    [![Dependabot compatibility
    score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=lru&package-manager=cargo&previous-version=0.12.5&new-version=0.16.2)](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores)
    
    Dependabot will resolve any conflicts with this PR as long as you don't
    alter it yourself. You can also trigger a rebase manually by commenting
    `@dependabot rebase`.
    
    [//]: # (dependabot-automerge-start)
    [//]: # (dependabot-automerge-end)
    
    ---
    
    <details>
    <summary>Dependabot commands and options</summary>
    <br />
    
    You can trigger Dependabot actions by commenting on this PR:
    - `@dependabot rebase` will rebase this PR
    - `@dependabot recreate` will recreate this PR, overwriting any edits
    that have been made to it
    - `@dependabot merge` will merge this PR after your CI passes on it
    - `@dependabot squash and merge` will squash and merge this PR after
    your CI passes on it
    - `@dependabot cancel merge` will cancel a previously requested merge
    and block automerging
    - `@dependabot reopen` will reopen this PR if it is closed
    - `@dependabot close` will close this PR and stop Dependabot recreating
    it. You can achieve the same result by closing it manually
    - `@dependabot show <dependency name> ignore conditions` will show all
    of the ignore conditions of the specified dependency
    - `@dependabot ignore this major version` will close this PR and stop
    Dependabot creating any more for this major version (unless you reopen
    the PR or upgrade to it yourself)
    - `@dependabot ignore this minor version` will close this PR and stop
    Dependabot creating any more for this minor version (unless you reopen
    the PR or upgrade to it yourself)
    - `@dependabot ignore this dependency` will close this PR and stop
    Dependabot creating any more for this dependency (unless you reopen the
    PR or upgrade to it yourself)
    
    
    </details>
    
    Signed-off-by: dependabot[bot] <support@github.com>
    Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
  • chore(deps): bump sentry from 0.34.0 to 0.46.0 in /codex-rs (#8043)
    Bumps [sentry](https://github.com/getsentry/sentry-rust) from 0.34.0 to
    0.46.0.
    <details>
    <summary>Release notes</summary>
    <p><em>Sourced from <a
    href="https://github.com/getsentry/sentry-rust/releases">sentry's
    releases</a>.</em></p>
    <blockquote>
    <h2>0.46.0</h2>
    <h3>Breaking changes</h3>
    <ul>
    <li>Removed the <code>ClientOptions</code> struct's
    <code>trim_backtraces</code> and <code>extra_border_frames</code> fields
    (<a
    href="https://redirect.github.com/getsentry/sentry-rust/pull/925">#925</a>).
    <ul>
    <li>These fields configured backtrace trimming, which is being removed
    in this release.</li>
    </ul>
    </li>
    </ul>
    <h3>Improvements</h3>
    <ul>
    <li>Removed backtrace trimming to align the Rust SDK with the general
    principle that Sentry SDKs should only truncate telemetry data when
    needed to comply with <a
    href="https://develop.sentry.dev/sdk/data-model/envelopes/#size-limits">documented
    size limits</a> (<a
    href="https://redirect.github.com/getsentry/sentry-rust/pull/925">#925</a>).
    This change ensures that as much data as possible remains available for
    debugging.
    <ul>
    <li>If you notice any new issues being created for existing errors after
    this change, please open an issue on <a
    href="https://github.com/getsentry/sentry-rust/issues/new/choose">GitHub</a>.</li>
    </ul>
    </li>
    </ul>
    <h3>Fixes</h3>
    <ul>
    <li>fix: adjust sentry.origin for log integration (<a
    href="https://redirect.github.com/getsentry/sentry-rust/pull/919">#919</a>)
    by <a href="https://github.com/lcian"><code>@​lcian</code></a></li>
    </ul>
    <h2>0.45.0</h2>
    <h3>Breaking changes</h3>
    <ul>
    <li>Add custom variant to <code>AttachmentType</code> that holds an
    arbitrary String. (<a
    href="https://redirect.github.com/getsentry/sentry-rust/pull/916">#916</a>)</li>
    </ul>
    <h2>0.44.0</h2>
    <h3>Breaking changes</h3>
    <ul>
    <li>feat(log): support combined LogFilters and RecordMappings (<a
    href="https://redirect.github.com/getsentry/sentry-rust/pull/914">#914</a>)
    by <a href="https://github.com/lcian"><code>@​lcian</code></a>
    <ul>
    <li>Breaking change: <code>sentry::integrations::log::LogFilter</code>
    has been changed to a <code>bitflags</code> struct.</li>
    <li>It's now possible to map a <code>log</code> record to multiple items
    in Sentry by combining multiple log filters in the filter, e.g.
    <code>log::Level::ERROR =&gt; LogFilter::Event |
    LogFilter::Log</code>.</li>
    <li>If using a custom <code>mapper</code> instead, it's possible to
    return a
    <code>Vec&lt;sentry::integrations::log::RecordMapping&gt;</code> to map
    a <code>log</code> record to multiple items in Sentry.</li>
    </ul>
    </li>
    </ul>
    <h3>Behavioral changes</h3>
    <ul>
    <li>ref(log): send logs by default when logs feature flag is enabled (<a
    href="https://redirect.github.com/getsentry/sentry-rust/pull/915">#915</a>)
    by <a href="https://github.com/lcian"><code>@​lcian</code></a>
    <ul>
    <li>If the <code>logs</code> feature flag is enabled, the default Sentry
    <code>log</code> logger now sends logs for all events at or above
    INFO.</li>
    </ul>
    </li>
    <li>ref(logs): enable logs by default if logs feature flag is used (<a
    href="https://redirect.github.com/getsentry/sentry-rust/pull/910">#910</a>)
    by <a href="https://github.com/lcian"><code>@​lcian</code></a>
    <ul>
    <li>This changes the default value of
    <code>sentry::ClientOptions::enable_logs</code> to
    <code>true</code>.</li>
    <li>This simplifies the setup of Sentry structured logs by requiring
    users to just add the <code>log</code> feature flag to the
    <code>sentry</code> dependency to opt-in to sending logs.</li>
    <li>When the <code>log</code> feature flag is enabled, the
    <code>tracing</code> and <code>log</code> integrations will send
    structured logs to Sentry for all logs/events at or above INFO level by
    default.</li>
    </ul>
    </li>
    </ul>
    <h2>0.43.0</h2>
    <h3>Breaking changes</h3>
    <ul>
    <li>ref(tracing): rework tracing to Sentry span name/op conversion (<a
    href="https://redirect.github.com/getsentry/sentry-rust/pull/887">#887</a>)
    by <a href="https://github.com/lcian"><code>@​lcian</code></a>
    <ul>
    <li>The <code>tracing</code> integration now uses the tracing span name
    as the Sentry span name by default.</li>
    <li>Before this change, the span name would be set based on the
    <code>tracing</code> span target
    (<code>&lt;module&gt;::&lt;function&gt;</code> when using the
    <code>tracing::instrument</code> macro).</li>
    <li>The <code>tracing</code> integration now uses <code>&lt;span
    target&gt;::&lt;span name&gt;</code> as the default Sentry span op (i.e.
    <code>&lt;module&gt;::&lt;function&gt;</code> when using
    <code>tracing::instrument</code>).</li>
    <li>Before this change, the span op would be set based on the
    <code>tracing</code> span name.</li>
    <li>Read below to learn how to customize the span name and op.</li>
    <li>When upgrading, please ensure to adapt any queries, metrics or
    dashboards to use the new span names/ops.</li>
    </ul>
    </li>
    <li>ref(tracing): use standard code attributes (<a
    href="https://redirect.github.com/getsentry/sentry-rust/pull/899">#899</a>)
    by <a href="https://github.com/lcian"><code>@​lcian</code></a>
    <ul>
    <li>Logs now carry the attributes <code>code.module.name</code>,
    <code>code.file.path</code> and <code>code.line.number</code>
    standardized in OTEL to surface the respective information, in contrast
    with the previously sent <code>tracing.module_path</code>,
    <code>tracing.file</code> and <code>tracing.line</code>.</li>
    </ul>
    </li>
    <li>fix(actix): capture only server errors (<a
    href="https://redirect.github.com/getsentry/sentry-rust/pull/877">#877</a>)
    by <a href="https://github.com/lcian"><code>@​lcian</code></a></li>
    </ul>
    <!-- raw HTML omitted -->
    </blockquote>
    <p>... (truncated)</p>
    </details>
    <details>
    <summary>Changelog</summary>
    <p><em>Sourced from <a
    href="https://github.com/getsentry/sentry-rust/blob/master/CHANGELOG.md">sentry's
    changelog</a>.</em></p>
    <blockquote>
    <h2>0.46.0</h2>
    <h3>Breaking changes</h3>
    <ul>
    <li>Removed the <code>ClientOptions</code> struct's
    <code>trim_backtraces</code> and <code>extra_border_frames</code> fields
    (<a
    href="https://redirect.github.com/getsentry/sentry-rust/pull/925">#925</a>).
    <ul>
    <li>These fields configured backtrace trimming, which is being removed
    in this release.</li>
    </ul>
    </li>
    </ul>
    <h3>Improvements</h3>
    <ul>
    <li>Removed backtrace trimming to align the Rust SDK with the general
    principle that Sentry SDKs should only truncate telemetry data when
    needed to comply with <a
    href="https://develop.sentry.dev/sdk/data-model/envelopes/#size-limits">documented
    size limits</a> (<a
    href="https://redirect.github.com/getsentry/sentry-rust/pull/925">#925</a>).
    This change ensures that as much data as possible remains available for
    debugging.
    <ul>
    <li>If you notice any new issues being created for existing errors after
    this change, please open an issue on <a
    href="https://github.com/getsentry/sentry-rust/issues/new/choose">GitHub</a>.</li>
    </ul>
    </li>
    </ul>
    <h3>Fixes</h3>
    <ul>
    <li>fix: adjust sentry.origin for log integration (<a
    href="https://redirect.github.com/getsentry/sentry-rust/pull/919">#919</a>)
    by <a href="https://github.com/lcian"><code>@​lcian</code></a></li>
    </ul>
    <h2>0.45.0</h2>
    <h3>Breaking changes</h3>
    <ul>
    <li>Add custom variant to <code>AttachmentType</code> that holds an
    arbitrary String. (<a
    href="https://redirect.github.com/getsentry/sentry-rust/pull/916">#916</a>)</li>
    </ul>
    <h2>0.44.0</h2>
    <h3>Breaking changes</h3>
    <ul>
    <li>feat(log): support combined LogFilters and RecordMappings (<a
    href="https://redirect.github.com/getsentry/sentry-rust/pull/914">#914</a>)
    by <a href="https://github.com/lcian"><code>@​lcian</code></a>
    <ul>
    <li>Breaking change: <code>sentry::integrations::log::LogFilter</code>
    has been changed to a <code>bitflags</code> struct.</li>
    <li>It's now possible to map a <code>log</code> record to multiple items
    in Sentry by combining multiple log filters in the filter, e.g.
    <code>log::Level::ERROR =&gt; LogFilter::Event |
    LogFilter::Log</code>.</li>
    <li>If using a custom <code>mapper</code> instead, it's possible to
    return a
    <code>Vec&lt;sentry::integrations::log::RecordMapping&gt;</code> to map
    a <code>log</code> record to multiple items in Sentry.</li>
    </ul>
    </li>
    </ul>
    <h3>Behavioral changes</h3>
    <ul>
    <li>ref(log): send logs by default when logs feature flag is enabled (<a
    href="https://redirect.github.com/getsentry/sentry-rust/pull/915">#915</a>)
    by <a href="https://github.com/lcian"><code>@​lcian</code></a>
    <ul>
    <li>If the <code>logs</code> feature flag is enabled, the default Sentry
    <code>log</code> logger now sends logs for all events at or above
    INFO.</li>
    </ul>
    </li>
    <li>ref(logs): enable logs by default if logs feature flag is used (<a
    href="https://redirect.github.com/getsentry/sentry-rust/pull/910">#910</a>)
    by <a href="https://github.com/lcian"><code>@​lcian</code></a>
    <ul>
    <li>This changes the default value of
    <code>sentry::ClientOptions::enable_logs</code> to
    <code>true</code>.</li>
    <li>This simplifies the setup of Sentry structured logs by requiring
    users to just add the <code>log</code> feature flag to the
    <code>sentry</code> dependency to opt-in to sending logs.</li>
    <li>When the <code>log</code> feature flag is enabled, the
    <code>tracing</code> and <code>log</code> integrations will send
    structured logs to Sentry for all logs/events at or above INFO level by
    default.</li>
    </ul>
    </li>
    </ul>
    <h2>0.43.0</h2>
    <h3>Breaking changes</h3>
    <ul>
    <li>ref(tracing): rework tracing to Sentry span name/op conversion (<a
    href="https://redirect.github.com/getsentry/sentry-rust/pull/887">#887</a>)
    by <a href="https://github.com/lcian"><code>@​lcian</code></a>
    <ul>
    <li>The <code>tracing</code> integration now uses the tracing span name
    as the Sentry span name by default.</li>
    <li>Before this change, the span name would be set based on the
    <code>tracing</code> span target
    (<code>&lt;module&gt;::&lt;function&gt;</code> when using the
    <code>tracing::instrument</code> macro).</li>
    <li>The <code>tracing</code> integration now uses <code>&lt;span
    target&gt;::&lt;span name&gt;</code> as the default Sentry span op (i.e.
    <code>&lt;module&gt;::&lt;function&gt;</code> when using
    <code>tracing::instrument</code>).</li>
    <li>Before this change, the span op would be set based on the
    <code>tracing</code> span name.</li>
    <li>Read below to learn how to customize the span name and op.</li>
    </ul>
    </li>
    </ul>
    <!-- raw HTML omitted -->
    </blockquote>
    <p>... (truncated)</p>
    </details>
    <details>
    <summary>Commits</summary>
    <ul>
    <li><a
    href="https://github.com/getsentry/sentry-rust/commit/8d82bfde5944de48482e4d8ada2d2ab35978845f"><code>8d82bfd</code></a>
    release: 0.46.0</li>
    <li><a
    href="https://github.com/getsentry/sentry-rust/commit/9525735e5cdfa25c98667aa91c3cade2ef5acdff"><code>9525735</code></a>
    feat(backtrace): Stop truncating backtraces (<a
    href="https://redirect.github.com/getsentry/sentry-rust/issues/925">#925</a>)</li>
    <li><a
    href="https://github.com/getsentry/sentry-rust/commit/a57b91c5c8992c0955f22cb26f0db0625c1aa9cd"><code>a57b91c</code></a>
    ref: Fix new Clippy lints (<a
    href="https://redirect.github.com/getsentry/sentry-rust/issues/935">#935</a>)</li>
    <li><a
    href="https://github.com/getsentry/sentry-rust/commit/57595753d6d7c039b640405a369d8b039455633c"><code>5759575</code></a>
    meta: Update cargo metadata (<a
    href="https://redirect.github.com/getsentry/sentry-rust/issues/927">#927</a>)</li>
    <li><a
    href="https://github.com/getsentry/sentry-rust/commit/77193f81e44500662acd115ed190dec4bb870852"><code>77193f8</code></a>
    chore: X handle update (<a
    href="https://redirect.github.com/getsentry/sentry-rust/issues/926">#926</a>)</li>
    <li><a
    href="https://github.com/getsentry/sentry-rust/commit/ca232686f4f338f3e13a0123b15654c32c68d47c"><code>ca23268</code></a>
    chore(ci): Migrate danger workflow from v2 to v3 (<a
    href="https://redirect.github.com/getsentry/sentry-rust/issues/918">#918</a>)</li>
    <li><a
    href="https://github.com/getsentry/sentry-rust/commit/2edf6d7a54dde2284b8954501beea311a2468aae"><code>2edf6d7</code></a>
    fix: adjust sentry.origin for log integration (<a
    href="https://redirect.github.com/getsentry/sentry-rust/issues/919">#919</a>)</li>
    <li><a
    href="https://github.com/getsentry/sentry-rust/commit/641204891076a8a4efdde9fb753a2012702e58ac"><code>6412048</code></a>
    Merge branch 'release/0.45.0'</li>
    <li><a
    href="https://github.com/getsentry/sentry-rust/commit/aa6d85b90fc8dcc1292b9727c32350e1aa12a425"><code>aa6d85b</code></a>
    release: 0.45.0</li>
    <li><a
    href="https://github.com/getsentry/sentry-rust/commit/b99eb46bcff33ea17b309f772e0bef0db30c0bed"><code>b99eb46</code></a>
    feat(types): Add custom variant to <code>AttachmentType</code> (<a
    href="https://redirect.github.com/getsentry/sentry-rust/issues/916">#916</a>)</li>
    <li>Additional commits viewable in <a
    href="https://github.com/getsentry/sentry-rust/compare/0.34.0...0.46.0">compare
    view</a></li>
    </ul>
    </details>
    <br />
    
    
    [![Dependabot compatibility
    score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=sentry&package-manager=cargo&previous-version=0.34.0&new-version=0.46.0)](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores)
    
    Dependabot will resolve any conflicts with this PR as long as you don't
    alter it yourself. You can also trigger a rebase manually by commenting
    `@dependabot rebase`.
    
    [//]: # (dependabot-automerge-start)
    [//]: # (dependabot-automerge-end)
    
    ---
    
    <details>
    <summary>Dependabot commands and options</summary>
    <br />
    
    You can trigger Dependabot actions by commenting on this PR:
    - `@dependabot rebase` will rebase this PR
    - `@dependabot recreate` will recreate this PR, overwriting any edits
    that have been made to it
    - `@dependabot merge` will merge this PR after your CI passes on it
    - `@dependabot squash and merge` will squash and merge this PR after
    your CI passes on it
    - `@dependabot cancel merge` will cancel a previously requested merge
    and block automerging
    - `@dependabot reopen` will reopen this PR if it is closed
    - `@dependabot close` will close this PR and stop Dependabot recreating
    it. You can achieve the same result by closing it manually
    - `@dependabot show <dependency name> ignore conditions` will show all
    of the ignore conditions of the specified dependency
    - `@dependabot ignore this major version` will close this PR and stop
    Dependabot creating any more for this major version (unless you reopen
    the PR or upgrade to it yourself)
    - `@dependabot ignore this minor version` will close this PR and stop
    Dependabot creating any more for this minor version (unless you reopen
    the PR or upgrade to it yourself)
    - `@dependabot ignore this dependency` will close this PR and stop
    Dependabot creating any more for this dependency (unless you reopen the
    PR or upgrade to it yourself)
    
    
    </details>
    
    Signed-off-by: dependabot[bot] <support@github.com>
    Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
  • Do not panic when session contains a tool call without an output (#8048)
    Normally, all tool calls within a saved session should have a response,
    but there are legitimate reasons for the response to be missing. This
    can occur if the user canceled the call or there was an error of some
    sort during the rollout. We shouldn't panic in this case.
    
    This is a partial fix for #7990
  • chore(deps): bump socket2 from 0.6.0 to 0.6.1 in /codex-rs (#8046)
    Bumps [socket2](https://github.com/rust-lang/socket2) from 0.6.0 to
    0.6.1.
    <details>
    <summary>Changelog</summary>
    <p><em>Sourced from <a
    href="https://github.com/rust-lang/socket2/blob/master/CHANGELOG.md">socket2's
    changelog</a>.</em></p>
    <blockquote>
    <h1>0.6.1</h1>
    <h2>Added</h2>
    <ul>
    <li>Added support for Windows Registered I/O (RIO)
    (<a
    href="https://redirect.github.com/rust-lang/socket2/pull/604">rust-lang/socket2#604</a>).</li>
    <li>Added support for <code>TCP_NOTSENT_LOWAT</code> on Linux via
    <code>Socket::(set_)tcp_notsent_lowat</code>
    (<a
    href="https://redirect.github.com/rust-lang/socket2/pull/611">rust-lang/socket2#611</a>).</li>
    <li>Added support for <code>SO_BUSY_POLL</code> on Linux via
    <code>Socket::set_busy_poll</code>
    (<a
    href="https://redirect.github.com/rust-lang/socket2/pull/607">rust-lang/socket2#607</a>).</li>
    <li><code>SockFilter::new</code> is now a const function
    (<a
    href="https://redirect.github.com/rust-lang/socket2/pull/609">rust-lang/socket2#609</a>).</li>
    </ul>
    <h2>Changed</h2>
    <ul>
    <li>Updated the windows-sys dependency to version 0.60
    (<a
    href="https://redirect.github.com/rust-lang/socket2/pull/605">rust-lang/socket2#605</a>).</li>
    </ul>
    </blockquote>
    </details>
    <details>
    <summary>Commits</summary>
    <ul>
    <li><a
    href="https://github.com/rust-lang/socket2/commit/d0ba3d39a6328115a49f470b11be25fd5eba686d"><code>d0ba3d3</code></a>
    Release v0.6.1</li>
    <li><a
    href="https://github.com/rust-lang/socket2/commit/3a8b7edda3d81b849b5f961481154510e718dde7"><code>3a8b7ed</code></a>
    Add example to create <code>SockAddr</code> from
    <code>libc::sockaddr_storage</code> (<a
    href="https://redirect.github.com/rust-lang/socket2/issues/615">#615</a>)</li>
    <li><a
    href="https://github.com/rust-lang/socket2/commit/b54e2e6dbf44baee462afb48285d6595e5800381"><code>b54e2e6</code></a>
    Disable armv7-sony-vita-newlibeabihf CI check</li>
    <li><a
    href="https://github.com/rust-lang/socket2/commit/2d4a2f7b3b791118074f5b5ac6f3f92a890ad7b0"><code>2d4a2f7</code></a>
    Update feature <code>doc_auto_cfg</code> to <code>doc_cfg</code></li>
    <li><a
    href="https://github.com/rust-lang/socket2/commit/11aa1029f2ffbc4915d788a85fa739da77599198"><code>11aa102</code></a>
    Add missing components when installing Rust in CI</li>
    <li><a
    href="https://github.com/rust-lang/socket2/commit/528ba2b0dacac88567c2af2e0bf6fd64fe6c4d5c"><code>528ba2b</code></a>
    Add TCP_NOTSENT_LOWAT socketopt support</li>
    <li><a
    href="https://github.com/rust-lang/socket2/commit/1fdd2938c1f3ed81f1a5e0c4ed655146252a3532"><code>1fdd293</code></a>
    Correct rename in CHANGELOG.md (<a
    href="https://redirect.github.com/rust-lang/socket2/issues/610">#610</a>)</li>
    <li><a
    href="https://github.com/rust-lang/socket2/commit/600ff0d2468bd817179c5eab17dd5a69dddb9250"><code>600ff0d</code></a>
    Add support for Windows Registered I/O</li>
    <li><a
    href="https://github.com/rust-lang/socket2/commit/f0836965a165f357ea3be6f5cc47544130d1bfde"><code>f083696</code></a>
    Allow <code>SockFilter::new</code> in const contexts</li>
    <li><a
    href="https://github.com/rust-lang/socket2/commit/15ade5100c865629518190f4234247c8b6e5b1fd"><code>15ade51</code></a>
    Refactor for cargo fmt</li>
    <li>Additional commits viewable in <a
    href="https://github.com/rust-lang/socket2/compare/v0.6.0...v0.6.1">compare
    view</a></li>
    </ul>
    </details>
    <br />
    
    
    [![Dependabot compatibility
    score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=socket2&package-manager=cargo&previous-version=0.6.0&new-version=0.6.1)](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores)
    
    Dependabot will resolve any conflicts with this PR as long as you don't
    alter it yourself. You can also trigger a rebase manually by commenting
    `@dependabot rebase`.
    
    [//]: # (dependabot-automerge-start)
    [//]: # (dependabot-automerge-end)
    
    ---
    
    <details>
    <summary>Dependabot commands and options</summary>
    <br />
    
    You can trigger Dependabot actions by commenting on this PR:
    - `@dependabot rebase` will rebase this PR
    - `@dependabot recreate` will recreate this PR, overwriting any edits
    that have been made to it
    - `@dependabot merge` will merge this PR after your CI passes on it
    - `@dependabot squash and merge` will squash and merge this PR after
    your CI passes on it
    - `@dependabot cancel merge` will cancel a previously requested merge
    and block automerging
    - `@dependabot reopen` will reopen this PR if it is closed
    - `@dependabot close` will close this PR and stop Dependabot recreating
    it. You can achieve the same result by closing it manually
    - `@dependabot show <dependency name> ignore conditions` will show all
    of the ignore conditions of the specified dependency
    - `@dependabot ignore this major version` will close this PR and stop
    Dependabot creating any more for this major version (unless you reopen
    the PR or upgrade to it yourself)
    - `@dependabot ignore this minor version` will close this PR and stop
    Dependabot creating any more for this minor version (unless you reopen
    the PR or upgrade to it yourself)
    - `@dependabot ignore this dependency` will close this PR and stop
    Dependabot creating any more for this dependency (unless you reopen the
    PR or upgrade to it yourself)
    
    
    </details>
    
    Signed-off-by: dependabot[bot] <support@github.com>
    Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
  • Reimplement skills loading using SkillsManager + skills/list op. (#7914)
    refactor the way we load and manage skills:
    1. Move skill discovery/caching into SkillsManager and reuse it across
    sessions.
    2. Add the skills/list API (Op::ListSkills/SkillsListResponse) to fetch
    skills for one or more cwds. Also update app-server for VSCE/App;
    3. Trigger skills/list during session startup so UIs preload skills and
    handle errors immediately.
  • docs: update the docs for @openai/codex-shell-tool-mcp (#7962)
    The existing version of `shell-tool-mcp/README.md` was not written in a
    way that was meant to be consumed by end-users. This is now fixed.
    
    Added `codex-rs/exec-server/README.md` for the more technical bits.
  • Changed default wrap algorithm from OptimalFit to FirstFit (#7960)
    Codex identified this as the cause of a reported hang:
    https://github.com/openai/codex/issues/7822. Apparently, the wrapping
    algorithm we're using has known issues and bad worst-case behaviors when
    OptimalFit is used on certain strings. It recommended switching to
    FirstFit instead.
  • Sync tui2 with tui and keep dual-run glue (#7965)
    - Copy latest tui sources into tui2
    - Restore notifications, tests, and styles
    - Keep codex-tui interop conversions and snapshots
    
    The expected changes that are necessary to make this work are still in
    place:
    
    diff -ru codex-rs/tui codex-rs/tui2 --exclude='*.snap'
    --exclude='*.snap.new'
    
    ```diff
    diff -ru --ex codex-rs/tui/Cargo.toml codex-rs/tui2/Cargo.toml
    --- codex-rs/tui/Cargo.toml	2025-12-12 16:39:12
    +++ codex-rs/tui2/Cargo.toml	2025-12-12 17:31:01
    @@ -1,15 +1,15 @@
     [package]
    -name = "codex-tui"
    +name = "codex-tui2"
     version.workspace = true
     edition.workspace = true
     license.workspace = true
     
     [[bin]]
    -name = "codex-tui"
    +name = "codex-tui2"
     path = "src/main.rs"
     
     [lib]
    -name = "codex_tui"
    +name = "codex_tui2"
     path = "src/lib.rs"
     
     [features]
    @@ -42,6 +42,7 @@
     codex-login = { workspace = true }
     codex-protocol = { workspace = true }
     codex-utils-absolute-path = { workspace = true }
    +codex-tui = { workspace = true }
     color-eyre = { workspace = true }
     crossterm = { workspace = true, features = ["bracketed-paste", "event-stream"] }
     derive_more = { workspace = true, features = ["is_variant"] }
    diff -ru --ex codex-rs/tui/src/app.rs codex-rs/tui2/src/app.rs
    --- codex-rs/tui/src/app.rs	2025-12-12 16:39:05
    +++ codex-rs/tui2/src/app.rs	2025-12-12 17:30:36
    @@ -69,6 +69,16 @@
         pub update_action: Option<UpdateAction>,
     }
     
    +impl From<AppExitInfo> for codex_tui::AppExitInfo {
    +    fn from(info: AppExitInfo) -> Self {
    +        codex_tui::AppExitInfo {
    +            token_usage: info.token_usage,
    +            conversation_id: info.conversation_id,
    +            update_action: info.update_action.map(Into::into),
    +        }
    +    }
    +}
    +
     fn session_summary(
         token_usage: TokenUsage,
         conversation_id: Option<ConversationId>,
    Only in codex-rs/tui/src/bin: md-events.rs
    Only in codex-rs/tui2/src/bin: md-events2.rs
    diff -ru --ex codex-rs/tui/src/cli.rs codex-rs/tui2/src/cli.rs
    --- codex-rs/tui/src/cli.rs	2025-11-19 13:40:42
    +++ codex-rs/tui2/src/cli.rs	2025-12-12 17:30:43
    @@ -88,3 +88,28 @@
         #[clap(skip)]
         pub config_overrides: CliConfigOverrides,
     }
    +
    +impl From<codex_tui::Cli> for Cli {
    +    fn from(cli: codex_tui::Cli) -> Self {
    +        Self {
    +            prompt: cli.prompt,
    +            images: cli.images,
    +            resume_picker: cli.resume_picker,
    +            resume_last: cli.resume_last,
    +            resume_session_id: cli.resume_session_id,
    +            resume_show_all: cli.resume_show_all,
    +            model: cli.model,
    +            oss: cli.oss,
    +            oss_provider: cli.oss_provider,
    +            config_profile: cli.config_profile,
    +            sandbox_mode: cli.sandbox_mode,
    +            approval_policy: cli.approval_policy,
    +            full_auto: cli.full_auto,
    +            dangerously_bypass_approvals_and_sandbox: cli.dangerously_bypass_approvals_and_sandbox,
    +            cwd: cli.cwd,
    +            web_search: cli.web_search,
    +            add_dir: cli.add_dir,
    +            config_overrides: cli.config_overrides,
    +        }
    +    }
    +}
    diff -ru --ex codex-rs/tui/src/main.rs codex-rs/tui2/src/main.rs
    --- codex-rs/tui/src/main.rs	2025-12-12 16:39:05
    +++ codex-rs/tui2/src/main.rs	2025-12-12 16:39:06
    @@ -1,8 +1,8 @@
     use clap::Parser;
     use codex_arg0::arg0_dispatch_or_else;
     use codex_common::CliConfigOverrides;
    -use codex_tui::Cli;
    -use codex_tui::run_main;
    +use codex_tui2::Cli;
    +use codex_tui2::run_main;
     
     #[derive(Parser, Debug)]
     struct TopCli {
    diff -ru --ex codex-rs/tui/src/update_action.rs codex-rs/tui2/src/update_action.rs
    --- codex-rs/tui/src/update_action.rs	2025-11-19 11:11:47
    +++ codex-rs/tui2/src/update_action.rs	2025-12-12 17:30:48
    @@ -9,6 +9,20 @@
         BrewUpgrade,
     }
     
    +impl From<UpdateAction> for codex_tui::update_action::UpdateAction {
    +    fn from(action: UpdateAction) -> Self {
    +        match action {
    +            UpdateAction::NpmGlobalLatest => {
    +                codex_tui::update_action::UpdateAction::NpmGlobalLatest
    +            }
    +            UpdateAction::BunGlobalLatest => {
    +                codex_tui::update_action::UpdateAction::BunGlobalLatest
    +            }
    +            UpdateAction::BrewUpgrade => codex_tui::update_action::UpdateAction::BrewUpgrade,
    +        }
    +    }
    +}
    +
     impl UpdateAction {
         /// Returns the list of command-line arguments for invoking the update.
         pub fn command_args(self) -> (&'static str, &'static [&'static str]) {
    ```
  • fix: introduce AbsolutePathBuf as part of sandbox config (#7856)
    Changes the `writable_roots` field of the `WorkspaceWrite` variant of
    the `SandboxPolicy` enum from `Vec<PathBuf>` to `Vec<AbsolutePathBuf>`.
    This is helpful because now callers can be sure the value is an absolute
    path rather than a relative one. (Though when using an absolute path in
    a Seatbelt config policy, we still have to _canonicalize_ it first.)
    
    Because `writable_roots` can be read from a config file, it is important
    that we are able to resolve relative paths properly using the parent
    folder of the config file as the base path.
  • fix: restore MCP startup progress messages in TUI (fixes #7827) (#7828)
    ## Problem
    
    The introduction of `notify_sandbox_state_change()` in #7112 caused a
    regression where the blocking call in `Session::new()` waits for all MCP
    servers to fully initialize before returning. This prevents the TUI
    event loop from starting, resulting in `McpStartupUpdateEvent` messages
    being emitted but never consumed or displayed. As a result, the app
    appears to hang during startup, and users do not see the expected
    "Booting MCP server: {name}" status line.
    
    Issue: [#7827](https://github.com/openai/codex/issues/7827)
    
    ## Solution
    This change moves sandbox state notification into each MCP server's
    background initialization task. The notification is sent immediately
    after the server transitions to the Ready state. This approach:
    - Avoids blocking `Session::new()`, allowing the TUI event loop to start
    promptly.
    - Ensures each MCP server receives its sandbox state before handling any
    tool calls.
    - Restores the display of "Booting MCP server" status lines during
    startup.
    
    ## Key Changes
    - Added `ManagedClient::notify_sandbox_state()` method.
    - Passed sandbox_state to `McpConnectionManager::initialize()`.
    - Sends sandbox state notification in the background task after the
    server reaches Ready status.
    - Removed blocking notify_sandbox_state_change() methods.
    - Added a chatwidget snapshot test for the "Booting MCP server" status
    line.
    
    ## Regression Details
    
    Regression was bisected to #7112, which introduced the blocking
    behavior.
    
    ---------
    
    Co-authored-by: Michael Bolin <bolinfest@gmail.com>
    Co-authored-by: Michael Bolin <mbolin@openai.com>
  • support 1p (#7945)
    # External (non-OpenAI) Pull Request Requirements
    
    Before opening this Pull Request, please read the dedicated
    "Contributing" markdown file or your PR may be closed:
    https://github.com/openai/codex/blob/main/docs/contributing.md
    
    If your PR conforms to our contribution guidelines, replace this text
    with a detailed and high quality description of your changes.
    
    Include a link to a bug report or enhancement request.
  • fix: use PowerShell to parse PowerShell (#7607)
    Previous to this PR, we used a hand-rolled PowerShell parser in
    `windows_safe_commands.rs` to take a `&str` of PowerShell script see if
    it is equivalent to a list of `execvp(3)` invocations, and if so, we
    then test each using `is_safe_powershell_command()` to determine if the
    overall command is safe:
    
    
    https://github.com/openai/codex/blob/6e6338aa876bb4258abe25b02ac6417b8ea9dff0/codex-rs/core/src/command_safety/windows_safe_commands.rs#L89-L98
    
    Unfortunately, our PowerShell parser did not recognize `@(...)` as a
    special construct, so it was treated as an ordinary token. This meant
    that the following would erroneously be considered "safe:"
    
    ```powershell
    ls @(calc.exe)
    ```
    
    The fix introduced in this PR is to do something comparable what we do
    for Bash/Zsh, which is to use a "proper" parser to derive the list of
    `execvp(3)` calls. For Bash/Zsh, we rely on
    https://crates.io/crates/tree-sitter-bash, but there does not appear to
    be a crate of comparable quality for parsing PowerShell statically
    (https://github.com/airbus-cert/tree-sitter-powershell/ is the best
    thing I found).
    
    Instead, in this PR, we use a PowerShell script to parse the input
    PowerShell program to produce the AST.
  • chore(prompt) Update base prompt (#7943)
    ## Summary
    Update base prompt
  • chore(prompt) Remove truncation details (#7941)
    Fixes #7867 and #7906
    
    ## Summary
    Update truncation details.