Skip to content

🤖 feat: streamline workflow authoring#3575

Merged
ThomasK33 merged 40 commits into
mainfrom
workflows-p8gn
Jun 17, 2026
Merged

🤖 feat: streamline workflow authoring#3575
ThomasK33 merged 40 commits into
mainfrom
workflows-p8gn

Conversation

@ThomasK33

@ThomasK33 ThomasK33 commented Jun 16, 2026

Copy link
Copy Markdown
Member

Summary

Streamlines durable workflow authoring by introducing static metadata parsing for workflow/action schemas, bundling runtime/action child JavaScript from lintable source files, and adding concise const s = mux.schema; schema aliases across built-in workflows and actions.

Background

Workflow definitions and actions were accumulating repeated handwritten schema objects and mux.schema.* boilerplate. Runtime support code also lived as large inline strings, which made it harder to lint, format, and maintain.

Implementation

  • Adds a static metadata parser that supports JSON-compatible metadata plus mux.schema.* and top-level schema aliases such as const s = mux.schema;, restricted to aliases declared before metadata so static discovery matches runtime evaluation.
  • Extracts workflow runtime stdlib and action child process source into standalone JavaScript files with generated TypeScript bundles.
  • Tracks the generated workflow runtime source bundle so Jest/Windows tests can import it without local codegen first.
  • Moves built-in workflow actions to source files with generated registration content and strengthens git/GitHub action schemas.
  • Updates built-in workflows, the simplify workflow, and workflow-authoring docs to use the concise schema helper style.
  • Extends formatting/lint coverage and generated-bundle drift checks for built-in workflow actions and runtime JS.
  • Fixes workflow metadata stripping for static metadata strings containing };, nullable workflow args, quoted Windows path args, and raw JS tsconfig inclusion.

Validation

  • env MUX_ESLINT_CONCURRENCY=1 make static-check
  • make build-main
  • env TEST_INTEGRATION=1 bun x jest tests/ipc/runtime/executeBash.test.ts --runInBand
  • bun test src/common/utils/jsonSchemaSubset.test.ts
  • bun test src/node/services/workflows/WorkflowActionRunner.test.ts --test-name-pattern "rejects schema aliases declared after action metadata|runs JavaScript actions out of process|describes every built-in action"
  • bun test src/node/services/workflows/WorkflowService.test.ts --test-name-pattern "normalizes quoted Windows paths|runs workflows with metadata strings|normalizes workflow args from static metadata"
  • bun test src/node/services/workflows/builtInWorkflowDefinitions.test.ts --test-name-pattern "built-in workflows"
  • Ran deep-review-workflow and fixed the identified issues.
  • Ran the project simplify workflow successfully via CLI after rebasing on origin/main.

Risks

Moderate: this touches durable workflow discovery, metadata parsing, action execution, generated built-in workflow/action bundles, and validation infrastructure. The parser intentionally supports only static top-level schema aliases declared before metadata, not dynamic aliasing, to keep discovery deterministic and aligned with runtime execution order.


Generated with mux • Model: openai:gpt-5.5 • Thinking: xhigh • Cost: $190.19

Adds opt-in workflow args metadata parsing, sandbox mux schema/util helpers, and built-in git review context/preflight actions.\n\n---\n\n_Generated with `mux` • Model: `openai:gpt-5.5` • Thinking: `xhigh` • Cost: `887858{MUX_COSTS_USD:-unknown}`_\n\n<!-- mux-attribution: model=openai:gpt-5.5 thinking=xhigh costs=26.32 -->
Moves workflow descriptions into metadata, adds generated built-in GitHub action sources, action SDK helpers, and mux patch/parallel helpers.\n\nValidation:\n- bun test src/node/services/workflows/WorkflowDefinitionStore.test.ts src/node/services/workflows/WorkflowService.test.ts src/node/services/workflows/WorkflowActionRunner.test.ts src/cli/workflow.test.ts src/cli/trust.test.ts --test-name-pattern "description|workflow args|parallel agent maps|SDK helpers|git reviewContext|starts a named workflow|workflow|trust"\n- make typecheck\n- make lint\n- make static-check\n\n---\n\n_Generated with `mux` • Model: `openai:gpt-5.5` • Thinking: `xhigh` • Cost: `1091508{MUX_COSTS_USD:-unknown}`_\n\n<!-- mux-attribution: model=openai:gpt-5.5 thinking=xhigh costs=36.17 -->
Preserve workflow metadata while promoting descriptions, track generated workflow action content, and reduce redundant Git/GitHub action work.

