Skip to content

feat: surface cron windows in webapp, cli, sdk - #4572

Merged
carderne merged 12 commits into
mainfrom
feat/cron-windows-surface
Aug 14, 2026
Merged

feat: surface cron windows in webapp, cli, sdk#4572
carderne merged 12 commits into
mainfrom
feat/cron-windows-surface

Conversation

@carderne

@carderne carderne commented Aug 11, 2026

Copy link
Copy Markdown
Collaborator

Summary

Adds execution-window product surfaces for both declarative and imperative schedules.

  • Declarative schedules can set window through schedules.task(), with support for whole-minute, hour, and percentage values.
  • Imperative schedules can create, update, clear, and inspect windows through the API and dashboard.
  • Schedule API responses preserve nextRun as the nominal CRON time and expose nextRunEffectiveAt as the stable assigned time.
  • The dashboard displays configured windows alongside assigned upcoming-run times.
  • Deploy output summarizes declarative schedules and suggests adding a wider window when the default 60-second placement range is used.

Design

Window validation remains authoritative on the server and ensures each window is compatible with the schedule cadence. Omitting a window uses the default 60-second range, while explicit zero-duration windows remain supported.

Deployment summaries are derived from the deployment's stored task metadata, so they reflect the declarations associated with that deployment.

@changeset-bot

changeset-bot Bot commented Aug 11, 2026

Copy link
Copy Markdown

🦋 Changeset detected

Latest commit: 6a73a1a

The changes in this PR will be included in the next version bump.

This PR includes changesets to release 27 packages
Name Type
@trigger.dev/core Patch
@trigger.dev/sdk Patch
@trigger.dev/build Patch
trigger.dev Patch
@trigger.dev/python Patch
@trigger.dev/redis-worker Patch
@trigger.dev/schema-to-json Patch
@internal/cache Patch
@internal/clickhouse Patch
@internal/llm-model-catalog Patch
@internal/metrics-pipeline Patch
@trigger.dev/rbac Patch
@internal/redis Patch
@internal/replication Patch
@internal/run-engine Patch
@internal/run-store Patch
@internal/schedule-engine Patch
@trigger.dev/sso Patch
@internal/testcontainers Patch
@internal/tracing Patch
@internal/tsql Patch
@internal/dashboard-agent Patch
@internal/sdk-compat-tests Patch
@trigger.dev/react-hooks Patch
@trigger.dev/rsc Patch
@trigger.dev/database Patch
@trigger.dev/otlp-importer Patch

Not sure what this means? Click here to learn what changesets are.

Click here if you're a maintainer who wants to add another changeset to this PR

@coderabbitai

coderabbitai Bot commented Aug 11, 2026

Copy link
Copy Markdown
Contributor

Review Change Stack

Note

Reviews paused

It looks like this branch is under active development. To avoid overwhelming you with review comments due to an influx of new commits, CodeRabbit has automatically paused this review. You can configure this behavior by changing the reviews.auto_review.auto_pause_after_reviewed_commits setting.

Use the following commands to manage reviews:

  • @coderabbitai resume to resume automatic reviews.
  • @coderabbitai review to trigger a single review.

Use the checkboxes below for quick actions:

  • ▶️ Resume reviews
  • 🔍 Trigger review

No actionable comments were generated in the recent review. 🎉

ℹ️ Recent review info
⚙️ Run configuration

Configuration used: Repository UI

Review profile: CHILL

Plan: Pro Plus

Run ID: ce12cdec-70a2-4b4c-8b4f-5ebdce4870d5

📥 Commits

Reviewing files that changed from the base of the PR and between b6fbf74 and e3ee994.

📒 Files selected for processing (1)
  • apps/webapp/app/routes/api.v1.deployments.$deploymentId.ts
🚧 Files skipped from review as they are similar to previous changes (1)
  • apps/webapp/app/routes/api.v1.deployments.$deploymentId.ts
📜 Recent review details
⏰ Context from checks skipped due to timeout. (17)
  • GitHub Check: webapp / 🧪 Unit Tests: Webapp (7, 12)
  • GitHub Check: webapp / 🧪 Unit Tests: Webapp (9, 12)
  • GitHub Check: webapp / 🧪 Unit Tests: Webapp (4, 12)
  • GitHub Check: webapp / 🧪 Unit Tests: Webapp (5, 12)
  • GitHub Check: sdk-compat / Node.js 24.18 (warp-ubuntu-latest-x64-4x)
  • GitHub Check: sdk-compat / Node.js 26.4 (warp-ubuntu-latest-x64-4x)
  • GitHub Check: typecheck / typecheck
  • GitHub Check: sdk-compat / Bun Runtime
  • GitHub Check: packages / 🧪 Unit Tests: Packages (2, 3)
  • GitHub Check: runops-guard / runops-guard
  • GitHub Check: internal / 🧪 Unit Tests: Internal
  • GitHub Check: packages / 🧪 Unit Tests: Packages (1, 3)
  • GitHub Check: e2e-webapp / 🧪 E2E Tests: Webapp
  • GitHub Check: code-quality / code-quality
  • GitHub Check: 🛡️ E2E Auth Tests (full)
  • GitHub Check: Analyze (javascript-typescript)
  • GitHub Check: Analyze (actions)

Walkthrough

