Codex Desktop Windows: Git controls missing when thread git metadata is not backfilled for a valid local repo
What version of the Codex App are you using?
Codex Desktop 26.623.3763.0 on Windows.
What issue are you seeing?
For an existing local workspace thread, the right-side project/source panel does not show local Git controls such as local changes, branch state, commit, or push. The panel only shows the source/GitHub area.
The local repository itself is valid. Running Git from the same workspace directory succeeds and shows a clean branch tracking origin:
git status --short --branch
## main...origin/main
git rev-parse --show-toplevel
<workspace-root>
git remote -v
origin <github-remote-url> (fetch)
origin <github-remote-url> (push)
GitHub CLI is also installed, authenticated, and usable.
Additional diagnostic evidence
The local Codex state_5.sqlite threads table has Git metadata columns:
git_sha
git_branch
git_origin_url
For the affected current thread, the row has:
cwd = <workspace-root>
git_branch = main
git_sha = NULL
git_origin_url = NULL
So Codex Desktop appears to know the branch but has not backfilled the commit SHA or origin URL for the thread, even though Git can read them correctly from the same directory. The UI appears to hide commit/push controls when git_origin_url is missing.
Other threads in the same local Codex state database do have complete Git metadata, for example:
git_branch = main
git_sha = <sha>
git_origin_url = <github-remote-url>
This suggests a thread Git metadata refresh/backfill issue rather than a global Git or GitHub CLI installation problem.
What steps can reproduce the bug?
- Open an existing Codex Desktop thread whose cwd is, or later becomes, a valid local Git repository.
- Verify terminal Git commands can read branch, SHA, and origin from the same cwd.
- Open the right-side source/project panel.
- Observe that commit/push/local Git controls are missing.
- Inspect the thread row in
state_5.sqliteand observegit_origin_url/git_shaare empty despite a valid repo.
This may be more likely for long-running threads, or threads created before the repository was initialized or pushed, because the Git metadata does not appear to refresh later.
Expected behavior
Codex Desktop should refresh Git metadata for a thread when the cwd is a valid Git repository, especially after the thread is reopened or Codex Desktop is restarted. The UI should not permanently hide local Git controls just because git_origin_url was empty when the thread was first created.
Actual behavior
The thread remains stuck without commit/push controls even after the repository is valid, synced with origin, and Codex Desktop has been restarted.
Related issues
Possibly related but not identical:
- #17726
- #24484
- #29402
- #29911
5 Comments
Additional datapoint after updating/restarting Codex Desktop:
26.623.5175.0on Windows.Sourcescard with the GitHub/source icon.git status --short --branchshows the branch tracking origin cleanly).git_branch = mainbutgit_sha = NULLandgit_origin_url = NULLinstate_5.sqlite.Also searched public issues for
environment info missing,source only panel, andcommit push not showing desktop, but did not find an exact duplicate.Update after additional local diagnostics:
After mitigating the non-ASCII Windows username path issue, new threads now correctly persist Git metadata in
state_5.sqlite.For a newly created thread in the affected repo:
git_branchis populatedgit_shais populatedgit_origin_urlis populatedThe previous
EPERM mkdir C:\Users\�����errors no longer appear in the latest logs.However, Codex Desktop still renders only the
Sourcessection in the right panel.Environment Info/Changes/Branch/Commit or Pushcontrols are still hidden across all projects and new threads.I also tried:
state_5.sqliteThe issue persists even though Git metadata is now present in the local state database. This suggests the remaining problem is likely in the Desktop UI rendering / feature surface / feature flag layer, not Git detection itself.
This appears related to #30336 and especially #30344.
In my case, Git metadata is already populated in local state, but Codex Desktop still only renders the
Sourcessection and hides theEnvironment Info/ Git controls.Update after final local diagnostics (Windows, all repositories affected):
Current environment
26.707.3748.026.707.314280.144.0-alpha.410.0.262002.54.0.windows.1Scope has expanded
This is no longer limited to one old thread or one repository. The native Git UI fails across all tested local Git repositories and tasks on this machine.
In the representative repository, the right-side Environment Info panel may render the Git controls (Changes / Local / main / Commit or push), but the Changes view does not consume or display the actual local diff. "Generate commit message" also fails.
CLI evidence from the same workspace
There are no remaining Git permission warnings. Git CLI, branch, HEAD, diff, and origin are all healthy.
Codex state evidence
The active user thread row in
state_5.sqlitestill contains:At the same time, older threads and recent threads from another repository can contain complete Git metadata, confirming that the database schema and Git installation are functional. The affected Desktop task does not refresh/backfill SHA and origin even when CLI Git succeeds from the identical cwd.
Local causes ruled out
core.excludesFileto an accessible path; CLI output is now clean, but Desktop behavior is unchangedconfig.tomldependency: all repositories are affectedThis now appears to be a Codex Desktop Git metadata refresh/UI synchronization regression rather than a repository-specific backfill edge case.
Possibly related: #30344, #30484, #30659.
Please investigate the Desktop path that populates
threads.git_sha/threads.git_origin_urland the native Changes panel from local Git status.Update: the native Git UI is now visible, but the Commit/Push flow still fails before commit-message generation. This is not a missing-UI symptom and not a GitHub push/auth failure.
Current environment
10.0.26200OpenAI.Codex_26.715.8383.026.715.619432.54.0.windows.1User-visible failure
Clicking the native Commit/Push action shows the localized error equivalent to:
Unable to generate commit messageManual Git commands in the same repository work, and a manual commit/push through Git CLI has succeeded. Rebooting Windows and restarting Codex do not provide a durable fix.
Desktop log evidence
At the time of the UI failure, the Desktop log records the local Git status request being cancelled before execution:
The command family is the normal local change-collection path (
git status --porcelain). Since the status/diff collection does not complete, commit-message generation has no input.The same session also recorded:
Process evidence
A process snapshot found 22 live
git.exeprocesses launched by Codex-related command paths. Several had remained alive for more than 40 minutes. Commands included:A current
status --porcelainprocess was directly under the live Codex app-server process, with another Git child beneath it. These are read-only metadata/status commands, yet they remain blocked.This does not prove that Git for Windows itself is the root cause. The stronger hypothesis is a Codex Desktop Git-worker/process-lifecycle problem: command scheduling, cancellation, pipe handling, or child-process cleanup. The stuck Git processes appear to be a direct symptom and possible amplifier.
This now closely matches:
git statusand orphanedgit.exe/conhost.exeThere is currently no confirmed official workaround. Killing leaked Git processes or restarting the app only clears transient state; the processes can accumulate again after Codex reopens projects.
Please investigate the Windows Desktop Git worker path used by
local_conversation_git_actions, especially cancellation before spawn and cleanup ofgit.exedescendants.