mirror of
https://github.com/jparkerweb/plan2code.git
synced 2026-11-17 04:45:33 -08:00
Let Send through when an agent asks a question mid-build while still marked working: once an open question has an answer or note staged the web console unlocks Send at once instead of waiting out quietMinutes, and building.md now says a question stops the build (set waiting in the same post and wait)
This commit is contained in:
1 parent
d4234fe20a
commit
13ded0910b
29 files changed
+309
-28
No files matched your search
@@ -5658,6 +5658,19 @@ function sendState() {
|
||||
: { disabled: true, why: "Your last answers are on their way. One moment.", short: "" };
|
||||
}
|
||||
if (agentWorking()) {
|
||||
// A question the agent left open while still working is still a question,
|
||||
// and its answer has nowhere better to wait than the server, which holds
|
||||
// a send until the agent next looks. The contract says to switch to
|
||||
// "waiting" before asking, but an agent that asks and carries on ("while
|
||||
// you decide") must not lock the person out of answering for up to an
|
||||
// hour of quietMinutes.
|
||||
if (myTurn().length && (stagedCount() || pendingNotes().length)) {
|
||||
return {
|
||||
disabled: false,
|
||||
why: "Plan2Code is still working. Your answers wait for it to look.",
|
||||
short: "Still working · it reads this next",
|
||||
};
|
||||
}
|
||||
const ms = workingMs();
|
||||
if (ms > patience(WORKING_GRACE_MS)) {
|
||||
// A stuck agent must not lock someone out of their own session, so the
|
||||
|
||||
Reference in new issue
Block a user