Delegated worktree creation does not apply the selected local environment setup
Nobody has claimed this yet.
Assessment
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Newbie friendliness
- 48/100
- Issue type
- Bug
- Clarity
- Mostly clear
- Activity status
- Quiet
- Tech stack
- rust
- Domain
- cli, developer-experience
Research direction
No files or tests are named. Start by locating the normal UI worktree creation path and the delegated/programmatic task-creation entry point, then compare how the selected local environment is passed or loaded. Add a regression test covering explicit and saved environment selection, and verify that the new worktree runs its setup script and permits environment-managed commands.
Written by the indexing model from the issue text.
Description
Summary
Creating a worktree through a programmatic or delegated task path can skip the local environment selected for the project. The worktree is created successfully, but its configured setup script never runs.
The normal UI worktree flow lets the user select a local environment. The delegated/programmatic creation interface exposes no corresponding environment-selection parameter, and it also fails to inherit the project's saved selection.
This leaves the new worktree without generated environment files and with its environment manager blocked, even when the same local environment is selected and works through the normal UI worktree flow.
Steps to reproduce
- Open a project with a checked-in local environment definition that has a setup script.
- Select that environment for the project.
- Create a worktree through a delegated or programmatic task-creation flow.
- In the new worktree, check for an expected artifact from the setup script.
- Run a command through the environment manager.
Expected behavior
The delegated/programmatic creation interface should either:
- accept an explicit choice of the project's local environment; or
- inherit the project's saved selected environment when no explicit choice is supplied.
In either case, the new worktree should run the configured setup script automatically.
Actual behavior
The worktree is created without the selected environment attached. Its setup script does not run, expected setup artifacts are missing, and environment-managed commands report that the environment is blocked or unapproved.
Impact
Delegated worktrees require manual repair before normal development commands and verification can run. This is easy to miss and causes tasks to begin in a partially initialized state.
Suggested direction
Add a reviewed environment-selection option to delegated/programmatic worktree creation, and fall back to the project’s saved selection when omitted. This should match the normal UI worktree path.
Privacy note
This report intentionally omits local repository details, paths, logs, and project-specific configuration.
- Dominant language
- Rust
- Stars
- 125k
- Forks
- 19.5k
- Avg merge
- 1m
- Merged PRs (30d)
- 1k
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
More from openai/codex
-
enhancement remote
Difficulty 2/5 1-3 hours Newbie friendliness 68/100
-
bug CLI windows-os
Difficulty 2/5 1-3 hours Newbie friendliness 76/100
-
macOS sandbox blocks hw.optional.arm64 sysctl, causing Flutter to misdetect Apple Silicon as x64 Openbug CLI sandbox
Difficulty 2/5 1-3 hours Newbie friendliness 78/100
-
bug CLI TUI
Difficulty 2/5 1-3 hours Newbie friendliness 90/100
-
CLI config enhancement skills
Difficulty 2/5 1-3 hours Newbie friendliness 84/100
Similar issues
-
Difficulty 2/5 1-3 hours Newbie friendliness 86/100
kwakseongjae/auto-hwp#319 ·
-
area:cli bug filter-quality good first issue priority:medium
Difficulty 2/5 1-3 hours Newbie friendliness 84/100
-
Difficulty 1/5 Under an hour Newbie friendliness 72/100
bevyengine/bevy#25861 ·
-
comp-datalake
Difficulty 2/5 1-3 hours Newbie friendliness 88/100
ClickHouse/ClickHouse#121222 ·
-
A-linter
Difficulty 2/5 1-3 hours Newbie friendliness 72/100
oxc-project/oxc#26863 ·