Repository navigation
UX: freshly-started workflows show all-red at t=0 — add scheduled/not-started state + richer bundle cards #106
Description
Freshly-started workflows show all-red at t=0: add scheduled/not-started state + richer bundle cards
Status: pending
Tags: enhancement, frontend, backend, P2
Depends on: #105
Blocks: None
Groomed from the same live UX audit. #5: freshly-started workflows are instantly
all-red, destroying the signal value of the risk indicators. A workflow anchored
today (started from a template) immediately shows Overdue 9 / Missing evidence
15 / At risk on every task, because template task offsets are pre-publication
(relative to a future anchor/event) — so tasks with negative offsets land in the
past the moment the bundle is created. At t=0 the operator cannot tell a
genuinely late workflow from a brand-new one. Evidence:
.tmp/screenshots/ux-audit/13-bundle-header.png,15-dashboard-populated.png.
Scope
Two related changes:
-
Scheduled / not-started semantics. Template instantiation
(instantiateTemplateinbackend/src/db/templates.ts, ~lines 129-160)
computes each task date asanchorDate + offsetDays; with negative offsets and
an anchor of today, tasks are born in the past. The risk/queue helpers on the
frontend (bundleRiskSummary~line 707,dashboardQueueLabels/
taskPrimaryQueueGroup~lines 677-705) then flag them Overdue / Missing
evidence / At risk. A freshly-created workflow must not be flagged
overdue/at-risk before its tasks are genuinely due. Introduce a
"scheduled / not-started" treatment so not-yet-worked template tasks are shown
as scheduled rather than overdue at t=0. The engineer should choose the
simplest correct mechanism and document it; candidate approaches:- a bundle-level "not started / scheduled" state that suppresses
overdue/missing-evidence/at-risk flags until the operator activates the
workflow (e.g. on first task action or an explicit "Start"), or - treating a task as not-overdue when its due date is before the bundle's
creation date (i.e. do not retroactively mark pre-anchor tasks late for a
bundle created today).
The chosen rule must be applied consistently inbundleRiskSummary, the
dashboard queue grouping, and the bundle risk header so the same task is not
"overdue" in one place and "scheduled" in another.
- a bundle-level "not started / scheduled" state that suppresses
-
Richer bundle-list cards. The Bundles list card (
loadBundles,
~lines 3820-3843) shows only "N / M done". Enrich it to also show stage,
next-due date, overdue count, and waiting count — the same summary the
dashboard bundle card and the detail header already compute via
bundleRiskSummary(renderBundleCard~line 1682). Reuse that helper; do not
duplicate risk logic.
Serves JTBD 2 ("The first next action is immediately visible after creation"),
JTBD 3 ("Workflow detail shows stage, progress, next due task, overdue count, and
waiting count"), and the reminder model (overdue reminders "catch tasks that were
not closed on time" — a t=0 task was never late).
Acceptance Criteria
- A workflow started from a template with an anchor of today does NOT show all
tasks as Overdue / Missing evidence / At risk at creation time; tasks that
are not yet genuinely due are shown as scheduled/not-started instead. - A genuinely late task (past its due date after the workflow has been active)
is still flagged Overdue — the scheduled treatment applies only to
not-yet-worked / freshly-created tasks, not as a blanket suppression. - The scheduled/overdue/at-risk rule is consistent across the dashboard queue
grouping, the dashboard bundle card, and the bundle detail risk header (the
same task is never "overdue" in one view and "scheduled" in another). - The Bundles list card shows, in addition to progress: stage, next-due date,
overdue count, and waiting count (reusingbundleRiskSummary). - A brand-new bundle's list card and header read as a healthy new workflow
(e.g. "0 overdue", a next-due date), not "Overdue 9 / Missing evidence 15". - If a stored bundle state/field is added, it is declared in the data model
(backend/src/types.ts) and the SAM/CloudFormation-managed table is used —
no unmanaged tables or one-off migrations; export/restore
(npm run export:data,npm run validate:export) still round-trips.
Test Scenarios
Scenario: New workflow is not all-red at t=0
Given: Grace starts a Newsletter workflow anchored today from its template
When: she opens the bundle and the dashboard
Then: the tasks that fall before the anchor are shown as scheduled/not-started,
the bundle is not "Overdue 9 / Missing evidence 15 / At risk", and a clear
next-due is visible.
Scenario: Genuine overdue still flags
Given: an active workflow with a task whose due date has passed while the
workflow was in progress
When: the dashboard and bundle render
Then: that task is still shown Overdue.
Scenario: Bundle-list card carries risk
Given: the Bundles list with several bundles
When: it renders
Then: each card shows stage, next-due, overdue count, and waiting count in
addition to progress.
Out of Scope
- Dashboard section IA (UX: dashboard IA — lead with Today / Overdue / Follow-ups due / At-risk, demote intake counters #105 — this issue relies on the At-risk section that UX: dashboard IA — lead with Today / Overdue / Follow-ups due / At-risk, demote intake counters #105
establishes). - Task-row (UX: collapse task rows — every task renders a full always-expanded form #102) and Daily-Queue row (UX: dashboard Daily Queue should surface next-action button, not embed the completion editor #103) disclosure, and template start
consolidation (UX: consolidate workflow-start into the Templates library (add Start action; remove scattered launcher forms) #104). - Reworking template offset values themselves in content/templates.
- Source repos
../dtc-operations,../datatasks,../podcast-assistant.
Dependencies
- Depends on UX: dashboard IA — lead with Today / Overdue / Follow-ups due / At-risk, demote intake counters #105: UX: dashboard IA — lead with Today / Overdue / Follow-ups due / At-risk, demote intake counters #105 makes the four core sections (incl. At-risk) the
top-level structure; this issue refines how freshly-started tasks are
classified within Today/Overdue/At-risk. Do UX: dashboard IA — lead with Today / Overdue / Follow-ups due / At-risk, demote intake counters #105 first. - Data-safety: if a bundle field/state is added, cover it in the portable export
(backend/src/export/portable.ts) and confirm restore-drill round-trips.
Verification
- From
backend/:npm test(backend unit tests, node --test) covering the
scheduled/overdue classification andinstantiateTemplatedate behavior. - From
backend/:npm run typecheck. - From
backend/:npm run test:e2e— at minimumhome-dashboard.spec.js,
bundle-detail.spec.js, andapi-instantiation.spec.js; add a spec asserting a
today-anchored template workflow is not all-red at creation and that the bundle
list card shows stage/next-due/overdue/waiting. - If export shape changes:
npm run export:data+npm run validate:export(or
npm run restore:drill) to confirm round-trip; outputs under.tmp/exports/. - Playwright screenshots of a freshly-started bundle detail + header and the
Bundles list under.tmp/screenshots/ux-audit/, read to confirm it no longer
reads all-red.
Activity
alexeygrigorev commentedon Jul 30, 2026
Software Engineer handoff
Implemented the scheduled/not-started treatment and richer bundle cards on isolated branch
issue-106-scheduled, based on98fdc1fc9de41b463179392a41f393cee245288a.Chosen rule: a task is derived as Scheduled only when it is an untouched template
todotask with a strict validYYYY-MM-DDnominal date before the bundle's valid creation calendar date. Missing/invalid provenance falls back to legacy risk behavior; ad-hoc, recurring, waiting, and other non-todotasks remain active. Future tasks are excluded from missing-evidence/at-risk until due. No persisted field, migration, schema, or export-shape change was introduced.Changed files
backend/src/public/app.jsbackend/src/pages/index.htmlbackend/tests/home-dashboard.test.tsbackend/tests/bundle-detail.test.tsbackend/e2e/home-dashboard.spec.jsbackend/e2e/bundle-detail.spec.jsbackend/e2e/api-instantiation.spec.jsThe shared
bundleRiskSummarynow owns scheduled exclusion/counting, overdue/missing-evidence behavior, next-due selection, and the list/detail/dashboard summaries. The Bundles list reuses it to show stage, next due, overdue, waiting, and progress. The dashboard exposes a Scheduled overflow group and detail task pills/header show the same classification.Frozen uncommitted diff SHA-256:
134d1e9104fa2ebb60ad0081caa16a458c6d27ed5fce1d96fdd8809e8a2949a1Verification
NODE_ENV=test SKIP_AUTH=true node --import tsx --test tests/home-dashboard.test.ts tests/bundle-detail.test.ts— PASS, 100/100.npm test— PASS, 1,368 tests: 1,367 passed, 1 expected skip, 0 failed.npm run typecheck— PASS.npm run build— PASS.npx playwright test e2e/home-dashboard.spec.js e2e/bundle-detail.spec.js e2e/api-instantiation.spec.js— PASS, 75/75.node --checkon the changed browser JS/spec files andgit diff --check— PASS.Screenshots inspected
.tmp/screenshots/issue-106/dashboard-fresh-workflow-1440.png.tmp/screenshots/issue-106/dashboard-newsletter-t0-1440.png.tmp/screenshots/issue-106/bundles-list-rich-card-1280.png.tmp/screenshots/issue-106/bundle-detail-healthy-header-1280.pngAll four were opened and read. The seeded Newsletter at t=0 shows
Scheduled 9, no Overdue/At-risk entries, and only the genuinely due-today invoice's missing evidence. The list card and detail header show consistent next-due,Overdue 0,Waiting 0, and scheduled state without clipping, overlap, or error pages.Acceptance criteria
bundleRiskSummary.No commit or push has been made. Ready for independent Tester review.
alexeygrigorev commentedon Jul 30, 2026
CHANGES REQUESTED
Frozen diff reviewed:
98fdc1fc9de41b463179392a41f393cee245288a134d1e9104fa2ebb60ad0081caa16a458c6d27ed5fce1d96fdd8809e8a2949a1Blocking defect — archived tasks are treated as active workflow risk:
npx playwright test --config=../.tmp/issue106-test/playwright.config.js(frombackend/) — FAIL, 0/1.archived,requiresFile: true, and overdue/missing-evidence/at-risk dashboard states.Next due 2026-07-27 / Overdue 1 / Waiting 0(assertion expectedOverdue 0).Next due 2026-07-27 · Archived historical task,Overdue 1,Missing files 1; the archived row is also labeledOverdue / Missing evidence / At risk.bundleRiskSummaryandrenderWorkflowContextdefine active as every status exceptdone.TaskStatusalso includesarchived. This violates the reviewed done/archived terminal-state invariant and the cross-surface consistency/healthy-risk semantics required by UX: freshly-started workflows show all-red at t=0 — add scheduled/not-started state + richer bundle cards #106.doneandarchivedfrom shared risk, next-due, missing-proof/file, and task-row risk classification; add direct runtime regression coverage for archived tasks across Bundles list, bundle detail context/header, and task pills.Fresh screenshots captured and opened at original resolution:
.tmp/screenshots/issue-106-tester/archived-bundle-list-desktop.png.tmp/screenshots/issue-106-tester/archived-bundle-detail-desktop.png.tmp/screenshots/issue-106-tester/archived-bundle-detail-mobile.pngThe screenshots have no 404, error page, clipping, overlap, or unreadable mobile layout, but clearly show the blocking semantic defect.
Completed checks:
npm run typecheck— PASS, exit 0.npm run build— PASS, exit 0.git diff --check 98fdc1fc9de41b463179392a41f393cee245288a— PASS.npm testfirst run: 1,368 total; 1,366 passed, 1 expected skip, 1 unrelated Telegram uniqueness concurrency failure ([200,201]vs[201,409]). The UX: freshly-started workflows show all-red at t=0 — add scheduled/not-started state + richer bundle cards #106 gate is independently decided by the deterministic archived E2E failure.npm run test:e2ewas stopped once the deterministic blocker was confirmed: 296 tests had passed, including the UX: dashboard IA — lead with Today / Overdue / Follow-ups due / At-risk, demote intake counters #105 section-order tests, today/not-at-risk behavior, UX: freshly-started workflows show all-red at t=0 — add scheduled/not-started state + richer bundle cards #106 fresh-template scheduled semantics, seeded Newsletter t=0 behavior, richer bundle-list/detail summary, and genuine overdue behavior. The interruption is not presented as a full-suite pass.Acceptance-criterion assessment:
archivedtasks.Please return to SWE, fix terminal-state handling, add the missing archived regression tests, freeze a new diff hash, and send it back for a focused Tester rerun.
alexeygrigorev commentedon Jul 30, 2026
Software Engineer fix handoff
Addressed the Tester's archived-task blocker from #106 (comment) on the same isolated
issue-106-scheduledworktree.Fix
taskIsActiveinvariant: only tasks whose status is neitherdonenorarchivedcontribute operational work.bundleRiskSummaryactive/scheduled/overdue/waiting/follow-up/missing-evidence/next-due selection, missing-proof classification, andrenderWorkflowContextmissing-file counts.createdAtmetadata cannot invent Scheduled state and retain the documented legacy active/overdue behavior.The tracked diff remains limited to the original seven #106 files. No commit or push has been made.
Replacement frozen uncommitted diff SHA-256:
708fc6bdb4d9c87f6291f676b1a5827fbd060c34acc86420c03d002ceffe6f38Base HEAD:
98fdc1fc9de41b463179392a41f393cee245288aRegression coverage
The new runtime scenario creates one archived past required-file task and one genuine active overdue required-file task in the same bundle, then verifies:
Overdue 1;Waiting 0.Verification
git diff --check— PASS.NODE_ENV=test SKIP_AUTH=true node --import tsx --test tests/home-dashboard.test.ts tests/bundle-detail.test.ts— PASS, 101/101.npm run typecheck— PASS.npm run build— PASS.npm test— PASS, 1,369 tests: 1,368 passed, 1 expected skip, 0 failed.npx playwright test e2e/home-dashboard.spec.js e2e/bundle-detail.spec.js e2e/api-instantiation.spec.js— PASS, 77/77.Screenshots inspected
.tmp/screenshots/issue-106/bundles-list-archived-excluded-1280.png.tmp/screenshots/issue-106/bundle-detail-archived-excluded-1280.png.tmp/screenshots/issue-106/dashboard-archived-excluded-1280.pngAll were opened at original resolution. They show the active overdue task as the only risk-bearing work, archived history isolated under Archived, and no clipping, overlap, 404, or error page.
Ready for focused Tester rerun against the replacement frozen diff.
alexeygrigorev commentedon Jul 30, 2026
CHANGES REQUESTED
Replacement candidate reviewed:
98fdc1fc9de41b463179392a41f393cee245288a708fc6bdb4d9c87f6291f676b1a5827fbd060c34acc86420c03d002ceffe6f38The original archived-task blocker is substantially fixed:
NODE_ENV=test SKIP_AUTH=true node --import tsx --test tests/home-dashboard.test.ts tests/bundle-detail.test.ts— PASS, 101/101.Blocking remaining defect — an archived-only shared-link requirement still contributes live workflow risk:
npx playwright test archived-link-risk.spec.js --config=../.tmp/issue106-test/playwright.config.js— FAIL, 0/1.Campaignbundle link and exactly one task requiring that link; the only requiring task has valid terminal statusarchived.Missing links 0.Missing links 1.renderWorkflowContextcallsisBundleLinkMissing(link, tasks)with every task.emptyBundleLinkCoveredBySkipincludes archived requiring tasks and only suppresses a requirement when every task isdonewith a matching skip closure. It does not apply the new sharedtaskIsActiveterminal-state invariant.Other completed checks:
npm run typecheck— PASS, exit 0.npm run build— PASS, exit 0.git diff --check 98fdc1fc9de41b463179392a41f393cee245288a— PASS.Fresh screenshots opened at original resolution:
.tmp/screenshots/issue-106/bundles-list-archived-excluded-1280.png.tmp/screenshots/issue-106/bundle-detail-archived-excluded-1280.png.tmp/screenshots/issue-106/dashboard-archived-excluded-1280.png.tmp/screenshots/issue-106-retest/archived-shared-link-detail-desktop.pngThe core replacement screenshots are clean and readable with no 404, error page, clipping, or overlap. The archived-only shared-link capture visibly shows the empty Campaign link as an active highlighted gap even though Archived is the only task section.
Acceptance assessment:
Please return to SWE for the shared-link terminal-state fix, add the missing runtime regression, freeze a new diff hash, and send it back for focused Tester verification.
alexeygrigorev commentedon Jul 30, 2026
Software Engineer shared-link fix handoff
Addressed the second Tester finding from #106 (comment).
Fix
The bundle-link missing/coverage path now applies the shared terminal-state rule:
Missing links 0and no empty-risk highlight.No model, persistence, export, migration, or infrastructure change was introduced. The tracked diff remains limited to the same seven #106 files, with no commit or push.
Replacement frozen uncommitted diff SHA-256:
f913639912625e2716d882e0862902ae47fcfc0493bb6b795f15b7aae57d2c74Base HEAD:
98fdc1fc9de41b463179392a41f393cee245288aDeterministic regression
The archived-task runtime scenario now exercises all three shared-link cases:
Campaignrequirement:Missing links 0; Campaign row is not highlighted.Active controlrequirement:Missing links 1; only Active control is highlighted.Missing links 2; both active requirements are highlighted.The same scenario continues to prove archived exclusion from Next due, Overdue, Waiting, Scheduled, Missing files/evidence, At risk, dashboard rows, and task controls while genuine active overdue behavior remains.
Verification
git diff --check— PASS.NODE_ENV=test SKIP_AUTH=true node --import tsx --test tests/home-dashboard.test.ts tests/bundle-detail.test.ts— PASS, 101/101.npm run typecheck— PASS.npm run build— PASS.npm test— PASS, 1,369 tests: 1,368 passed, 1 expected skip, 0 failed.npx playwright test e2e/home-dashboard.spec.js e2e/bundle-detail.spec.js e2e/api-instantiation.spec.js— PASS, 77/77.Screenshots inspected
.tmp/screenshots/issue-106/bundle-detail-archived-excluded-1280.png— archived-only Campaign is neutral and Missing links is zero..tmp/screenshots/issue-106/bundle-detail-shared-link-terminal-control-1280.png— active/mixed controls are highlighted and Missing links is two.Both were opened at original resolution and contain no clipping, overlap, 404, or error page.
Ready for focused Tester rerun against this replacement frozen diff.
alexeygrigorev commentedon Jul 30, 2026
TEST PASS
Final independent Tester gate for the third candidate:
98fdc1fc9de41b463179392a41f393cee245288a.f913639912625e2716d882e0862902ae47fcfc0493bb6b795f15b7aae57d2c74.Commands and results:
NODE_ENV=test SKIP_AUTH=true node --import tsx --test tests/home-dashboard.test.ts tests/bundle-detail.test.ts— exit 0, 101/101 passed.npx playwright test e2e/home-dashboard.spec.js e2e/bundle-detail.spec.js e2e/api-instantiation.spec.js --grep "(#105|#106|shows missing proof controls and completes after operator enters proof or skip status)"— exit 0, 10/10 passed.npm run typecheck— exit 0.npm run build— exit 0.node --checkfor changedapp.jsand all three changed browser specs — exit 0.git diff --check 98fdc1fc9de41b463179392a41f393cee245288a— exit 0.Decisive regressions:
Missing links 0and no risk highlight. Active-only requirement rendersMissing links 1. Mixed active+archived Campaign plus active control rendersMissing links 2; both live requirements remain highlighted. The pre-existing completed-task explicit skip-closure scenario also passed, so terminal filtering did not regress done+skip coverage.Fresh screenshots regenerated by this run and opened at original resolution:
.tmp/screenshots/issue-106/bundles-list-rich-card-1280.png.tmp/screenshots/issue-106/bundle-detail-healthy-header-1280.png.tmp/screenshots/issue-106/dashboard-fresh-workflow-1440.png.tmp/screenshots/issue-106/dashboard-newsletter-t0-1440.png.tmp/screenshots/issue-106/bundles-list-archived-excluded-1280.png.tmp/screenshots/issue-106/bundle-detail-archived-excluded-1280.png.tmp/screenshots/issue-106/bundle-detail-shared-link-terminal-control-1280.png.tmp/screenshots/issue-106/dashboard-archived-excluded-1280.pngThey show the required states with no 404/error page, clipping, overlap, unreadable content, or missing state.
The SWE-reported full unit result (1,369 total: 1,368 passed, 1 expected skip) and three-spec browser result (77/77) are consistent with this independent focused gate; unrelated full suites were not rerun per the focused final-review assignment.
All six issue acceptance criteria are technically verified. Ready for Product Manager acceptance.
alexeygrigorev commentedon Jul 30, 2026
PM ACCEPTED
Accepted candidate:
98fdc1fc9de41b463179392a41f393cee245288af913639912625e2716d882e0862902ae47fcfc0493bb6b795f15b7aae57d2c74User-perspective acceptance:
Overdue 0, a clear current next due, and the retroactive template offset as Scheduled. The seeded Newsletter t=0 view shows nine Scheduled tasks, no overdue queue, and only the genuinely due-today invoice evidence requirement.todotasks dated before valid bundle creation metadata; it is not blanket risk suppression.bundleRiskSummary, dashboard grouping/card, Bundles list, detail context, and detail task pills agree on scheduled, overdue, waiting, missing-evidence, next-due, and at-risk semantics.Missing links 0); active-only and mixed active+archived requirements remain highlighted as live gaps; completed explicit skip-closure coverage remains intact.The independent final Tester gate is
TEST PASSat #106 (comment): focused unit 101/101, focused Playwright 10/10, typecheck/build/syntax/diff checks all exit 0, with the full SWE results also green (1,368 passed + 1 expected skip; 77/77 three-spec browser tests). Dependency #105 is closed and its accepted implementation is present in the base ancestry.Shipping instruction: return this unchanged frozen candidate to the Software Engineer to commit with
Closes #106; then the orchestrator should merge it locally tomain, pushmain, and launch On-Call monitoring per_docs/PROCESS.md.alexeygrigorev commentedon Jul 30, 2026
On-Call report — main
4f10a5bCode/test status: PASS. Production deployment: BLOCKED by the known unapplied live OIDC-role policy.
Push and closure
4f10a5b27b58a26c2ccb8e69acd180dfea905888(Improve fresh workflow scheduling signals).Closes #106.2026-07-30T09:28:10Z; no manual close was used.Workflow evidence
Deployment classification and production boundary
dataops-github-actions-deployrole:sqs:CreateQueueforConversationalExecutionFailureQueue;sqs:CreateQueueforSponsorCommunicationFailureQueue;ses:CreateConfigurationSetforSponsorSesConfigurationSet.SponsorCommunicationPrivateArchiveKeycreation and the sponsor CRM table update were cancelled as consequences of rollback; neither reported an independent application defect.UPDATE_ROLLBACK_COMPLETE. Runtime seeding and deployed-origin smoke were skipped.This exactly reproduces the known #124/#129 credentialed-operator boundary and is not a #106 code, test, SAM, or CI regression. Commit
4f10a5bdid not reach production; CloudFormation restored the prior stack state. The accepted combined role-policy source remainsDataTalksClub/aws-infraorigin/main2a1b95f, but it must be applied to the named-IAM stack by a credentialed operator before a fresh normalmaindeployment can verify production. No manual app deployment or AWS mutation was performed by On-Call.Recommended next step: keep #106 closed as shipped/test-verified, apply and verify the accepted #124/#129/#130 deploy-role stack through the existing operator handoff, then rerun fresh current
mainCI/CD and production smoke.ON-CALL DONE: repository gates green; production blocked at known live IAM apply boundary
Improve fresh workflow scheduling signals