---

_Generated with `mux` • Model: `openai:gpt-5.5` • Thinking: `xhigh` • Cost: `$56.31`_

<!-- mux-attribution: model=openai:gpt-5.5 thinking=xhigh costs=56.31 -->
Move built-in Git workflow actions into generated action source files, consolidate GitHub helper calls, avoid an extra label refetch, and reuse the shared plain-object guard for workflow args.
Add static workflow metadata parsing for mux.schema helpers, extracted workflow runtime/action child sources, stronger built-in action schemas, and concise schema alias support across workflows/actions.

---

_Generated with `mux` • Model: `openai:gpt-5.5` • Thinking: `xhigh` • Cost: `$181.71`_

<!-- mux-attribution: model=openai:gpt-5.5 thinking=xhigh costs=181.71 -->
@ThomasK33

Copy link
Copy Markdown
Member Author

@codex review

Ensure Jest/Windows test environments can import the generated workflow runtime source module without requiring local codegen first.

---

_Generated with `mux` • Model: `openai:gpt-5.5` • Thinking: `xhigh` • Cost: `$187.08`_

<!-- mux-attribution: model=openai:gpt-5.5 thinking=xhigh costs=187.08 -->
@ThomasK33

Copy link
Copy Markdown
Member Author

@codex review

Pushed a CI fix for the missing generated workflow runtime source module and re-ran local validation.

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: 2e30d5aacf

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

Comment thread src/node/builtinWorkflowActions/github/ensureIssueLabels.js Outdated
Fix deep-review findings around generated workflow bundle drift checks, workflow JS lint coverage, metadata stripping, schema alias ordering, nullable workflow args, quoted Windows paths, stale JSON schema union tests, and raw JS tsconfig inclusion.

Validation:
- env MUX_ESLINT_CONCURRENCY=1 make static-check
- make build-main
- bun test src/common/utils/jsonSchemaSubset.test.ts
- bun test src/node/services/workflows/WorkflowActionRunner.test.ts --test-name-pattern "rejects schema aliases declared after action metadata|runs JavaScript actions out of process|describes every built-in action"
- bun test src/node/services/workflows/WorkflowService.test.ts --test-name-pattern "normalizes quoted Windows paths|runs workflows with metadata strings|normalizes workflow args from static metadata"

---

_Generated with `mux` • Model: `openai:gpt-5.5` • Thinking: `xhigh` • Cost: `$190.19`_

<!-- mux-attribution: model=openai:gpt-5.5 thinking=xhigh costs=190.19 -->
@ThomasK33

Copy link
Copy Markdown
Member Author

@codex review

Ran deep-review-workflow, fixed the identified issues, and pushed the follow-up changes. Local validation is green, including static-check, build-main, and targeted regression tests.

Export GitHub action reconcile handlers as callable async declarations so static action discovery reports reconciliation support consistently with child execution.

Validation:
- env MUX_ESLINT_CONCURRENCY=1 make static-check
- bun test src/node/services/workflows/WorkflowActionRunner.test.ts --test-name-pattern "describes every built-in workflow action"

---

_Generated with `mux` • Model: `openai:gpt-5.5` • Thinking: `xhigh` • Cost: `$190.19`_

<!-- mux-attribution: model=openai:gpt-5.5 thinking=xhigh costs=190.19 -->
@ThomasK33

Copy link
Copy Markdown
Member Author

@codex review

Addressed the reconcile export finding, replied inline, resolved the thread, and pushed the fix.

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: a04adfb23d

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

Comment thread src/node/builtinWorkflowActions/github/listIssues.js Outdated
Mark read-only GitHub fetch/verify workflow actions as read effects so interrupted or failed attempts remain retryable without reconciliation.

Validation:
- env MUX_ESLINT_CONCURRENCY=1 make static-check
- bun test src/node/services/workflows/WorkflowActionRunner.test.ts --test-name-pattern "describes every built-in workflow action"

---

_Generated with `mux` • Model: `openai:gpt-5.5` • Thinking: `xhigh` • Cost: `$190.19`_