The change adds optional duration or percentage windows to declarative schedules. Scheduling utilities calculate nominal CRON times and effective assigned times. Presenters and APIs return both timestamps and window metadata. Dashboard views and forms display and edit windows. Deployment responses and CLI output include declarative schedule details. Tests cover SDK serialization, timing calculations, API lifecycle behavior, and deployment formatting.

🚥 Pre-merge checks | ✅ 3 | ❌ 2

❌ Failed checks (2 warnings)

Check name Status Explanation Resolution
Docstring Coverage ⚠️ Warning Docstring coverage is 11.11% which is insufficient. The required threshold is 80.00%. Write docstrings for the functions missing them to satisfy the coverage threshold.
Description check ⚠️ Warning The description explains the feature and design, but it omits the required issue reference, checklist, testing steps, changelog, and screenshots sections. Add the required template sections, including the issue reference, completed checklist, testing steps, changelog entry, and screenshots or an explicit reason they are unavailable.
✅ Passed checks (3 passed)
Check name Status Explanation
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.
Title check ✅ Passed The title clearly summarizes the main change: exposing CRON execution windows across the webapp, CLI, and SDK.
✨ Finishing Touches 💡 1
📝 Generate docstrings 💡
  • Create stacked PR
  • Commit on current branch
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch feat/cron-windows-surface

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

Comment @coderabbitai help to get the list of available commands.

github-advanced-security[bot]

This comment was marked as resolved.

coderabbitai[bot]

This comment was marked as resolved.

@carderne
carderne changed the base branch from main to feat/cron-windows August 11, 2026 19:34
@carderne
carderne force-pushed the feat/cron-windows-surface branch from 2ba481a to eb8c3af Compare August 11, 2026 19:40
@github-actions

github-actions Bot commented Aug 11, 2026

Copy link
Copy Markdown
Contributor

Observability map

As of 6a73a1a.

Nothing in this pull request moves the report any more. The findings an earlier push reported are gone.

The score and findings here are report-only and never gate the merge. Separately, a required test suite keeps this tool's symbol and route lists in sync with the code they name, and can fail a pull request that renames or removes a symbol they reference, or that adds the first route with a segment they anticipate. Each failure names the list to edit. The rules and their reasons: internal-packages/observability-map/README.md.

@pkg-pr-new

pkg-pr-new Bot commented Aug 11, 2026

Copy link
Copy Markdown

Open in StackBlitz

@trigger.dev/build

npm i https://pkg.pr.new/@trigger.dev/build@1ecb593

trigger.dev

npm i https://pkg.pr.new/trigger.dev@1ecb593

@trigger.dev/core

npm i https://pkg.pr.new/@trigger.dev/core@1ecb593

@trigger.dev/python

npm i https://pkg.pr.new/@trigger.dev/python@1ecb593

@trigger.dev/react-hooks

npm i https://pkg.pr.new/@trigger.dev/react-hooks@1ecb593

@trigger.dev/redis-worker

npm i https://pkg.pr.new/@trigger.dev/redis-worker@1ecb593

@trigger.dev/rsc

npm i https://pkg.pr.new/@trigger.dev/rsc@1ecb593

@trigger.dev/schema-to-json

npm i https://pkg.pr.new/@trigger.dev/schema-to-json@1ecb593

@trigger.dev/sdk

npm i https://pkg.pr.new/@trigger.dev/sdk@1ecb593

commit: 1ecb593

Base automatically changed from feat/cron-windows to main August 12, 2026 11:24
@carderne
carderne force-pushed the feat/cron-windows-surface branch from eb8c3af to 9ecb63f Compare August 12, 2026 11:31
@coderabbitai

coderabbitai Bot commented Aug 12, 2026

Copy link
Copy Markdown
Contributor

Note

GitHub couldn't provide a complete incremental comparison for this pull request, so CodeRabbit is performing a full review instead. This review may take a little longer.

coderabbitai[bot]

This comment was marked as resolved.

@carderne
carderne force-pushed the feat/cron-windows-surface branch 2 times, most recently from 6bd63af to 75080c1 Compare August 13, 2026 21:49
@carderne
carderne marked this pull request as ready for review August 13, 2026 21:49
devin-ai-integration[bot]

This comment was marked as resolved.

devin-ai-integration[bot]

This comment was marked as resolved.

devin-ai-integration[bot]

This comment was marked as resolved.

devin-ai-integration[bot]

This comment was marked as resolved.

@carderne
carderne force-pushed the feat/cron-windows-surface branch from 206ef69 to 1ecb593 Compare August 13, 2026 22:43
devin-ai-integration[bot]

This comment was marked as resolved.

@carderne
carderne force-pushed the feat/cron-windows-surface branch from 8058d83 to c6f4c34 Compare August 14, 2026 07:38
Comment thread packages/core/src/v3/schemas/api.ts

@devin-ai-integration devin-ai-integration Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Devin Review found 2 new potential issues.

Open in Devin Review

Comment thread apps/webapp/app/v3/scheduleWindow.server.ts
Comment thread apps/webapp/app/presenters/v3/ViewSchedulePresenter.server.ts
@carderne
carderne merged commit 3e7964e into main Aug 14, 2026
52 checks passed
@carderne
carderne deleted the feat/cron-windows-surface branch August 14, 2026 09:07
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.

4 participants