mirror of
https://github.com/Ark0N/Codeman.git
synced 2026-11-14 02:29:33 +01:00
docs: finish dropping the stripped-newline rule from the input docs
The first commit left the old rule standing in places: the gotchas list in extending-codeman.md still said newlines were stripped and that "echo A\necho B\r" ran `echo Aecho B`, and so did both READMEs and the skill's big-input section. Those now describe the paste. Newlines are only kept on the mux path, so the docs that describe the paste say "with useMux": without it a multi-line body is not a plain prompt and is written straight into the pane. Cron keeps rejecting multi-line prompts, but its docs and the code comments in cron-service.ts, schemas.ts and respawn-controller.ts gave a reason this change removes (writeViaMux joining lines, a newline submitting in Ink). The reason that remains is the submit check, which cannot recognise a multi-line paste in the composer, and for cron's paste mode the newlines reaching the CLI as keys. Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
This commit is contained in:
1 parent
e3de354461
commit
fe10cad83f
14 files changed
+58
-48
No files matched your search
@@ -420,8 +420,9 @@ callers send no body at all.
|
||||
**or Enter is never sent**: the text is typed onto the worker's prompt and sits
|
||||
there unsubmitted. This is [symptom 1](#1-deliveredtrue-then-every-wait-times-out),
|
||||
the number-one silent failure.
|
||||
- Newlines in `input` are kept: the text goes in as one bracketed paste and the `\r`
|
||||
submits all lines. To send a bare Enter (confirm a dialog), send `{"input":"\r"}`.
|
||||
- With `useMux`, newlines in `input` are kept: the text goes in as one bracketed paste
|
||||
and the `\r` submits all lines (without `useMux`, multi-line input is written straight
|
||||
into the pane). To send a bare Enter (confirm a dialog), send `{"input":"\r"}`.
|
||||
- `input` is capped at **65536** characters. ⚠️ **Two caps disagree and the smaller one
|
||||
is the real one**: the Zod schema allows 100000 (`schemas.ts:1035`), so a 65537-to-100000
|
||||
character body passes validation and *then* 400s at the route against
|
||||
|
||||
@@ -303,10 +303,11 @@ duplicate resend costs nothing.
|
||||
Codeman types the text and sends Enter **only when the input contains a carriage
|
||||
return**; without it your command sits unsubmitted on the worker's prompt and
|
||||
everything downstream times out. No response field catches this: `delivered:true`
|
||||
means "written to the pane", **not** "submitted". Newlines are kept: the text goes in
|
||||
as one paste, and the `\r` submits all of it. Build the body with `jq -n` for any prompt you did not
|
||||
author as a literal, because the inline `-d '{"input":"'"$P"'\r"}'` pattern breaks on
|
||||
the first double quote, backslash or `$` in a real prompt:
|
||||
means "written to the pane", **not** "submitted". With `useMux`, newlines are kept: the
|
||||
text goes in as one paste, and the `\r` submits all of it. Build the body with `jq -n`
|
||||
for any prompt you did not author as a literal, because the inline
|
||||
`-d '{"input":"'"$P"'\r"}'` pattern breaks on the first double quote, backslash or `$`
|
||||
in a real prompt:
|
||||
|
||||
```bash
|
||||
BODY=$(jq -n --arg p "$PROMPT" '{input:($p+"\r"),useMux:true,clientId:"agent-1",seq:1,wait:true,waitTimeout:60000}')
|
||||
@@ -587,9 +588,9 @@ allowlist in §4.
|
||||
|
||||
### 5.9 Big input via the workspace
|
||||
|
||||
The composer is a single line capped at 65536 characters with newlines stripped, which
|
||||
makes it a bad channel for a spec, a diff or a file list. The workspace is the good
|
||||
one, and for a local or docker case you are on the same filesystem as the worker.
|
||||
The composer is capped at 65536 characters, and a multi-line paste cannot be confirmed
|
||||
as submitted, which makes it a bad channel for a spec, a diff or a file list. The
|
||||
workspace is the good one, and for a local or docker case you are on the same filesystem as the worker.
|
||||
|
||||
1. Write `TASK.md` into the worker's workspace with your own file tools. The path is
|
||||
`.data.casePath` from `quick-start`, or the `workingDir` you passed to
|
||||
|
||||
Reference in new issue
Block a user