From 4d9aef945e42332c8ebafe4384d15634a3dda1ca Mon Sep 17 00:00:00 2001 From: bflatastic Date: Mon, 2 Nov 2026 05:23:26 +0700 Subject: [PATCH] Pitfall: never type python - with a heredoc An empty python -I - heredoc waited for input twice more in one session. --- docs/pitfalls.md | 2 ++ 1 file changed, 2 insertions(+) diff --git a/docs/pitfalls.md b/docs/pitfalls.md index 321e6389..0c59e076 100644 --- a/docs/pitfalls.md +++ b/docs/pitfalls.md @@ -376,6 +376,8 @@ the tool timed out, with work left in a stash. Never run anything that can page It happened again from a leftover first line (`python -I - <<'X'` with nothing before `X`) in a command that then wrote and ran a script: 10 minutes lost. Write the script with the editor tool and run only `python -I `. +And twice more in one night, each time a `python -I - <<'X'` with an empty body typed as a +throwaway step in a longer command. There is no safe use of `python -` here: never type it. **A search that ran no search.** `timeout 40 find … 2>/dev/null` on a Mac: there's no `timeout` there, the error went to `/dev/null`, and the empty result read as "no such files on this computer". Don't