<!-- mux-attribution: model=openai:gpt-5.5 thinking=xhigh costs=190.19 -->
@ThomasK33

Copy link
Copy Markdown
Member Author

@codex review

Addressed the read-only GitHub action effect finding, replied inline, resolved the thread, and pushed the fix.

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: 67b90fdaf6

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

Comment thread src/node/services/workflows/workflowDescription.ts Outdated
Keep legacy // description: workflow headers discoverable while supporting new static metadata declarations, and cover legacy project workflow listing/reading.

Validation:
- env MUX_ESLINT_CONCURRENCY=1 make static-check
- bun test src/node/services/workflows/WorkflowDefinitionStore.test.ts --test-name-pattern "legacy description headers"

---

_Generated with `mux` • Model: `openai:gpt-5.5` • Thinking: `xhigh` • Cost: `$190.19`_

<!-- mux-attribution: model=openai:gpt-5.5 thinking=xhigh costs=190.19 -->
@ThomasK33

Copy link
Copy Markdown
Member Author

@codex review

Addressed the legacy workflow description header compatibility finding, replied inline, resolved the thread, and pushed the fix.

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: 6a945c2ff5

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

Comment thread src/node/workflowRuntime/workflowActionChild.js
Mask regex literals in the workflow action child source before depth-counting export declarations so executable actions with regex literals before metadata/execute load consistently with static describe.

Validation:
- env MUX_ESLINT_CONCURRENCY=1 make static-check
- bun test src/node/services/workflows/WorkflowActionRunner.test.ts --test-name-pattern "executes actions with regex literals before exports"

---

_Generated with `mux` • Model: `openai:gpt-5.5` • Thinking: `xhigh` • Cost: `$190.19`_

<!-- mux-attribution: model=openai:gpt-5.5 thinking=xhigh costs=190.19 -->
@ThomasK33

Copy link
Copy Markdown
Member Author

@codex review

Addressed the action child regex masking finding, replied inline, resolved the thread, and pushed the fix.

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: 8e07a35291

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

Comment thread src/node/services/workflows/WorkflowRunner.ts Outdated
Comment thread src/node/builtinWorkflowActions/git/status.js Outdated
@ThomasK33

Copy link
Copy Markdown
Member Author

@codex review

Pushed a unit-test-only follow-up for the CI failures: the parallelActions fixture now uses the tightened git.status input schema and the sandbox exposure expectation reflects the intentional mux helper global.

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: 2e95945c8a

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

Comment thread src/node/services/workflows/workflowArgs.ts Outdated
@ThomasK33

Copy link
Copy Markdown
Member Author

Addressed the latest Codex findings:

  • PRRT_kwDOPxxmWM6J6510 / metadata binding: preserved export const metadata as a runtime const metadata binding during workflow compilation, while still stripping CommonJS module.exports.metadata assignments that cannot run in the workflow sandbox. Added coverage that a workflow can read metadata.description at runtime even when the description contains }; terminator text.
  • PRRT_kwDOPxxmWM6J652A / git.status ignored files: changed action.git.status so ignored files are only requested when includeIgnored: true, regenerated the built-in action bundle, updated the existing workflow test to request ignored files explicitly, and added a direct regression test for the default vs explicit behavior.

Validation after fixes:

  • bun test src/node/services/workflows/WorkflowService.test.ts src/node/services/workflows/WorkflowActionRunner.test.ts src/node/services/workflows/WorkflowRunner.test.ts
  • MUX_ESLINT_CONCURRENCY=1 make static-check

@codex review

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: ac8292142d

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

Comment thread src/node/services/workflows/workflowArgs.ts
@ThomasK33

Copy link
Copy Markdown
Member Author

@codex review

Please take another look after the CI-only split in 9125646. The previous review threads are resolved; this last push splits the QuickJS-heavy deep-review auto-fix unit filters into separate Bun processes after the Unit job hit the known mprotect/timeout failure in the grouped filter. MUX_ESLINT_CONCURRENCY=4 make static-check-full passes locally.

@ThomasK33

Copy link
Copy Markdown
Member Author

@codex review

Please take another look. I addressed the detached-HEAD expectedBranch feedback in d98f0a3.

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 Codex Review

