Repository navigation
Fix idle zsh PR probes triggering chpwd hooks - #16553
Conversation
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
|
Warning Review limit reachedYou've used all free OSS reviews for now. Wait for the free limit to reset to keep reviewing this public repository. Next included review available in 54 seconds. View limit detailsLimit details: You’ve used all 10 included reviews currently available. Review configuration: ⚙️ Run configurationConfiguration used: Repository: manaflow-ai/cmux/.coderabbit.yaml Review profile: ASSERTIVE Plan: Advanced Run ID: 📒 Files selected for processing (2)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
|
All contributors have signed the CLA ✍️ ✅ |
There was a problem hiding this comment.
All reported issues were addressed across 1 file
You’re at about 90% of the monthly reviewed-line limit. You may want to disable incremental reviews to conserve quota. Reviews will continue until that limit is exceeded. If you need help avoiding interruptions, please contact contact@cubic.dev.
Reply with feedback, questions, or to request a fix.
Re-trigger cubic
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
There was a problem hiding this comment.
1 issue found across 2 files (changes from recent commits).
You’re at about 90% of the monthly reviewed-line limit. You may want to disable incremental reviews to conserve quota. Reviews will continue until that limit is exceeded. If you need help avoiding interruptions, please contact contact@cubic.dev.
Prompt for AI agents (unresolved issues)
Check if these issues are valid — if so, understand the root cause of each and fix them. When an issue isn't valid or won't be fixed in this PR, reply in its thread with the reason and then resolve the thread. If appropriate, use sub-agents to investigate and fix each issue separately.
<file name="Resources/shell-integration/cmux-zsh-integration.zsh">
<violation number="1" location="Resources/shell-integration/cmux-zsh-integration.zsh:1655">
P2: `cd -q` (chpwd suppression) was added in zsh 5.9. On older zsh the option is rejected, and because `2>/dev/null` swallows the error the `&& gh pr view ...` chain never runs, so the PR probe silently returns `1` forever and the badge stops updating/never appears — the same silent-failure class of regression this file avoids elsewhere by falling back for zselect/jobstates. Confirm the zsh floor (cmux ships on macOS 14+, whose system zsh is 5.9, so this only bites custom/older zsh builds) or gate the option with `is-at-least 5.9` and use a plain `cd` fallback for older zsh. Note a plain-`cd` fallback re-runs chpwd hooks on shells < 5.9, so if old zsh is out of support, documenting the requirement is the simpler fix.</violation>
</file>
Reply with feedback, questions, or to request a fix.
Re-trigger cubic
| [[ -n "$err_file" ]] || return 1 | ||
| gh_output="$( | ||
| builtin cd "$repo_path" 2>/dev/null \ | ||
| builtin cd -q "$repo_path" 2>/dev/null \ |
There was a problem hiding this comment.
P2: cd -q (chpwd suppression) was added in zsh 5.9. On older zsh the option is rejected, and because 2>/dev/null swallows the error the && gh pr view ... chain never runs, so the PR probe silently returns 1 forever and the badge stops updating/never appears — the same silent-failure class of regression this file avoids elsewhere by falling back for zselect/jobstates. Confirm the zsh floor (cmux ships on macOS 14+, whose system zsh is 5.9, so this only bites custom/older zsh builds) or gate the option with is-at-least 5.9 and use a plain cd fallback for older zsh. Note a plain-cd fallback re-runs chpwd hooks on shells < 5.9, so if old zsh is out of support, documenting the requirement is the simpler fix.
Prompt for AI agents
Check if this issue is valid — if so, understand the root cause and fix it. When an issue isn't valid or won't be fixed in this PR, reply in its thread with the reason and then resolve the thread. At Resources/shell-integration/cmux-zsh-integration.zsh, line 1655:
<comment>`cd -q` (chpwd suppression) was added in zsh 5.9. On older zsh the option is rejected, and because `2>/dev/null` swallows the error the `&& gh pr view ...` chain never runs, so the PR probe silently returns `1` forever and the badge stops updating/never appears — the same silent-failure class of regression this file avoids elsewhere by falling back for zselect/jobstates. Confirm the zsh floor (cmux ships on macOS 14+, whose system zsh is 5.9, so this only bites custom/older zsh builds) or gate the option with `is-at-least 5.9` and use a plain `cd` fallback for older zsh. Note a plain-`cd` fallback re-runs chpwd hooks on shells < 5.9, so if old zsh is out of support, documenting the requirement is the simpler fix.</comment>
<file context>
@@ -1652,7 +1652,7 @@ _cmux_report_pr_for_path() {
[[ -n "$err_file" ]] || return 1
gh_output="$(
- builtin cd "$repo_path" 2>/dev/null \
+ builtin cd -q "$repo_path" 2>/dev/null \
&& gh pr view "$branch" \
"${gh_repo_args[@]}" \
</file context>
|
Merge receipt for |
0bfd027 test(cloud): fix the Cloud header and moved-panel focus tests that never ran (manaflow-ai#16539) c5c4345 localization: accept numbered placeholders in any order (manaflow-ai#16376) 456edeb fix(settings): replace custom sidebar mockups with real previews (manaflow-ai#16569) 98dc3ab Prototype: cmux Cloud as a remote MCP server (manaflow-ai#16568) 6c22525 test(remote): isolate tmux stale-surface fixture (manaflow-ai#16566) 3ec9918 Re-land "fix(coderouter): initialize Cloud VM account pools (manaflow-ai#16397)" (manaflow-ai#16572) 2b895a5 Fix browser paste routing with terminal text box beta (manaflow-ai#6380) (manaflow-ai#16560) 2bd3455 localization: check Swift defaultValue literals against their catalog en value (manaflow-ai#16396) c43086e test(cli): expect --mark-read to mark every listed inbox message (manaflow-ai#16537) fcda4f0 test(feed): wait for zero-wait Codex permission acceptance before checking attention (manaflow-ai#16536) 7d57a03 fix(remote): evict stale persistent SSH bridge leases (manaflow-ai#16558) d630cb8 docs: add protected-folder diagnostics for tmux sessions (manaflow-ai#12219) 7dceaac test: create cwd fixtures that new terminals now resolve on disk (manaflow-ai#16538) 28cc575 docs: cover surface resume binding CLI contract (manaflow-ai#16473) 5c7dca1 Fix idle zsh PR probes triggering chpwd hooks (manaflow-ai#16553) # Conflicts: # .github/workflows/ci-guards.yml
Idle zsh PR polling now uses quiet
cd, so it stops firing userchpwdhooks and inflating zoxide rankings. The probe still runsghin the repository and caches the returned PR.Closes #3191.
Validation: the test-only commit reproduces the unwanted hook execution locally. After the fix, all 6 PR watcher tests, the stale-cwd shell tests, first-prompt spawn tests, zsh syntax check, and
git diff --checkpass. The test-only CI run skipped themacos-shelllane, so its green guards are not regression-test evidence.No user-facing strings changed; localization audit found no strings to translate.
Marshmallow g1 🎐
run: run_cx_bl_bugs_a_old_20261001
session: cx-bl-bugs-a-oldest