Repository navigation
feat(build-notes): draft workflow builds in hidden, agent-only build notes - #10193
myxamediyar wants to merge 16 commits into
Conversation
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
[Medium impact] The PR appears safe to merge; no new blocking issue was established. SummaryAdds hidden, Copilot-only workflow build notes behind the
|
There was a problem hiding this comment.
All reported issues were addressed across 48 files
This PR changes authentication, authorization, or input validation. Ultrareviews find 2.4x more serious bugs than standard reviews. Comment @cubic-dev-ai ultrareview to run one.
Turn on auto-fix | Re-trigger cubic
ff6a245 to
1d34bab
Compare
|
@cubic-dev-ai review this PR |
@myxamediyar I have started the AI code review. It will take a few minutes to complete. |
|
@cubic-dev-ai review this PR |
@myxamediyar I have started the AI code review. It will take a few minutes to complete. |
There was a problem hiding this comment.
All reported issues were addressed across 50 files
Reply with feedback, questions, or to request a fix.
Turn on auto-fix | Re-trigger cubic
b094961 to
f0adcf2
Compare
|
@cubic-dev-ai review this PR |
@myxamediyar I have started the AI code review. It will take a few minutes to complete. |
There was a problem hiding this comment.
1 issue found across 50 files
Confidence score: 4/5
- In
apps/sim/lib/build-notes/content.ts, notes can be written withnotes.baselineFileIdnull, leaving an incomplete row that can be evaluated without a baseline. Reject the write and direct callers to runbuild-notes rebasefirst.
Prompt for AI agents (unresolved issues)
Check if these issues are valid — if so, understand the root cause of each and fix them. When an issue isn't valid or won't be fixed in this PR, reply in its thread with the reason and then resolve the thread. If appropriate, use sub-agents to investigate and fix each issue separately.
<file name="apps/sim/lib/build-notes/content.ts">
<violation number="1" location="apps/sim/lib/build-notes/content.ts:21">
P2: A notes write is accepted while `notes.baselineFileId` is null. Refuse it and direct the caller to run `build-notes rebase` before editing notes, so an incomplete notes row cannot be evaluated without a baseline.
(Based on your team's feedback about requiring a baseline before guarded writes.)</violation>
</file>
Reply with feedback, questions, or to request a fix.
Turn on auto-fix | Re-trigger cubic
|
@cubic-dev-ai review this PR |
@myxamediyar I have started the AI code review. It will take a few minutes to complete. |
There was a problem hiding this comment.
All reported issues were addressed across 50 files
You've manually re-run cubic several times on this PR. Each manual re-review checks the full PR again and counts toward your usage quota. To preserve your usage limits, we recommend letting cubic automatically review new commits.
Turn on auto-fix | Re-trigger cubic
@myxamediyar I have started the AI code review. It will take a few minutes to complete. |
There was a problem hiding this comment.
All reported issues were addressed across 50 files
You've manually re-run cubic several times on this PR. Each manual re-review checks the full PR again and counts toward your usage quota. To preserve your usage limits, we recommend letting cubic automatically review new commits.
Turn on auto-fix | Re-trigger cubic
…un, and document the module APIs
# Conflicts: # packages/db/migrations/meta/0473_snapshot.json # packages/db/migrations/meta/_journal.json
|
@cubic-dev-ai review this PR |
@myxamediyar I have started the AI code review. It will take a few minutes to complete. |
|
@cubic-dev-ai review this PR |
@myxamediyar I have started the AI code review. It will take a few minutes to complete. |
|
@cubic-dev-ai review this PR |
@myxamediyar I have started the AI code review. It will take a few minutes to complete. |
There was a problem hiding this comment.
All reported issues were addressed across 54 files
You've manually re-run cubic several times on this PR. Each manual re-review checks the full PR again and counts toward your usage quota. To preserve your usage limits, we recommend letting cubic automatically review new commits.
Turn on auto-fix | Re-trigger cubic
…dicts to the notes revision
|
@cubic-dev-ai review this PR |
@myxamediyar I have started the AI code review. It will take a few minutes to complete. |
There was a problem hiding this comment.
No issues found across 54 files
Confidence score: 5/5
- Automated review surfaced no issues in the provided summaries.
- No files require special attention.
You've manually re-run cubic several times on this PR. Each manual re-review checks the full PR again and counts toward your usage quota. To preserve your usage limits, we recommend letting cubic automatically review new commits.
Turn on auto-fix | Re-trigger cubic
Summary
build-notesfeature flag (off by default; global and per-organization rollout)build-notes/<workflowId>.mdbefore it changes the graph; Sim keeps the sanitized graph of its last build beside it inbuild-notes/<workflowId>.baseline.jsonworkflow_build_notestable owns both files (owned-file contextbuild_notes): never listed in Files, reachable only by Copilot (people and API keys get not found), archived and restored with the workflow, never copied by duplicate, fork or exportbuild_notesCopilot service:create,status,evaluate(dry-runs the notes' operations block and lists open<<open:…>>placeholders,[gather]/[ask]items, skipped operations, input errors, and lint the batch adds),apply(builds from the evaluated block, atomically),changes(redacted diff since the baseline, ignoring layout),rebaseoperations applymust be the evaluated batch, from notes unchanged since evaluation, on a graph unchanged since the baseline (credential switches included, through salted hashes of withheld values); the check holds under the workflow lock, where the build spends the evaluation, and the baseline moves to exactly what the build committed. A Copilotstate replaceis refused. A person's edit (editor or API) is never refused; it shows up inchangesworkflow_build_notesand lets the file ownership functions admit thebuild_notescontext (reconcile-file-ownershipreplays them for push-provisioned databases)listWorkflowLintFindingslets evaluation compare a batch's lint with the saved graph'sType of Change
Testing
lib/build-notes/build-notes.integration.ts(19 checks, real Postgres): hidden files and person access, baseline write refusal, evaluation and its parser, exact-batch builds, edited-notes refusal, a person's edit and its reconciliation, lint the batch adds vs. lint already in the graph, content-gate refusal, refused replace, credential switches, folder restore, flag off, archive and restore with file history, archive/build lock order, stale verdicts and baselines, first-baseline races. Disabling the agent-only access check, the apply guard, the archive lock order, the baseline's evaluation withdrawal and the attach-once rule turns their checks redlib/build-notes/agent-path.integration.ts: the whole loop throughsim_clias Chat sends it (24 calls:workflows create,build-notes create/evaluate/apply/status/changes/rebase,files read/edit), with a JSON transcript intest-results/build-notes-agent.json. It caught two bugs fixed here: the template's own example placeholder blocked every evaluation, and lint from a person's unfinished edit blocked the agent's buildsbun run test(3777 files pass),bun run lint,bun run type-check,bun run check:audits,bun run check:migrations origin/staging, block registry check, drizzle-kit generate (no drift)Checklist
test-auditauthoring gate)