Browser launches leave zombie processes on Linux

Open Beginner friendly
#62,286 1 comment 0 reactions 0 assignees View on GitHub

Maintainers usually reply within 1 day

Nobody has claimed this yet.

Assessment

Difficulty
1/5
Estimated time
Under an hour
Newbie friendliness
83/100
Issue type
Bug
Clarity
Clearly specified
Activity status
Active
Tech stack
rust
Domain
cli

Research direction

Start with the webbrowser dependency entry in codex-rs/Cargo.toml and its resolved version in codex-rs/Cargo.lock; the issue identifies upstream version 1.2.7 as the fix. Update the dependency and check that the lockfile resolves to 1.2.7 or later. Done means the updated dependency cleans up browser child processes on Linux.

Written by the indexing model from the issue text.

Description

bug CLI performance
What version of Codex CLI is running?

codex-cli 0.162.1

What issue are you seeing?

When using Codex CLI with a custom BROWSER script, each browser launch leaves a defunct process after the script exits. These processes remain until Codex exits.

What steps can reproduce the bug?
  1. On Linux, set the browser environment variable before starting Codex: export BROWSER=/usr/bin/echo
  2. Start Codex and trigger an action that opens a browser (click a link, multiple times).
  3. Check the process list while Codex is still running. Each browser launch leaves a [echo] <defunct> process.
What is the expected behavior?

Processes are cleaned up.

Additional information

This is caused by amodm/webbrowser-rs#126. The background launch path drops the child handle without waiting for it.

Codex currently specifies webbrowser = "1.2.2" in Cargo.toml, with version 1.2.4 resolved in Cargo.lock.

This is fixed upstream in 1.2.7. Could webbrowser be updated to 1.2.7 or later?

Dominant language
Rust
Stars
136k
Forks
21.5k
Avg merge
1m
Merged PRs (30d)
998

Getting set up

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

More from openai/codex

All issues in openai/codex

Similar issues

More Rust issues

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.