if (fs.readFileSync(gitignorePath, "utf-8") !== "*\n") fs.writeFileSync(gitignorePath, "*\n", "utf-8");
} catch (error) {
if (!error || error.code !== "ENOENT") throw error;
fs.writeFileSync(gitignorePath, "*\n", "utf-8");

P1 Badge Avoid following symlinks for generated gitignore

When a repository contains .mux/security/.gitignore as a symlink, these reads/writes follow it after only the .mux/security directory was realpath-checked. Running security-scan on such a worktree can overwrite any user-writable symlink target with *\n before artifacts are written, escaping the promised workspace-local .mux/security boundary; use lstat/no-follow semantics or replace the symlink instead.

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

Comment thread src/node/builtinWorkflowActions/github/_shared.js
@ThomasK33

Copy link
Copy Markdown
Member Author

@codex review

Please take another look after b8f84e7. This push only addresses the Unit CI flake by increasing the WorkflowRunner parallelWorkflows sibling-abort test guard from 500ms to 5s after the previous run timed out at the guard on CI. Targeted test and MUX_ESLINT_CONCURRENCY=4 make static-check-full pass locally.

@ThomasK33

Copy link
Copy Markdown
Member Author

@codex review

Please take another look. I addressed the issue conversation body budget feedback in 8bedd32.

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: 8bedd32f92

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

Comment thread src/node/builtinWorkflowActions/github/_shared.js Outdated
Comment thread src/node/builtinWorkflowActions/github/_shared.js Outdated
@ThomasK33

Copy link
Copy Markdown
Member Author

@codex review

Please take another look. I addressed the issue/comment body budget feedback in 067dd74.

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: 067dd74e47

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

Comment thread src/node/builtinWorkflowActions/github/_shared.js Outdated
@ThomasK33

Copy link
Copy Markdown
Member Author

@codex review

Please take another look. I addressed the jq arithmetic feedback in 84de03c.

@chatgpt-codex-connector

Copy link
Copy Markdown

Codex Review: Didn't find any major issues. Bravo.

Reviewed commit: 84de03c78a

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

@ThomasK33 ThomasK33 added this pull request to the merge queue Jun 17, 2026
@github-merge-queue github-merge-queue Bot removed this pull request from the merge queue due to failed status checks Jun 17, 2026
@ThomasK33 ThomasK33 added this pull request to the merge queue Jun 17, 2026
@github-merge-queue github-merge-queue Bot removed this pull request from the merge queue due to failed status checks Jun 17, 2026
@ThomasK33

Copy link
Copy Markdown
Member Author

@codex review

Pushed a Dockerfile fix for the merge-queue-only Smoke / Docker failure: the Docker build context now includes the workflow action/runtime generator scripts required by make verify-docker-runtime-artifacts.

Local validation:

  • make static-check
  • docker build --target builder --progress=plain --build-arg RELEASE_TAG=merge-queue-smoke -t mux-docker-runtime-verify:workflows-p8gn .

@chatgpt-codex-connector

Copy link
Copy Markdown

Codex Review: Didn't find any major issues. Keep it up!

Reviewed commit: 76f78849a3

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

@ThomasK33 ThomasK33 added this pull request to the merge queue Jun 17, 2026
Merged via the queue into main with commit 7e3277c Jun 17, 2026
24 checks passed
@ThomasK33 ThomasK33 deleted the workflows-p8gn branch June 17, 2026 07:06
@mux-bot mux-bot Bot mentioned this pull request Jun 17, 2026
LeonidasZhak pushed a commit to LeonidasZhak/mux that referenced this pull request Jun 20, 2026
## Summary

Long-lived auto-cleanup PR maintained by the **Auto-Cleanup Agent**.
Each pass lands at most one extremely low-risk, behavior-preserving
cleanup drawn from recently merged `main` activity, then advances the
checkpoint below.

## This pass

Replaced an inline terminal-status check in
`WorkflowService.interruptRunOnAbort`
(`src/node/services/workflows/WorkflowService.ts`) with the
`isTerminalWorkflowRunStatus` helper introduced by coder#3587 ("show
workflow-only sidebar activity"). The guard

```ts
if (
  run == null ||
  run.status === "completed" ||
  run.status === "failed" ||
  run.status === "interrupted"
) {
  return;
}
```

now reads `if (run == null || isTerminalWorkflowRunStatus(run.status))`.

- **Behavior-preserving:** `isTerminalWorkflowRunStatus(status)` is
defined as `status === "completed" || status === "failed" || status ===
"interrupted"` — byte-for-byte the same three-status disjunction (same
short-circuit order, same boolean result), so the `run == null || ...`
early-return is unchanged.
- **Why it helps:** `isTerminalWorkflowRunStatus` is already the
canonical terminal-status predicate everywhere else (`taskService.ts`,
`tools/task_await.ts`); this was the only remaining hand-inlined copy in
`WorkflowService`, so the dedup keeps the terminal-status set defined in
exactly one place.
- **Scoped:** one file, one guard; the helper was already exported from
`@/common/types/workflow` and is now added to the existing import in
`WorkflowService.ts` (next to the already-imported
`isActiveWorkflowRunStatus`).

## Validation

- `bun test src/node/services/workflows/WorkflowService.test.ts` — 58
pass / 0 fail.
- `make static-check` — eslint, tsc (both configs), Prettier, and the
generated workflow-runtime bundle drift check all pass. The only failing
step is `fmt-shell-check`, which requires `shfmt` (not installed in this
environment); no shell scripts were touched, so CI (which has `shfmt`)
is unaffected.

<details>
<summary>Prior passes</summary>

- Deduplicated the identical `workspaceId`-only metadata JSON Schema
that three id-targeted host actions repeat in
`src/node/services/workflows/workspaceHostActions.ts` into a
module-level `WORKSPACE_ID_ONLY_INPUT_SCHEMA` constant (the third copy
was introduced by coder#3583 when it added `workspace.unarchive`).
Behavior-preserving: nothing mutates the metadata, and the shared
constant has identical key order/values so the generated stub bundle is
byte-identical (drift check passing).
- Extracted a shared `BlockedBadge` component in
`src/browser/features/Tools/WorkflowDefinitionToolCall.tsx` to
deduplicate the `<WorkflowBadge tone="danger">blocked</WorkflowBadge>`
markup that coder#3578 introduced verbatim in three spots. Also resolved a
trivial rebase conflict from coder#3582 in
`src/node/services/workflows/workflowArgs.ts`.
- Deduplicated the repeated `"Workflow metadata.argsSchema.properties
must be an object"` error string in
`src/node/services/workflows/workflowArgs.ts` (added in coder#3575) into a
module-level `ARGS_SCHEMA_PROPERTIES_ERROR_MESSAGE` constant.
- Deduplicated the four mocked-module specifier strings in
`src/browser/hooks/useModelsFromSettings.test.ts` into shared local
constants so `installUseModelsModuleMocks()` /
`restoreUseModelsModuleMocks()` can't drift (after coder#3574).
- Removed a redundant `toggleWorkflowExpanded` wrapper in
`src/browser/features/Tools/WorkflowRunToolCall.tsx`, left behind by
coder#3571.
- Deduplicated two repeated fallback error strings in
`src/browser/components/AutomationModal/AutomationModal.tsx` (after
coder#3560) into `SAVE_AUTOMATION_ERROR_MESSAGE` /
`REMOVE_AUTOMATION_ERROR_MESSAGE` module-level constants.
- Replaced a duplicated `"wfr_"` literal in
`src/node/services/workflows/WorkflowRunner.ts` with the canonical
`isWorkflowRunTaskId()` predicate from
`src/node/services/tools/taskId.ts` (after coder#3565).
- Removed a duplicated `"chat.jsonl"` literal in
`src/node/services/analytics/etl.ts` by re-exporting `CHAT_FILE_NAME`
from the canonical `src/common/constants/paths.ts` (after coder#3541).
- Extracted a `harvestRecordTime` helper in
`src/node/services/memoryConsolidationService.ts` so
`findNewestHarvestRecord` and `pruneHarvestRecords` derive the
`completedAt ?? startedAt` ordering key from one place (after coder#3558).

</details>

Auto-cleanup checkpoint: a7f047b

---

_Generated with `mux` • Model: `anthropic:claude-opus-4-8` • Thinking:
`xhigh` • Cost: `n/a`_

<!-- mux-attribution: model=anthropic:claude-opus-4-8 thinking=xhigh
costs=n/a -->

---------

Co-authored-by: mux-bot[bot] <264182336+mux-bot[bot]@users.noreply.github.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant