Skip to content

refactor(api): move cron expression parsing into packages/cron - #2788

Merged
simple-agent-manager[bot] merged 6 commits into
mainfrom
sam/stream-c-agent-context-5pmcpb
Nov 17, 2026
Merged

simple-agent-manager[bot] merged 6 commits into
mainfrom
sam/stream-c-agent-context-5pmcpb

Conversation

@simple-agent-manager

@simple-agent-manager simple-agent-manager Bot commented Nov 16, 2026 •

Copy link
Copy Markdown
Contributor

Summary

First slice of the apps/api/src/services split (stream C of the agent-context work, idea 01M7H32EK6S4E31EHWVSJSENR5). Seam map for the whole directory: SAM idea 01M7HXHPQ46H3YK0GC9Q2QHAFF.

apps/api/src/services/cron-utils.ts moves unchanged into a new package, packages/cron (@simple-agent-manager/cron). It is the five-field cron parser behind triggers: validateCronExpression, cronToNextFire, cronToHumanReadable. Its 40-case unit test moves with it. The 10 worker importers and 6 worker tests now import the package, and no re-export is left at the old path: a shim with no importers would be dead code (#2681 kept shims only to avoid editing hundreds of importers).

Package template from PR #2681: dist/ resolution, a single public entry point, an AGENTS.md, boundaryRules lint coverage (automatic for packages/**), and the build order in CLAUDE.md, rule 08 and the local-development guide. The package depends only on @simple-agent-manager/shared.

Effect on rule loading. On first access, the moved file loaded 271.5 KB from 36 path-scoped rules in apps/api. In packages/cron it loads 12.7 KB from 1 rule. Each of the 36 is decided in the table under Validation. Measured with parseRuleFile/compilePattern from scripts/quality/agent-instructions.ts. pnpm quality:agent-context-budget --check passes, and the indexes were regenerated with --write after rebasing onto #2790.

Why cron and not text-to-speech. TTS (services/tts*.ts) was the first pick and was tried. It needs @mastra/core and workers-ai-provider. For a new importer, pnpm resolved their peer dependencies differently (zod@4.6.7 against the worker's locked 4.5.4), which creates a second instance of each library in the worker bundle. Fixing that means pinning peer versions inside the package or turning the LLM call into a port, so it is not a pure move. Recorded on the seam map.

Validation

  • pnpm lint (via pnpm check:fast, passed)
  • pnpm typecheck (API typecheck passed)
  • pnpm test (see notes)
  • Additional validation run (if applicable)
  • N/A: no sweep/cron/alarm candidate selection changed (the cron sweep is untouched; only its import path changed)

Pure-move evidence:

  • cron-utils.ts is byte-identical to main (diff <(git show bfe2b96e7:apps/api/src/services/cron-utils.ts) packages/cron/src/cron-utils.ts prints nothing; Git reports a 100% rename).
  • Every other source diff is an import specifier, plus the import re-sorting ESLint applied.
  • Worker bundle (wrangler deploy --dry-run): 32,560,747 bytes before, 32,560,844 after. The cron module's code in the bundle is identical with whitespace removed. The +97 bytes are path comments and the two per-module polyfill init calls that wrangler adds to every bundled module. The source maps differ only in apps/api/src/services/cron-utils.ts becoming packages/cron/src/{index,cron-utils}.ts.
  • Tests: 40 cron cases moved (40 pass in the package). The 5 repointed worker unit test files (41 cases) and tests/workers/cron-trigger-sweep.test.ts (19 cases) pass. Test case count is unchanged.
  • No wrangler.toml, D1 or Durable Object migration, route, binding or environment change.

Rule-by-rule scoping decision

On main 30ae952ae, the first read of apps/api/src/services/cron-utils.ts loaded 271.5 KB from 36 path-scoped rules. After this PR, packages/cron/src/cron-utils.ts loads 12.7 KB from 1 rule (73, which #2790 scoped to every .ts, .tsx, .go and .sql file). Each of the 36 rules is a decision, not a default. The package has no I/O, no D1, DO, KV or fetch, no Env, no routes, no auth, no settings and no runtime state. Its inputs are strings and a Date; its outputs are a validation result, an ISO string or a description. The code that does the I/O around it stays in apps/api, where every one of these rules still loads: request validation in schemas/triggers.ts, D1 writes in services/trigger-create.ts, the sweep in scheduled/cron-triggers.ts. The launch rules (constitution and no hardcoded values, 81 work bounds, quality gates) still apply to packages/cron.

Rule Decision for packages/cron Why
06 API patterns not added Hono routes, middleware and Workers bindings; the package has none.
24 no duplicate implementations not added Its point is one canonical implementation. Moving the parser keeps it the only one, and the rule still loads for every caller in apps/api.
26 project chat first not added UI and navigation; no surface here.
27 VM agent staging refresh not added VM agent binaries.
31 migration safety not added No D1 or DO migrations or SQL.
32 CF API debugging not added No Cloudflare resources.
34 VM agent callback auth not added No routes or auth.
40 sentinel rows excluded from counts not added No D1 counts.
43 long-running MCP tools not added No MCP tools; routes/mcp/trigger-*.ts stay in apps/api.
44 dual-write migrations not added No storage.
45 DO concurrency mutex not added No Durable Objects and no await; every function is synchronous.
47 control-loop I/O budget not added The control loop is the cron sweep in apps/api/src/scheduled/cron-triggers.ts, which keeps this rule. The package's only loop (cronToNextFire) does no I/O and is bounded at 2 × 525,600 iterations; launch rule 81 (work bounds) covers that and still applies.
49 capture prerequisites before async completion not added No async code.
50 list-read row fault isolation not added No row reads.
51 runtime boundary validation not added Its subject is turning unknown external JSON, rows and fetch responses into typed values. The package receives typed strings. The untrusted request body is parsed by the valibot schemas in apps/api/src/schemas/triggers.ts (cronExpression, cronTimezone), which keep this rule. validateCronExpression errors echo only the caller's own expression back, never another tenant's data or a secret.
51 server-side node-class gates not added No placement or identity.
52 model catalog lifecycle not added No models.
53 scheduled-handler isolation and liveness signals not added The scheduled handler and its step isolation live in apps/api (scheduled/cron-triggers.ts, index.ts), which keep this rule. The parser computes no idleness or staleness.
55 runaway-cost emergency ops not added No spend.
57 write-only cross-boundary state not added No state.
58 terminal verdicts not added No verdicts.
61 guards cover every runtime not added Runtime-specific guards for VM and container; the parser is runtime-independent.
61 per-cycle budget counters not added No counters.
63 widening a table deletes an auth check not added No schema.
65 capped selection must rank and disclose not added No selections or caps.
66 ownership handoff not added No ownership.
67 shared predicates that trigger actions not added The parser's predicates decide whether a minute matches an expression; the actions (firing a trigger) are in apps/api, which keeps this rule.
68 event-scoped filter predicates not added No event filters.
69 aggregate capacity at final reservation not added No capacity.
69 emergency config coverage not added No configuration. The minimum interval is passed in by the caller (trigger-create.ts reads CRON_MIN_INTERVAL_MINUTES, default DEFAULT_CRON_MIN_INTERVAL_MINUTES from shared).
70 flag flips verify deployed value not added No flags or Worker vars.
71 tightening a column not added No schema.
72 error categories match the recovery action not added Covers provider and HTTP errors. validateCronExpression returns a result that trigger-create.ts turns into a 400 (errors.badRequest) in apps/api.
73 optional fields must not overwrite on absence loads (scope from #2790) Applies to every .ts file. The package has no update or merge helper; cronToNextFire's optional after defaults to now and overwrites nothing.
75 external API check-then-act not added No external API.
77 library extension points not added No library extension points.

Staging Verification (REQUIRED for all code changes — merge-blocking)

  • Staging deployment green
  • Live app verified via Playwright (verified through the live API with a token-login session instead; no UI change)
  • Existing workflows confirmed working
  • New feature/fix verified on staging
  • Infrastructure verification completed — N/A: no infra changes (no cloud-init, VM agent, DNS, TLS or deploy script change)
  • Mobile and desktop verification notes added for UI changes — N/A: no UI change

Staging Verification Evidence

staging2 (sammy2.party), head 99bbfa0cb, 2026-11-17 ~00:45Z. Deploy run 43988624033 succeeded: queue, lease, Validate Configuration, Deploy to Cloudflare and smoke-tests all passed. Signed in by workload identity. GET /health returned 200. As staging2-agent-admin, the trigger list returned cronHumanReadable: "Every 15 minutes" for two existing */15 * * * * triggers. That value is computed by cronToHumanReadable from @simple-agent-manager/cron in the deployed Worker (services/trigger-read.ts).

The write path (validateCronExpression, cronToNextFire on create and update) cannot be exercised there: trigger create and edit refuse agent sign-in sessions by design (assertNotAgentSignInSession in routes/triggers/crud.ts: 403 Agent sign-in sessions cannot create credentials or grant access). staging2's only other session token is the workflow-only SMOKE_TEST_TOKEN. No test resources were created, and the lease was released (run 43990835091).

Primary staging (sammy.party), head 99bbfa0cb, 2026-11-17 04:39-05:33Z. Deploy run 44018692314 succeeded: queue, lease, Validate Configuration, Deploy to Cloudflare and smoke-tests all passed. The write-path check (create, list, update, invalid expression, every-minute, delete) did not run. The normal-session test token is only usable through SAM exec_with_secrets; in a plain shell it is a placeholder, and token-login returned 401 for that reason. SAM's MCP tools were disconnected from the session for the whole lease, so the lease was released unused (run 44024945939) and the branch is queued again. (Superseded by the run below.)

Primary staging (sammy.party), head 5ba2eb30e (rebased on main 1ed27436c), 2026-11-17 19:52Z. Write path verified. Deploy run 44158298531: queue, lease, Validate Configuration and Deploy to Cloudflare passed; the staging deployment record shows 5ba2eb30e. Signed in with the primary test user's token-login session (through SAM exec_with_secrets), then in project 01KWHD8XS7MQ7R6KWXJYRHDVH4:

Step Result
Create cron trigger 0 9 1 1 * UTC 201, nextFireAt 2027-01-01T09:00:00.000Z, cronHumanReadable "At 9:00 AM on day 1 of the month in Jan"
List triggers 200, same description
PATCH to 30 6 * * 1 200, nextFireAt 2026-11-23T06:30:00.000Z (next Monday), "At 6:30 AM on Monday"
PATCH to * * 400 "Invalid cron expression: Expected 5 fields (minute hour dayOfMonth month dayOfWeek), got 2"
PATCH to * * * * * 400 "Schedule fires too frequently (every ~1 minutes). Minimum interval is 15 minutes."
Create with 61 * * * * 400 "Invalid value in minute: 61 (valid: 0-59)"
Delete the test trigger 200 (nothing left behind)

validateCronExpression, cronToNextFire and cronToHumanReadable all ran from @simple-agent-manager/cron in the deployed Worker.

Changes since the last review round (takeover by task 01M7N5Q1YTKVCRNMKDJKN9G760): rebased twice onto main. The .sonarcloud.properties conflict was resolved by keeping both new exclusions. Commit 5ba2eb30e trims this PR's launch-context addition to 68 bytes (shorter CLAUDE.md line; cron dropped from the rule 08 diagram, where it implied the worker module packages depend on it; both build-order sentences still list it), because Code Quality Checks failed at 210,107 bytes against the 210,000 ceiling after the rebase. Docs only, no code change.

UI Compliance Checklist (Required for UI changes)

N/A: no UI change.

UI Screenshot Evidence

N/A: no UI change.

End-to-End Verification (Required for multi-component changes)

  • Data flow traced from user input to final outcome with code path citations
  • Capability test exercises the complete happy path across system boundaries
  • All spec/doc assumptions about existing behavior verified against code
  • If any gap exists between automated test coverage and full E2E, manual verification steps documented below

Data Flow Trace

Trigger create (routes/triggers/crud.ts, MCP routes/mcp/trigger-create-tool.ts) → services/trigger-create.ts (validateCronExpression, cronToNextFire) → D1 triggers.next_fire_at. Read paths: services/trigger-read.ts, routes/mcp/trigger-tool-shared.ts and operation-ports.ts (cronToHumanReadable). Cron sweep: scheduled/cron-triggers.ts (cronToNextFire). All of these now import @simple-agent-manager/cron, which the worker bundles from packages/cron/dist.

Untested Gaps

N/A: behaviour is unchanged and covered by the moved unit tests plus the worker route, sweep and workers-pool tests; staging covers the deployed bundle.

Post-Mortem (Required for bug fix PRs)

N/A: not a bug fix.

Specialist Review Evidence (Required for agent-authored PRs)

  • All local reviewers completed and findings addressed before merge
  • If any reviewer did NOT complete: needs-human-review label added and merge deferred to human (N/A: all completed; the first run stopped at a usage limit and the same reviewers were resumed)
Reviewer Status Outcome
task-completion-validator ADDRESSED No CRITICAL/HIGH. MEDIUM: scripts/quality/ast-checks.ts scanned the file before the move, so it now scans packages/cron/src (fece83e). LOW: task file ticked, with evidence and the rule 51 decision recorded (fece83e).
architecture-reviewer ADDRESSED No CRITICAL/HIGH; boundary judged sound (shared -> cron -> api, coherent subject, wiring matches scheduler-core). MEDIUM: apps/web/src/pages/automation/editor/cron.ts has an older, partial parser of its own. Moving the web editor onto the package changes web behaviour, so it is recorded as a follow-up on the seam map idea, not done in a pure move. MEDIUM: the dated blog post keeps its historical path (see Documentation & Specs). LOW: AGENTS.md wording fixed (fece83e).
cloudflare-specialist PASS Turbo ^build and the api^... filters build the package with no named step; Miniflare and vitest aliases need no entry; every sibling-package list is covered. INFO (ast-checks) addressed in fece83e.

CodeRabbit Review Evidence (Required for agent-authored PRs)

  • CodeRabbit requested when the PR was marked ready for review
  • Waited about 15 minutes (or until a skip, rate-limit or quota reply)
  • Either CodeRabbit reviewed and no CodeRabbit feedback is unresolved, or it did not review and the observed outcome is recorded below

CodeRabbit Notes

Requested 14:39Z with the coderabbit-review label when the PR was marked ready; the label workflow ran and CodeRabbit replied "Review triggered". It reviewed 30ae952ae..fece83e2a and approved, with "No actionable comments were generated" and merge risk "Minimal". Its summary calls the plain-text package diagram in .claude/rules/08-architecture.md (which predates this PR) a non-blocking format issue. It opened no thread, and converting the diagram is outside a pure move.

After the takeover rebases and the launch-budget trim (5ba2eb30e, pushed 18:50-19:13Z), CodeRabbit posted no incremental review within the wait; its approval stands and no CodeRabbit thread is unresolved.

CI note: on run 43887945119 (fece83e2a), Test web (2/2) failed once on SecretRequestCard.test.tsx (waitFor timed out after its 1 s default; the PR touches no web code). It passed locally and on rerun, so all checks are green. The flake is tracked as SAM idea 01M7JF5EBFQCGS7H7QN089YMFH.

Exceptions (If any)

  • Scope: None
  • Rationale: N/A
  • Expiration: N/A

Agent Preflight (Required)

  • Preflight completed before code changes

Classification

  • external-api-change
  • cross-component-change
  • business-logic-change
  • public-surface-change
  • docs-sync-change
  • security-sensitive-change
  • ui-change
  • infra-change

External References

N/A: no external API; internal reorganisation following PR #2681 and tasks/archive/2026-11-12-worker-modularization.md ("Package template").

Codebase Impact Analysis

  • packages/cron/ (new): src/cron-utils.ts (moved from apps/api/src/services/cron-utils.ts), src/index.ts, tests/unit/cron-utils.test.ts (moved from apps/api/tests/unit/services/).
  • apps/api/src: import path only in operation-ports.ts, routes/tasks/crud.ts, routes/triggers/crud.ts, routes/mcp/trigger-create-tool.ts, routes/mcp/trigger-tool-shared.ts, routes/mcp/trigger-tools.ts, scheduled/cron-triggers.ts, services/trigger-create.ts, services/trigger-read.ts, services/trigger-status.ts.
  • apps/api/tests: import or vi.mock path only in six test files.
  • Wiring: apps/api/package.json, pnpm-lock.yaml, .github/workflows/ci.yml and e2e-smoke.yml path filters, the quality:runtime-boundary-semantics scope in package.json, the scripts/quality/ast-checks.ts scan scope.
  • Open PRs Insights H: Admin Health & cost #2784 and Insights slice R: run receipt #2786 edit apps/api/src/operation-ports.ts on lines away from the moved import; Git merges them cleanly.

Documentation & Specs

CLAUDE.md (structure, build order), .claude/rules/08-architecture.md (package graph, build order), apps/www/src/content/docs/docs/guides/local-development.md (build order), packages/cron/AGENTS.md (new), regenerated rule indexes. No spec changes. Blog post sams-journal-two-features-one-day.md keeps its historical path.

Constitution & Risk Check

Principle X (simplicity): a leaf package with one dependency, no ports and no shims. Principle XI (no hardcoded values): unchanged code; the minimum interval still comes from DEFAULT_CRON_MIN_INTERVAL_MINUTES in shared. Risk: the deployed bundle must contain identical cron logic. Checked by bundle comparison above and by the staging trigger check.

🤖 Generated with Claude Code

Summary by CodeRabbit

  • Refactor
    • Cron scheduling utilities are now provided through a dedicated package. Scheduling and trigger behavior remains unchanged.
  • Chores
    • Updated automated checks and build workflows to include the cron package.

@coderabbitai

coderabbitai Bot commented Nov 16, 2026 •

Copy link
Copy Markdown

Explain Change →

Important

Review skipped

Bot user detected.

To trigger a single review, invoke the @coderabbitai review command.

Run configuration

You can disable this status message by setting the reviews.review_status to false in the CodeRabbit configuration file.

Use the checkbox below for a quick retry:

  • Trigger review

No actionable comments were generated in the recent review.

Walkthrough

The cron utilities are exposed through a new workspace package. API modules and tests now import them from that package. CI filters, quality checks, and repository documentation include the package.

Changes: Cron Package Extraction

Layer / File(s) Summary
Package entry point and tooling
packages/cron/*, tasks/active/*
The package defines its metadata, build and test configuration, and public exports for cronToHumanReadable, cronToNextFire, and validateCronExpression. Package guidance, utility tests, and an extraction task document are added.
API and test imports
apps/api/package.json, apps/api/src/*, apps/api/tests/*
The API adds the workspace dependency. API code and tests import cron utilities from @simple-agent-manager/cron instead of the local cron utility module.
Repository checks and build references
.claude/rules/*, .github/workflows/*, CLAUDE.md, apps/www/src/content/docs/*, package.json, scripts/quality/*
CI path filters and quality checks include the cron package. Architecture and build-order documentation now list the package.

Estimated code review effort: 2 (Simple) | ~12 minutes

Change: Refactor

Suggested reviewers: raphaeltm

Merge Risk: Minimal · previous review fece8

The extraction preserves the cron utilities’ public interface and wires their package into supported build and test paths. No material merge-blocking defect is established; the remaining diagram-format issue is non-blocking.

Pre-merge checks: Passed 4

Check name Status Explanation
Title check Passed The title "refactor(api): move cron expression parsing into packages/cron" matches the main change. The PR moves cron-utils.ts (validateCronExpression, cronToNextFire, cronToHumanReadable) and its uni…
Description check Passed The description follows the repository template closely. It has a Summary that explains the problem and intended change, and it includes validation evidence (lint, typecheck, tests, bundle comparison)…
Linked Issues check Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check Passed Check skipped because no linked issues were found for this pull request.
Full details: Title check

Explanation

The title "refactor(api): move cron expression parsing into packages/cron" matches the main change. The PR moves cron-utils.ts (validateCronExpression, cronToNextFire, cronToHumanReadable) and its unit tests from apps/api into the new packages/cron package, and repoints importers. The title is concise, specific, and follows a conventional-commit style.

Full details: Description check

Explanation

The description follows the repository template closely. It has a Summary that explains the problem and intended change, and it includes validation evidence (lint, typecheck, tests, bundle comparison). It fills in the Staging Verification, UI, E2E, Post-Mortem, Specialist Review, CodeRabbit, and Agent Preflight sections, and marks N/A where appropriate. Several staging checkboxes are unchecked and marked Pending, and the CodeRabbit evidence is incomplete. These gaps are expected for an open PR that has not yet been staged or reviewed, and the required structure is otherwise present.

Finishing Touches

Generate unit tests (beta)

  • Commit to this branch
  • Create a new PR
  • Autofix · Keep fixing CodeRabbit findings and required CI, and resolving merge conflicts

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

Share

A rabbit checks the cron by moonlit light
Three helpers hop into a package neat
The API calls them from their home
Tests follow close along the path
CI watches as the changes land
Then I nibble clover, pleased and calm

Recent review info

Run configuration

Commits

Reviewing files that changed from the base of the PR and between 30ae952 and fece83e.

Files ignored due to path filters: 1

  • pnpm-lock.yaml is excluded by !**/pnpm-lock.yaml
Files selected for processing: 32

  • .claude/rules/08-architecture.md
  • .github/workflows/ci.yml
  • .github/workflows/e2e-smoke.yml
  • CLAUDE.md
  • apps/api/package.json
  • apps/api/src/operation-ports.ts
  • apps/api/src/routes/mcp/trigger-create-tool.ts
  • apps/api/src/routes/mcp/trigger-tool-shared.ts
  • apps/api/src/routes/mcp/trigger-tools.ts
  • apps/api/src/routes/tasks/crud.ts
  • apps/api/src/routes/triggers/crud.ts
  • apps/api/src/scheduled/cron-triggers.ts
  • apps/api/src/services/trigger-create.ts
  • apps/api/src/services/trigger-read.ts
  • apps/api/src/services/trigger-status.ts
  • apps/api/tests/unit/routes/mcp-list-triggers.test.ts
  • apps/api/tests/unit/routes/triggers.test.ts
  • apps/api/tests/unit/scheduled/capacity-pool-continuation-cron-config.test.ts
  • apps/api/tests/unit/services/cron-sweep.test.ts
  • apps/api/tests/unit/services/trigger-status.test.ts
  • apps/api/tests/workers/cron-trigger-sweep.test.ts
  • apps/www/src/content/docs/docs/guides/local-development.md
  • package.json
  • packages/cron/AGENTS.md
  • packages/cron/package.json
  • packages/cron/src/cron-utils.ts
  • packages/cron/src/index.ts
  • packages/cron/tests/unit/cron-utils.test.ts
  • packages/cron/tsconfig.json
  • packages/cron/vitest.config.ts
  • scripts/quality/ast-checks.ts
  • tasks/active/2026-11-16-extract-cron-package.md

Included review availability: This review used your included allowance. Your plan provides up to 1 included review per hour; 0 remain after this review.

@codspeed

codspeed Bot commented Nov 16, 2026 •

Copy link
Copy Markdown
Contributor

Merging this PR will not alter performance

✅ 5 untouched benchmarks
⏩ 1 skipped benchmark1


Comparing sam/stream-c-agent-context-5pmcpb (5ba2eb3) with main (f5a116b)2

Open in CodSpeed

Footnotes

  1. 1 benchmark was skipped, so the baseline result was used instead. If it was deleted from the codebase, click here and archive it to remove it from the performance reports. ↩

  2. No successful run was found on main (1ed2743) during the generation of this report, so f5a116b was used instead as the comparison base. There might be some changes unrelated to this pull request in this report. ↩

@simple-agent-manager
simple-agent-manager Bot force-pushed the sam/stream-c-agent-context-5pmcpb branch from 06d1b2c to 97408f6 Compare November 16, 2026 14:30
@simple-agent-manager
simple-agent-manager Bot marked this pull request as ready for review November 16, 2026 14:38
@simple-agent-manager simple-agent-manager Bot added the coderabbit-review Trigger CodeRabbit review for opt-in PRs label Nov 16, 2026
@raphaeltm

Copy link
Copy Markdown
Owner

@coderabbitai review

@coderabbitai

coderabbitai Bot commented Nov 16, 2026 •

Copy link
Copy Markdown
Action performed

Review finished.

Note: CodeRabbit is an incremental review system and does not re-review already reviewed commits. This command is applicable only when automatic reviews are paused.

@simple-agent-manager
simple-agent-manager Bot force-pushed the sam/stream-c-agent-context-5pmcpb branch from fece83e to 78c47b2 Compare November 16, 2026 17:06
@github-actions
github-actions Bot requested a deployment to staging2 November 16, 2026 18:09 Abandoned
@github-actions
github-actions Bot requested a deployment to staging2 November 16, 2026 19:31 Abandoned
@github-actions
github-actions Bot requested a deployment to staging2 November 17, 2026 00:37 Abandoned
@github-actions
github-actions Bot requested a deployment to staging November 17, 2026 00:51 Abandoned
@github-actions
github-actions Bot requested a deployment to staging2 November 17, 2026 00:56 Abandoned
@github-actions
github-actions Bot requested a deployment to staging November 17, 2026 04:45 Abandoned
@github-actions
github-actions Bot requested a deployment to staging November 17, 2026 05:39 Abandoned
@simple-agent-manager
simple-agent-manager Bot force-pushed the sam/stream-c-agent-context-5pmcpb branch from 99bbfa0 to 3f9966a Compare November 17, 2026 10:31
@github-actions
github-actions Bot requested a deployment to staging November 17, 2026 10:36 Abandoned
@github-actions
github-actions Bot requested a deployment to staging November 17, 2026 15:28 Abandoned
@simple-agent-manager
simple-agent-manager Bot force-pushed the sam/stream-c-agent-context-5pmcpb branch from 3f9966a to 682c07e Compare November 17, 2026 16:38
raphaeltm and others added 6 commits November 17, 2026 19:13
First slice of the apps/api/src/services split (seam map: SAM idea
01M7HXHPQ46H3YK0GC9Q2QHAFF). services/cron-utils.ts moves unchanged to
packages/cron; its unit test moves with it. The ten worker importers and six
worker tests import @simple-agent-manager/cron instead of the old path.
No re-export is left behind.

Wiring: apps/api dependency, CI path filters, runtime-boundary scope, build
order in CLAUDE.md, rule 08 and the local-development guide, a package
AGENTS.md, regenerated rule indexes.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Review follow-ups for the cron package move: the API AST checks scanned
cron-utils.ts before the move, so they now scan packages/cron/src as they do
the other worker packages. AGENTS.md says who consumes the package, and the
task file records the evidence and the rule 51 decision.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
SonarCloud counts packages/cron/tests/unit/cron-utils.test.ts as new code
after the move, and its repeated test blocks (102 lines, unchanged from the old
path) failed the new-code duplication gate. Tests are excluded from CPD by
policy (sonar-project.properties); automatic analysis needs the exact path.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…udget

Claude Code launch context reached 210,107 bytes against the 210,000 ceiling
after rebasing onto main. Shorten the CLAUDE.md structure line and drop cron
from the rule 08 diagram, where it implied the worker module packages depend
on it; both build-order sentences still list cron. Net launch addition is now
68 bytes.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@sonarqubecloud

Copy link
Copy Markdown

This branch had an error being deployed

2 abandoned (1 outdated) deployments
staging — 5ba2eb30 Deployed Nov 17, 2026 by github-actions[bot]
staging2 — 99bbfa0c Deployed Nov 17, 2026 by github-actions[bot]
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

coderabbit-review Trigger CodeRabbit review for opt-in PRs

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant