This commit is contained in:
wassname
2026-06-03 23:56:50 +00:00
parent 0913b064fc
commit 0efd638b4e
2 changed files with 34 additions and 0 deletions
+1
View File
@@ -2,3 +2,4 @@
- [No nohup with pueue](feedback_no_nohup_with_pueue.md) — run `pueue follow|wait` directly as the bg task; nohup& orphans it from the harness.
- [Burn down task list](feedback_burn_down_task_list.md) — when many asks are queued, do them all; don't stop to ask which first.
- [Workshop paper goal](project_workshop_paper_goal.md) — current phase is ablations+seeds for a workshop paper; artifact tracker A1-A7 lives in docs/spec/20260602_writeup_spec.md.
- [Bash-tool shell gotchas](bash-tool-shell-gotchas.md) — noclobber ON + pi --mode json gives 0 bytes; use panel_direct.py / `>|` (generic box/env note, not repo-specific).
+33
View File
@@ -0,0 +1,33 @@
---
name: bash-tool-shell-gotchas
description: Bash-tool zsh has noclobber ON and pi --mode json gives 0 bytes (non-tty); workarounds
metadata:
node_type: memory
type: feedback
originSessionId: ba4a4349-3947-4bfe-87fc-2d6e99001352
---
The Bash tool runs a zsh where `noclobber` is ON, and it is NOT set in any user rc
file (`~/.zshrc`, `~/.zshenv`, etc. — grep finds nothing). So the harness/wrapper
sets it; editing `~/.zshrc` does NOT turn it off. Symptom: `cmd > existing_file`
fails with `file exists: <path>` and writes 0 bytes.
Two recurring consequences and fixes:
1. **`pi --mode json` writes to the tty, not stdout.** In this non-tty shell,
`pi ... | extractor` or `pi ... > file` yields 0 bytes (silently). Fix: skip pi,
hit OpenRouter HTTP directly — see `~/.claude/skills/external-review/panel_direct.py`
(stdlib-only, reads key from /root/.env). This is the robust path for the
external-review comprehension panel and external-panel Q&A.
2. **noclobber refuses `>` onto existing files.** Use `>|` to force-overwrite, or
`rm -f` first, or have the program write the file itself (Python `Path.write_text`,
`tee` both work; `>` redirect does not).
**Why:** wasted ~an hour chasing 0-byte panel output that looked like an auth/model
problem but was noclobber + pi-tty. **How to apply:** when a `>` redirect or a piped
CLI returns 0 bytes, suspect these two before debugging the tool itself.
Also: batching many Bash calls in one message causes cascade-cancellation — if the
first errors (e.g. the noclobber test exits 2), the rest are all cancelled. Run
diagnostics sequentially. See [[projected-grpo-rebuild-from-pseudocode]].