From 93d47da92ce278c516388e9ef5fd531f5f3137a9 Mon Sep 17 00:00:00 2001 From: Xinyao Date: Sat, 18 Jul 2026 00:22:14 +0800 Subject: [PATCH] fix: drop [triggers] block from backend Pages config MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit wrangler ≥4.9x validates wrangler.toml as a Pages config (it has pages_build_output_dir) and hard-errors on [triggers]: "Configuration file for Pages projects does not support 'triggers'" — every pages deploy fails before upload. The block was documentation only (Pages Functions never ran the cron); keep the cadence documented in a comment and point at the deletion worker's own wrangler.toml, which is where the cron actually lives. --- apps/backend/wrangler.toml | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/apps/backend/wrangler.toml b/apps/backend/wrangler.toml index 0613a144..94a8ac31 100644 --- a/apps/backend/wrangler.toml +++ b/apps/backend/wrangler.toml @@ -61,12 +61,12 @@ bucket_name = "spool-hub" [vars] ENV = "development" -# Cron trigger for the deletion sweep. Pages Functions ignore this in -# the Pages runtime — the deletion worker is intended to run as a +# Cron cadence for the deletion sweep ("0 */6 * * *"). Pages configs +# reject a [triggers] block outright (wrangler ≥4.9x validates it), so +# this lives here as documentation only — the deletion worker is a # companion Worker (functions/_scheduled/deletion-worker.ts) sharing the -# same D1/KV/R2 bindings. Kept here for documentation. -[triggers] -crons = ["0 */6 * * *"] +# same D1/KV/R2 bindings, and its cron is set in +# workers/spool-share-deletion/wrangler.toml. # Secrets (set ONCE per environment via wrangler — never commit): # wrangler pages secret put WORKOS_CLIENT_ID --project-name spool-share-backend