mirror of
https://github.com/jparkerweb/plan2code.git
synced 2026-11-16 04:45:33 -08:00
Merge pull request #6 from jparkerweb/develop
Let Send through when an agent asks a question mid-build while still …
This commit is contained in:
commit
ade74cd636
29 files changed
+309
-28
No files matched your search
@@ -51,6 +51,7 @@ All notable changes to Plan2Code will be documented in this file.
|
||||
|
||||
- **pathfinder**: charting no longer ends the session, or shows "Session ended" in the web console, while its research subagents are still running. They live in the terminal's process, so closing it on a "done" page killed them mid-write. The session now waits for every one (the page shows a running count), each subagent ends `## Evidence` with a `**Research complete:**` line, and Work Step 2 re-fires any research question missing it. `console.md` makes the same rule general: no `finish` while any subagent or background job is still out.
|
||||
- **web-console**: reusing a settled question id for a different kind of question (say a multi-select turned confirm) now opens it as a new question instead of keeping the old answer.
|
||||
- **web-console**: Send no longer stays disabled when an agent posts a question mid-build while still marked `working` (seen on Implement + Review, where the question said "I'm carrying on while you decide"). Once an open question has an answer or a note staged, Send unlocks at once with "Still working · it reads this next", instead of waiting out the agent's `quietMinutes` (up to an hour); the server holds the send until the agent next looks. `building.md` now says a question stops the build: set `waiting` in the same post as the question and wait, never keep working with a question open.
|
||||
|
||||
### 📚 Documentation
|
||||
|
||||
|
||||
@@ -135,8 +135,15 @@ not questions. Put them in the phase doc as they happen, and in the report.
|
||||
|
||||
### When the workflow asks something
|
||||
|
||||
Publish it, set `"agent": { "status": "waiting", "quietMinutes": null }`, and
|
||||
go into the wait loop. When the answer lands, set `working` again and carry on.
|
||||
Publish it, set `"agent": { "status": "waiting", "quietMinutes": null }` in
|
||||
the SAME post, and go into the wait loop. When the answer lands, set `working`
|
||||
again and carry on.
|
||||
|
||||
A question stops the build. Never leave yourself `working` with a question
|
||||
open, and never "carry on while you decide": the page reads `working` as "not
|
||||
your turn", and the person is left looking at a question they cannot answer.
|
||||
If there is other work the answer does not touch, finish it before you ask,
|
||||
then ask and wait.
|
||||
|
||||
| Moment | `kind` | Notes |
|
||||
| --- | --- | --- |
|
||||
|
||||
@@ -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
|
||||
|
||||
@@ -135,8 +135,15 @@ not questions. Put them in the phase doc as they happen, and in the report.
|
||||
|
||||
### When the workflow asks something
|
||||
|
||||
Publish it, set `"agent": { "status": "waiting", "quietMinutes": null }`, and
|
||||
go into the wait loop. When the answer lands, set `working` again and carry on.
|
||||
Publish it, set `"agent": { "status": "waiting", "quietMinutes": null }` in
|
||||
the SAME post, and go into the wait loop. When the answer lands, set `working`
|
||||
again and carry on.
|
||||
|
||||
A question stops the build. Never leave yourself `working` with a question
|
||||
open, and never "carry on while you decide": the page reads `working` as "not
|
||||
your turn", and the person is left looking at a question they cannot answer.
|
||||
If there is other work the answer does not touch, finish it before you ask,
|
||||
then ask and wait.
|
||||
|
||||
| Moment | `kind` | Notes |
|
||||
| --- | --- | --- |
|
||||
|
||||
@@ -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
|
||||
|
||||
@@ -135,8 +135,15 @@ not questions. Put them in the phase doc as they happen, and in the report.
|
||||
|
||||
### When the workflow asks something
|
||||
|
||||
Publish it, set `"agent": { "status": "waiting", "quietMinutes": null }`, and
|
||||
go into the wait loop. When the answer lands, set `working` again and carry on.
|
||||
Publish it, set `"agent": { "status": "waiting", "quietMinutes": null }` in
|
||||
the SAME post, and go into the wait loop. When the answer lands, set `working`
|
||||
again and carry on.
|
||||
|
||||
A question stops the build. Never leave yourself `working` with a question
|
||||
open, and never "carry on while you decide": the page reads `working` as "not
|
||||
your turn", and the person is left looking at a question they cannot answer.
|
||||
If there is other work the answer does not touch, finish it before you ask,
|
||||
then ask and wait.
|
||||
|
||||
| Moment | `kind` | Notes |
|
||||
| --- | --- | --- |
|
||||
|
||||
@@ -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
|
||||
|
||||
@@ -135,8 +135,15 @@ not questions. Put them in the phase doc as they happen, and in the report.
|
||||
|
||||
### When the workflow asks something
|
||||
|
||||
Publish it, set `"agent": { "status": "waiting", "quietMinutes": null }`, and
|
||||
go into the wait loop. When the answer lands, set `working` again and carry on.
|
||||
Publish it, set `"agent": { "status": "waiting", "quietMinutes": null }` in
|
||||
the SAME post, and go into the wait loop. When the answer lands, set `working`
|
||||
again and carry on.
|
||||
|
||||
A question stops the build. Never leave yourself `working` with a question
|
||||
open, and never "carry on while you decide": the page reads `working` as "not
|
||||
your turn", and the person is left looking at a question they cannot answer.
|
||||
If there is other work the answer does not touch, finish it before you ask,
|
||||
then ask and wait.
|
||||
|
||||
| Moment | `kind` | Notes |
|
||||
| --- | --- | --- |
|
||||
|
||||
@@ -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
|
||||
|
||||
@@ -135,8 +135,15 @@ not questions. Put them in the phase doc as they happen, and in the report.
|
||||
|
||||
### When the workflow asks something
|
||||
|
||||
Publish it, set `"agent": { "status": "waiting", "quietMinutes": null }`, and
|
||||
go into the wait loop. When the answer lands, set `working` again and carry on.
|
||||
Publish it, set `"agent": { "status": "waiting", "quietMinutes": null }` in
|
||||
the SAME post, and go into the wait loop. When the answer lands, set `working`
|
||||
again and carry on.
|
||||
|
||||
A question stops the build. Never leave yourself `working` with a question
|
||||
open, and never "carry on while you decide": the page reads `working` as "not
|
||||
your turn", and the person is left looking at a question they cannot answer.
|
||||
If there is other work the answer does not touch, finish it before you ask,
|
||||
then ask and wait.
|
||||
|
||||
| Moment | `kind` | Notes |
|
||||
| --- | --- | --- |
|
||||
|
||||
@@ -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
|
||||
|
||||
@@ -135,8 +135,15 @@ not questions. Put them in the phase doc as they happen, and in the report.
|
||||
|
||||
### When the workflow asks something
|
||||
|
||||
Publish it, set `"agent": { "status": "waiting", "quietMinutes": null }`, and
|
||||
go into the wait loop. When the answer lands, set `working` again and carry on.
|
||||
Publish it, set `"agent": { "status": "waiting", "quietMinutes": null }` in
|
||||
the SAME post, and go into the wait loop. When the answer lands, set `working`
|
||||
again and carry on.
|
||||
|
||||
A question stops the build. Never leave yourself `working` with a question
|
||||
open, and never "carry on while you decide": the page reads `working` as "not
|
||||
your turn", and the person is left looking at a question they cannot answer.
|
||||
If there is other work the answer does not touch, finish it before you ask,
|
||||
then ask and wait.
|
||||
|
||||
| Moment | `kind` | Notes |
|
||||
| --- | --- | --- |
|
||||
|
||||
@@ -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
|
||||
|
||||
@@ -135,8 +135,15 @@ not questions. Put them in the phase doc as they happen, and in the report.
|
||||
|
||||
### When the workflow asks something
|
||||
|
||||
Publish it, set `"agent": { "status": "waiting", "quietMinutes": null }`, and
|
||||
go into the wait loop. When the answer lands, set `working` again and carry on.
|
||||
Publish it, set `"agent": { "status": "waiting", "quietMinutes": null }` in
|
||||
the SAME post, and go into the wait loop. When the answer lands, set `working`
|
||||
again and carry on.
|
||||
|
||||
A question stops the build. Never leave yourself `working` with a question
|
||||
open, and never "carry on while you decide": the page reads `working` as "not
|
||||
your turn", and the person is left looking at a question they cannot answer.
|
||||
If there is other work the answer does not touch, finish it before you ask,
|
||||
then ask and wait.
|
||||
|
||||
| Moment | `kind` | Notes |
|
||||
| --- | --- | --- |
|
||||
|
||||
@@ -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
|
||||
|
||||
@@ -135,8 +135,15 @@ not questions. Put them in the phase doc as they happen, and in the report.
|
||||
|
||||
### When the workflow asks something
|
||||
|
||||
Publish it, set `"agent": { "status": "waiting", "quietMinutes": null }`, and
|
||||
go into the wait loop. When the answer lands, set `working` again and carry on.
|
||||
Publish it, set `"agent": { "status": "waiting", "quietMinutes": null }` in
|
||||
the SAME post, and go into the wait loop. When the answer lands, set `working`
|
||||
again and carry on.
|
||||
|
||||
A question stops the build. Never leave yourself `working` with a question
|
||||
open, and never "carry on while you decide": the page reads `working` as "not
|
||||
your turn", and the person is left looking at a question they cannot answer.
|
||||
If there is other work the answer does not touch, finish it before you ask,
|
||||
then ask and wait.
|
||||
|
||||
| Moment | `kind` | Notes |
|
||||
| --- | --- | --- |
|
||||
|
||||
@@ -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
|
||||
|
||||
@@ -135,8 +135,15 @@ not questions. Put them in the phase doc as they happen, and in the report.
|
||||
|
||||
### When the workflow asks something
|
||||
|
||||
Publish it, set `"agent": { "status": "waiting", "quietMinutes": null }`, and
|
||||
go into the wait loop. When the answer lands, set `working` again and carry on.
|
||||
Publish it, set `"agent": { "status": "waiting", "quietMinutes": null }` in
|
||||
the SAME post, and go into the wait loop. When the answer lands, set `working`
|
||||
again and carry on.
|
||||
|
||||
A question stops the build. Never leave yourself `working` with a question
|
||||
open, and never "carry on while you decide": the page reads `working` as "not
|
||||
your turn", and the person is left looking at a question they cannot answer.
|
||||
If there is other work the answer does not touch, finish it before you ask,
|
||||
then ask and wait.
|
||||
|
||||
| Moment | `kind` | Notes |
|
||||
| --- | --- | --- |
|
||||
|
||||
@@ -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
|
||||
|
||||
@@ -135,8 +135,15 @@ not questions. Put them in the phase doc as they happen, and in the report.
|
||||
|
||||
### When the workflow asks something
|
||||
|
||||
Publish it, set `"agent": { "status": "waiting", "quietMinutes": null }`, and
|
||||
go into the wait loop. When the answer lands, set `working` again and carry on.
|
||||
Publish it, set `"agent": { "status": "waiting", "quietMinutes": null }` in
|
||||
the SAME post, and go into the wait loop. When the answer lands, set `working`
|
||||
again and carry on.
|
||||
|
||||
A question stops the build. Never leave yourself `working` with a question
|
||||
open, and never "carry on while you decide": the page reads `working` as "not
|
||||
your turn", and the person is left looking at a question they cannot answer.
|
||||
If there is other work the answer does not touch, finish it before you ask,
|
||||
then ask and wait.
|
||||
|
||||
| Moment | `kind` | Notes |
|
||||
| --- | --- | --- |
|
||||
|
||||
@@ -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
|
||||
|
||||
@@ -135,8 +135,15 @@ not questions. Put them in the phase doc as they happen, and in the report.
|
||||
|
||||
### When the workflow asks something
|
||||
|
||||
Publish it, set `"agent": { "status": "waiting", "quietMinutes": null }`, and
|
||||
go into the wait loop. When the answer lands, set `working` again and carry on.
|
||||
Publish it, set `"agent": { "status": "waiting", "quietMinutes": null }` in
|
||||
the SAME post, and go into the wait loop. When the answer lands, set `working`
|
||||
again and carry on.
|
||||
|
||||
A question stops the build. Never leave yourself `working` with a question
|
||||
open, and never "carry on while you decide": the page reads `working` as "not
|
||||
your turn", and the person is left looking at a question they cannot answer.
|
||||
If there is other work the answer does not touch, finish it before you ask,
|
||||
then ask and wait.
|
||||
|
||||
| Moment | `kind` | Notes |
|
||||
| --- | --- | --- |
|
||||
|
||||
@@ -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
|
||||
|
||||
@@ -135,8 +135,15 @@ not questions. Put them in the phase doc as they happen, and in the report.
|
||||
|
||||
### When the workflow asks something
|
||||
|
||||
Publish it, set `"agent": { "status": "waiting", "quietMinutes": null }`, and
|
||||
go into the wait loop. When the answer lands, set `working` again and carry on.
|
||||
Publish it, set `"agent": { "status": "waiting", "quietMinutes": null }` in
|
||||
the SAME post, and go into the wait loop. When the answer lands, set `working`
|
||||
again and carry on.
|
||||
|
||||
A question stops the build. Never leave yourself `working` with a question
|
||||
open, and never "carry on while you decide": the page reads `working` as "not
|
||||
your turn", and the person is left looking at a question they cannot answer.
|
||||
If there is other work the answer does not touch, finish it before you ask,
|
||||
then ask and wait.
|
||||
|
||||
| Moment | `kind` | Notes |
|
||||
| --- | --- | --- |
|
||||
|
||||
@@ -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
|
||||
|
||||
@@ -135,8 +135,15 @@ not questions. Put them in the phase doc as they happen, and in the report.
|
||||
|
||||
### When the workflow asks something
|
||||
|
||||
Publish it, set `"agent": { "status": "waiting", "quietMinutes": null }`, and
|
||||
go into the wait loop. When the answer lands, set `working` again and carry on.
|
||||
Publish it, set `"agent": { "status": "waiting", "quietMinutes": null }` in
|
||||
the SAME post, and go into the wait loop. When the answer lands, set `working`
|
||||
again and carry on.
|
||||
|
||||
A question stops the build. Never leave yourself `working` with a question
|
||||
open, and never "carry on while you decide": the page reads `working` as "not
|
||||
your turn", and the person is left looking at a question they cannot answer.
|
||||
If there is other work the answer does not touch, finish it before you ask,
|
||||
then ask and wait.
|
||||
|
||||
| Moment | `kind` | Notes |
|
||||
| --- | --- | --- |
|
||||
|
||||
@@ -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
|
||||
|
||||
@@ -135,8 +135,15 @@ not questions. Put them in the phase doc as they happen, and in the report.
|
||||
|
||||
### When the workflow asks something
|
||||
|
||||
Publish it, set `"agent": { "status": "waiting", "quietMinutes": null }`, and
|
||||
go into the wait loop. When the answer lands, set `working` again and carry on.
|
||||
Publish it, set `"agent": { "status": "waiting", "quietMinutes": null }` in
|
||||
the SAME post, and go into the wait loop. When the answer lands, set `working`
|
||||
again and carry on.
|
||||
|
||||
A question stops the build. Never leave yourself `working` with a question
|
||||
open, and never "carry on while you decide": the page reads `working` as "not
|
||||
your turn", and the person is left looking at a question they cannot answer.
|
||||
If there is other work the answer does not touch, finish it before you ask,
|
||||
then ask and wait.
|
||||
|
||||
| Moment | `kind` | Notes |
|
||||
| --- | --- | --- |
|
||||
|
||||
@@ -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