{"_self":{"principle":"Self-explaining payload — no external context required. This _self block describes what you are reading and where to look next.","widget":"article_topology","feature":"topology","name":"Article topology","what":"Claims, sources, anecdotes, user reports, related embeds, question graph slice — for ask/ROUTER.","contains":"claims, sources, anecdotes, question_graph slice","slug":"cloudflare-os-functions","urls":{"read":"https://miscsubjects.com/api/articles/cloudflare-os-functions/topology"},"how_to_use":"Claims, sources, anecdotes, user reports, related embeds, question graph slice — for ask/ROUTER.","write":null,"imessage":null,"router_tag":null,"proof_chain":[{"step":1,"claim":"Articles are voxel graphs of tiered claims, not prose blobs.","verify":"https://miscsubjects.com/api/articles/constitution"},{"step":2,"claim":"Claims link to hash-chained sources via source_ids.","verify":"https://miscsubjects.com/api/articles/cloudflare-os-functions/sources"},{"step":3,"claim":"Ask reads topology; ingest/claim append to ledger.","verify":"https://miscsubjects.com/api/protocol"},{"step":4,"claim":"Models queue growth: populate → collaborate → repair → reflex.","verify":"https://miscsubjects.com/api/protocol/grow"},{"step":5,"claim":"Graph proves its own shape (reflex) and $/claim (yield).","verify":"https://miscsubjects.com/graph.html?layer=reflex"},{"step":6,"claim":"Full feature index + _explain on every API response.","verify":"https://miscsubjects.com/api/articles/system-map"}],"related_features":[{"id":"ask","name":"Ask protocol","what":"Answer only from topology; creates question_node with gaps and ingest_hint.","urls":{"read":"https://miscsubjects.com/api/articles/cloudflare-os-functions/prompts","write":"https://miscsubjects.com/api/protocol/ask"}},{"id":"graph_topology","name":"Cross-article graph","what":"Merged claims/sources across condition+stack slugs for one question.","urls":{"read":"https://miscsubjects.com/api/articles/cloudflare-os-functions/graph-topology?question=..."}},{"id":"question_graph","name":"Question graph","what":"Ask nodes (questions + gaps) and evidence_ingest nodes (pasted model output).","urls":{"read":"https://miscsubjects.com/api/articles/cloudflare-os-functions/question-graph","write":"https://miscsubjects.com/api/protocol/ask"}},{"id":"voxels","name":"Voxel graph","what":"Claims as atoms, sources as edges (supported_by, posted_by). Per-claim provenance.","urls":{"read":"https://miscsubjects.com/api/articles/cloudflare-os-functions/voxels","write":"https://miscsubjects.com/api/protocol/claim"}}],"system_map":"https://miscsubjects.com/api/articles/system-map","system_map_markdown":"https://miscsubjects.com/api/articles/system-map?format=markdown","not_medical_advice":true},"_explain":{"feature":"topology","name":"Article topology","what":"Claims, sources, anecdotes, user reports, related embeds, question graph slice — for ask/ROUTER.","why":"Every feature is auditable collective intelligence","how":"Claims, sources, anecdotes, user reports, related embeds, question graph slice — for ask/ROUTER.","model":null,"verifies":null,"urls":{"read":"https://miscsubjects.com/api/articles/cloudflare-os-functions/topology"},"imessage":null,"router":null,"related":[{"id":"ask","what":"Answer only from topology; creates question_node with gaps and ingest_hint."},{"id":"graph_topology","what":"Merged claims/sources across condition+stack slugs for one question."},{"id":"question_graph","what":"Ask nodes (questions + gaps) and evidence_ingest nodes (pasted model output)."},{"id":"voxels","what":"Claims as atoms, sources as edges (supported_by, posted_by). Per-claim provenance."}],"not_medical_advice":true},"slug":"cloudflare-os-functions","title":"Pages Functions compiles 224 route files into one 1.35 MB Worker","register":"essay","tags":["cloudflare","architecture","workers","cloudflare-os","pages-functions","routing","middleware","wrangler","deployment"],"updated_at":"2026-07-26T05:59:19.635Z","body_excerpt":"A Pages Function is a JavaScript file inside a directory called `functions/`. Cloudflare compiles every one of those files into a single Worker script and runs it at the edge in front of the site's static files. There is no route table to write: the path of the file *is* the URL it answers.\n\nThat is fine at ten files. This application has 387 modules under `functions/`, of which 223 are route files exporting 270 request handlers. At that size four things start to matter: which file wins when two could match, whether a request touches the Worker at all, how big the compiled bundle has grown against a hard ceiling, and what you can see when a handler fails.\n\n## Evidence status\n\n**Observed** marks first-party measurements or runtime receipts from the named environment.\n**Derived** marks arithmetic calculated from cited inputs. **Specified** marks vendor or standards\ndocumentation. **Implemented** and **deployed** name code and live-state evidence, respectively.\n**Reproduced** means the stated procedure was rerun. **Externally attested** marks operator reports;\nthose reports show that an experience occurred, not that it is universal.\n\n## The file tree is the router, and there is no other route table\n\nCloudflare's routing document states it in one line: your `/functions` directory structure determines the routes. Real paths from this repository:\n\n| File | URL it answers |\n| --- | --- |\n| `functions/index.js` | `/` |\n| `functions/latest.js` | `/latest` |\n| `functions/a/[slug].js` | `/a/cloudflare-os-functions`, `/a/anything` |\n| `functions/api/articles/[[path]].js` | `/api/articles` and every path beneath it |\n| `functions/api/articles/design-law/skill.js` | `/api/articles/design-law/skill` |\n| `functions/_middleware.js` | every request, before any of the above |\n\nThree bracket forms, and they behave differently:\n\n| Form | Captures | `context.params` type | Example in this repo |\n| --- | --- | --- | --- |\n| `name.js` | exactly that path | — | `functions/latest.js` |\n| `[param].js` | exactly one path segment | string | `functions/a/[slug].js` |\n| `[[path]].js` | one segment or many | array of strings | `functions/api/articles/[[path]].js` |\n\n`functions/a/[slug].js` answers `/a/thing` and **not** `/a/thing/extra`. The catch-all answers `/api/articles/x/y/z` and receives `context.params.path` as `[\"x\",\"y\",\"z\"]`. If no Function matches, Pages falls through to a static file with that name. Trailing slashes are ignored.\n\n## A handler file exports up to eight functions, one per HTTP method\n\nThe API reference is explicit about the interaction between them: `onRequest` is called *unless* a more specific `onRequestVerb` is exported. Export both `onRequest` and `onRequestGet` and a GET only ever reaches `onRequestGet`. The eight names are `onRequest`, `onRequestGet`, `onRequestPost`, `onRequestPut`, `onRequestPatch`, `onRequestDelete`, `onRequestHead`, `onRequestOptions`. Counted across this repository today:\n\n| Export | Count |\n| --- | --- |\n| `onRequestGet` | 169 |\n| `onRequestPost` | 51 |\n| `onRequest` | 28 |\n| `onRequestOptions` | 7 |\n| `onRequestPut` | 6 |\n| `onRequestDelete` | 6 |\n| `onRequestPatch` | 3 |\n| **Total handler exports** | **270** |\n\n```bash\ngrep -rhoE '^export (async )?(function|const) onRequest[A-Za-z]*' functions --include='*.js' \\\n  | grep -oE 'onRequest[A-Za-z]*' | sort | uniq -c | sort -rn\n```\n\nEvery handler receives one argument, the `EventContext`. Its useful members: `request`, `env` (your bindings), `params` (the bracket captures), `next()` (pass through to the next Function or to the static asset server), `waitUntil()` (finish work after the response is sent) and `passThroughOnException()`.\n\n## One middleware file sits in front of 100 percent of traffic\n\n`_middleware.js` is the only filename Pages treats as middleware. At `functions/_middleware.js` it runs in front of the entire application, static files included. At `functions/users/_middleware.js` it runs only for requests under `/users`. It calls `context.next()","ranking":"safety-first (interaction_risk/limitations), then quote-gated effective_weight","claims":[{"id":"c12","text":"A SvelteKit site reported crossing the old bundle limit after more than 200 posts compiled into its Worker.","tier":"anecdotal","section":"workers.api.error.script_too_large: three walls, three different exits","interaction_risk":false,"status":"active","source_ids":["p1"],"why_material":"Many small pages can create one oversized bundle.","retracted_at":null,"retraction_reason":null,"challenged_by":[],"effective_weight":0.3,"quote_gated":false},{"id":"c14","text":"A 300 MB Pages upload failed partway through asset upload, which is distinct from the Worker script-size limit.","tier":"anecdotal","section":"workers.api.error.script_too_large: three walls, three different exits","interaction_risk":false,"status":"active","source_ids":["p3"],"why_material":"Similar deploy symptoms can come from different pipelines.","retracted_at":null,"retraction_reason":null,"challenged_by":[],"effective_weight":0.3,"quote_gated":false},{"id":"c17","text":"A Pages operator reported an empty production 500 that took a day to diagnose because useful logging was unavailable.","tier":"anecdotal","section":"A 500 with an empty body, and nothing to look at","interaction_risk":false,"status":"active","source_ids":["p6"],"why_material":"It motivates live tailing and explicit error capture.","retracted_at":null,"retraction_reason":null,"challenged_by":[],"effective_weight":0.3,"quote_gated":false},{"id":"c19","text":"A Pages-to-Workers migration can be blocked when the custom domain's DNS zone cannot move to Cloudflare.","tier":"anecdotal","section":"Pages or Workers: a verdict for each row","interaction_risk":false,"status":"active","source_ids":["p4"],"why_material":"This is a hard external constraint, not reluctance.","retracted_at":null,"retraction_reason":null,"challenged_by":[],"effective_weight":0.3,"quote_gated":false},{"id":"c20","text":"Region choice and data-residency needs can push an operator off Workers even when the technical stack otherwise fits.","tier":"anecdotal","section":"Pages or Workers: a verdict for each row","interaction_risk":false,"status":"active","source_ids":["p8"],"why_material":"Placement hints do not equal guaranteed regional confinement.","retracted_at":null,"retraction_reason":null,"challenged_by":[],"effective_weight":0.3,"quote_gated":false},{"id":"c22","text":"A positive production report combines a Pages front end with a 60-route Workers API and multiple Cloudflare storage products.","tier":"anecdotal","section":"Pages or Workers: a verdict for each row","interaction_risk":false,"status":"active","source_ids":["p9"],"why_material":"The source set includes a working production architecture, not only failures.","retracted_at":null,"retraction_reason":null,"challenged_by":[],"effective_weight":0.3,"quote_gated":false},{"id":"c1","text":"Pages Functions maps files under functions directly to request paths and compiles the whole tree into one Worker.","tier":"system","section":"The file tree is the router, and there is no other route table","interaction_risk":false,"status":"active","source_ids":["r2","s1","s12"],"why_material":"Routing and bundle size come from the same file tree.","retracted_at":null,"retraction_reason":null,"challenged_by":[],"effective_weight":0.1,"quote_gated":false},{"id":"c2","text":"Single brackets capture one path segment while double brackets capture one or more segments as an array.","tier":"fact","section":"The file tree is the router, and there is no other route table","interaction_risk":false,"status":"active","source_ids":["s1"],"why_material":"Using the wrong bracket form changes which URLs can reach a handler.","retracted_at":null,"retraction_reason":null,"challenged_by":[],"effective_weight":0.1,"quote_gated":false},{"id":"c3","text":"A specific onRequestVerb export overrides the generic onRequest export for that HTTP method.","tier":"fact","section":"A handler file exports up to eight functions, one per HTTP method","interaction_risk":false,"status":"active","source_ids":["s2"],"why_material":"A generic handler does not wrap a more specific method handler.","retracted_at":null,"retraction_reason":null,"challenged_by":[],"effective_weight":0.1,"quote_gated":false},{"id":"c4","text":"Root _middleware runs around every Functions and static request unless routing excludes the request from the Worker.","tier":"system","section":"One middleware file sits in front of 100 percent of traffic","interaction_risk":false,"status":"active","source_ids":["r6","s3"],"why_material":"Middleware CPU and failures affect the whole site.","retracted_at":null,"retraction_reason":null,"challenged_by":[],"effective_weight":0.1,"quote_gated":false},{"id":"c5","text":"When a static route and an ancestor optional catch-all overlap, returning byte-identical behavior from both removes dependence on observed precedence.","tier":"system","section":"An optional catch-all can beat a static file with the same name","interaction_risk":false,"status":"active","source_ids":["r4","s4"],"why_material":"The endpoint stays correct whichever generated route wins.","retracted_at":null,"retraction_reason":null,"challenged_by":[],"effective_weight":0.1,"quote_gated":false},{"id":"c6","text":"_routes.json decides which requests invoke the Worker, with exclude rules winning over include rules.","tier":"fact","section":"_routes.json decides whether a request costs anything","interaction_risk":false,"status":"active","source_ids":["r6","s4"],"why_material":"Excluded static assets avoid invocation cost and routing collisions.","retracted_at":null,"retraction_reason":null,"challenged_by":[],"effective_weight":0.1,"quote_gated":false},{"id":"c7","text":"The fresh tree contains 391 modules, 224 route files and 167 shared library modules.","tier":"measurement","section":"The fresh compiler receipt moved the file count, not the architecture","interaction_risk":false,"status":"active","source_ids":["r1"],"why_material":"It corrects the dated 387-module inventory without erasing it.","retracted_at":null,"retraction_reason":null,"challenged_by":[],"effective_weight":0.1,"quote_gated":false},{"id":"c8","text":"214 current files export 271 request handlers, including 170 GET handlers.","tier":"measurement","section":"The fresh compiler receipt moved the file count, not the architecture","interaction_risk":false,"status":"active","source_ids":["r1"],"why_material":"Module count is not handler count.","retracted_at":null,"retraction_reason":null,"challenged_by":[],"effective_weight":0.1,"quote_gated":false},{"id":"c9","text":"Pages Functions inherits Workers compressed bundle, startup, CPU, memory and subrequest limits.","tier":"fact","section":"The limits, with the numbers the documentation carries today","interaction_risk":false,"status":"active","source_ids":["s5","s6"],"why_material":"Pages does not have a separate compute envelope.","retracted_at":null,"retraction_reason":null,"challenged_by":[],"effective_weight":0.1,"quote_gated":false},{"id":"c10","text":"Wrangler's gzipped bundle size, not raw source size, is compared with the 3 MB or 10 MB script limit.","tier":"system","section":"Measured: 5.07 MiB of compiled source, 1.29 MiB gzipped","interaction_risk":false,"status":"active","source_ids":["r2","s11","s6"],"why_material":"Judging the raw file gives the wrong headroom.","retracted_at":null,"retraction_reason":null,"challenged_by":[],"effective_weight":0.1,"quote_gated":false},{"id":"c11","text":"The fresh bundle is 5,325,637 bytes raw and 1,350,472 bytes gzipped, or 45.0% of the free ceiling.","tier":"measurement","section":"The fresh compiler receipt moved the file count, not the architecture","interaction_risk":false,"status":"active","source_ids":["r2"],"why_material":"It is the current deploy-size receipt.","retracted_at":null,"retraction_reason":null,"challenged_by":[],"effective_weight":0.1,"quote_gated":false},{"id":"c13","text":"A 2.4 MB compiled WASM file independently reproduced script_too_large under the historical 1 MB free ceiling.","tier":"independent","section":"workers.api.error.script_too_large: three walls, three different exits","interaction_risk":false,"status":"active","source_ids":["p2","s13"],"why_material":"A single binary needs a different repair than many modules.","retracted_at":null,"retraction_reason":null,"challenged_by":[],"effective_weight":0.1,"quote_gated":false},{"id":"c15","text":"The old 1 MiB Workers Free script limit was raised to 3 MB, so historical failure reports must be evaluated against current limits.","tier":"system","section":"workers.api.error.script_too_large: three walls, three different exits","interaction_risk":false,"status":"active","source_ids":["p1","p2","s6"],"why_material":"A once-blocked project may now fit unchanged.","retracted_at":null,"retraction_reason":null,"challenged_by":[],"effective_weight":0.1,"quote_gated":false},{"id":"c16","text":"The measured warm Function-route median was 145 ms versus 68 ms for an excluded cached font, but the paths did different work.","tier":"measurement","section":"Cold and warm, measured over eighteen requests from one client","interaction_risk":false,"status":"active","source_ids":["r3"],"why_material":"The result is bounded rather than mislabelled as pure routing overhead.","retracted_at":null,"retraction_reason":null,"challenged_by":[],"effective_weight":0.1,"quote_gated":false},{"id":"c18","text":"Pages supplies real-time logs, but broader persistent observability and source-map support are Workers migration reasons.","tier":"system","section":"A 500 with an empty body, and nothing to look at","interaction_risk":false,"status":"active","source_ids":["s7","s8"],"why_material":"The logging boundary changes post-incident debugging.","retracted_at":null,"retraction_reason":null,"challenged_by":[],"effective_weight":0.1,"quote_gated":false},{"id":"c21","text":"Cloudflare now recommends Workers for broader capabilities, while Pages remains viable for file routing and non-Cloudflare-zone custom domains.","tier":"system","section":"Pages or Workers: a verdict for each row","interaction_risk":false,"status":"active","source_ids":["p4","p7","s8"],"why_material":"The migration verdict is conditional rather than universal.","retracted_at":null,"retraction_reason":null,"challenged_by":[],"effective_weight":0.1,"quote_gated":false},{"id":"c23","text":"A direct Pages deployment must print the Functions-bundle upload line; otherwise static assets can ship without dynamic code.","tier":"system","section":"Uploading Functions bundle is the line that proves the deploy shipped code","interaction_risk":false,"status":"active","source_ids":["r5","s9"],"why_material":"A successful command can still deploy a Functions-less site from the wrong directory.","retracted_at":null,"retraction_reason":null,"challenged_by":[],"effective_weight":0.1,"quote_gated":false},{"id":"c24","text":"A report about a Pages deploy quota is specifically a Git-integration build concern; direct Wrangler uploads are a separate path.","tier":"system","section":"The limits, with the numbers the documentation carries today","interaction_risk":false,"status":"active","source_ids":["p5","s5","s9"],"why_material":"It prevents a historical anecdote from becoming a false universal deploy cap.","retracted_at":null,"retraction_reason":null,"challenged_by":[],"effective_weight":0.1,"quote_gated":false},{"id":"c25","text":"Local Pages development runs the Functions project without uploading it, so upload-time bundle rejection must be reproduced with the build or deploy command.","tier":"system","section":"workers.api.error.script_too_large: three walls, three different exits","interaction_risk":false,"status":"active","source_ids":["s10"],"why_material":"A project working locally does not prove it fits the deployed Worker envelope.","retracted_at":null,"retraction_reason":null,"challenged_by":[],"effective_weight":0.1,"quote_gated":false}],"sources":[{"id":"s1","type":"specification","url":"https://developers.cloudflare.com/pages/functions/routing/","title":"Pages Functions routing","quote":"Functions utilize file-based routing. Your `/functions` directory structure determines the designated routes that your Functions will run on.","summary":"Normative file-to-route mapping, dynamic segments, optional catch-alls, precedence and trailing slashes.","claim_ids":["c1","c2"],"hash":"bff543880c76406665c09608749a644f1a7e296f38b3a5e1a4152f87c0cd4385"},{"id":"s2","type":"specification","url":"https://developers.cloudflare.com/pages/functions/api-reference/","title":"Pages Functions API reference","quote":"The `onRequest` method will be called unless a more specific `onRequestVerb` method is exported.","summary":"EventContext members and the eight supported request-handler export names.","claim_ids":["c3"],"hash":"98b4ec1949ffb8578523a2142091cd0af44036dd943a90333c0e0af09e13531a"},{"id":"s3","type":"specification","url":"https://developers.cloudflare.com/pages/functions/middleware/","title":"Pages Functions middleware","quote":"Middleware is reusable logic that can be run before your `onRequest` function.","summary":"Middleware placement, arrays, next(), error handling and execution order.","claim_ids":["c4"],"hash":"7e1fc0fb9ef978f897139b04feb04015bcccb6a4ed71fec1b28b7a4e9ff8f9c5"},{"id":"s4","type":"publisher_documentation","url":"https://developers.cloudflare.com/pages/functions/routing/","title":"Pages _routes.json routing controls","quote":"More specific routes (routes with fewer wildcards) take precedence over less specific routes.","summary":"Include/exclude controls, route specificity and the 100-rule boundary.","claim_ids":["c5","c6"],"hash":"b4aef2934fe7d15c637a469e00981767d388a8fbbbb200bdeec7cd17b0c40377"},{"id":"s5","type":"publisher_documentation","url":"https://developers.cloudflare.com/pages/platform/limits/","title":"Cloudflare Pages limits","quote":"Cloudflare Pages has a limit of 100 projects per account.","summary":"Pages project, build, file, asset and custom-domain limits current to the article.","claim_ids":["c24","c9"],"hash":"e236016b168ef066524563a92b6156669ccc96e5f1248e2db1dd5c3d00e2e1fb"},{"id":"s6","type":"publisher_documentation","url":"https://developers.cloudflare.com/workers/platform/limits/","title":"Cloudflare Workers limits","quote":"Worker size","summary":"Compressed and uncompressed bundle ceilings, startup, CPU, memory and subrequest limits inherited by Pages Functions.","claim_ids":["c10","c15","c9"],"hash":"6d4b84cb0d2fe51c5a11235d6eacefc1ea5c0847d5ec2665cf3dc376d5a313a1"},{"id":"s7","type":"publisher_documentation","url":"https://developers.cloudflare.com/pages/functions/debugging-and-logging/","title":"Pages Functions debugging and logging","quote":"Logs are available for every deployment of your Pages project.","summary":"Live deployment tailing and its boundary: real-time observation rather than persistent queryable history.","claim_ids":["c18"],"hash":"f281df5ff84adee0847eb909c48682217ff9846eba6b49c04831ceeb56b64054"},{"id":"s8","type":"publisher_documentation","url":"https://developers.cloudflare.com/workers/static-assets/migration-guides/migrate-from-pages/","title":"Migrate from Pages to Workers","quote":"Unlike Pages, Workers has a distinctly broader set of features available to it","summary":"Official Pages-to-Workers migration differences, assets binding and routing changes.","claim_ids":["c18","c21"],"hash":"0bee2b54a32360dda272930a3193e85e2a1d571d080a3288752e38f889b4df5e"},{"id":"s9","type":"publisher_documentation","url":"https://developers.cloudflare.com/pages/get-started/direct-upload/","title":"Pages Direct Upload","quote":"Direct Upload enables you to upload your prebuilt assets to Pages and deploy them to the Cloudflare global network.","summary":"Wrangler direct-deployment workflow used by this repository instead of Git integration.","claim_ids":["c23","c24"],"hash":"dfc05d3f6c212e1f4f549f15715cc8442333511ce723fc6246e5807482a27080"},{"id":"s10","type":"publisher_documentation","url":"https://developers.cloudflare.com/pages/functions/local-development/","title":"Pages Functions local development","quote":"The main command for local development on Pages is `wrangler pages dev`.","summary":"Local Functions development surface and why upload-only limits do not appear locally.","claim_ids":["c25"],"hash":"c0b63bbfb33d9bf35bce1fa5c04dbb83b6f89a02edf97a59adfd42084d744d69"},{"id":"s11","type":"publisher_documentation","url":"https://opennext.js.org/cloudflare/troubleshooting","title":"OpenNext Cloudflare bundle troubleshooting","quote":"Only the latter (gzipped size) matters for these limits.","summary":"Third-party framework guidance that distinguishes raw and compressed Wrangler bundle sizes.","claim_ids":["c10"],"hash":"bb0213f0a2cf430586417079be7705bd8fff07613d97521807433be975c17077"},{"id":"s12","type":"repository","url":"https://github.com/cloudflare/workers-sdk","title":"Cloudflare workers-sdk","quote":"Home to Wrangler, the CLI for Cloudflare Workers®","summary":"Public Wrangler repository containing the Pages Functions compiler and deploy command.","claim_ids":["c1"],"hash":"f1fedf163bf2c655f70881168ea652d446abc4f868db4d7a6711f14a9262368e"},{"id":"s13","type":"independent_measurement","url":"https://github.com/nuxt-modules/og-image/issues/193","title":"Independent WASM bundle-limit reproduction","quote":"the compiled-wasm file is 2.4mb","summary":"Named reproduction where a single compiled WASM file exceeded the then-current Pages Free Worker limit.","claim_ids":["c13"],"hash":"9f219842c6d16119bce9349ba396685b5045a0c8aebdf599e587af2099ed686f"},{"id":"p1","type":"stackoverflow","url":"https://stackoverflow.com/questions/77173778/how-to-fix-workers-api-error-script-too-large-when-deploying-sveltekit-to-cloudf","title":"How to fix workers.api.error.script_too_large when deploying Sveltekit to Cloudflare pages","quote":"I now have more than 200 posts with multiple components each. Everything was working well, but recently started getting the following error when deploying to Cloudflare pages","summary":"A SvelteKit/mdsvex blog that deployed fine started failing once it crossed ~200 posts, because the generated _worker.js exceeded the 1 MiB Pages Functions script limit. The canonical 'many handlers, one deployment, one bundle' failure. Negative.","claim_ids":["c12","c15"],"hash":"2cb7222dc2d52d7729aaa1f096c3372dd8fb2d48bf042cd0386772923e03131f"},{"id":"p2","type":"github","url":"https://github.com/nuxt-modules/og-image/issues/193","title":"Deploying on Cloudflare Pages, script_too_large?","quote":"Tried deploying a branch with a simple template, it works well locally, but with the 1mb worker limit on Pages (free) I get the `workers.api.error.script_too_large` error as the compiled-wasm file is 2.4mb.","summary":"Works locally, dies on deploy: a 2.4mb compiled WASM asset blows the 1mb Pages Functions limit on the free plan. Asks whether the package is usable at all under that ceiling. Negative — bundle-size limit as a hard adoption wall.","claim_ids":["c13","c15"],"hash":"01c1475674ee3455d860a97a01388def3dea8a7076f380ba0f358c2fbdf7dc6c"},{"id":"p3","type":"github","url":"https://github.com/cloudflare/workers-sdk/issues/1194","title":"🐛 BUG: pages publish very slow / crashing","quote":"When I upload to pages with wrangler 2 it goes reaaallly slow and then crashes","summary":"A ~300MB site that uploaded fine to KV under wrangler 1 crawls and then dies with 'FatalError: Failed to upload files' partway through (809/8009 files) on Pages with wrangler 2. Long-running deployment-scale pain. Negative.","claim_ids":["c14"],"hash":"9a0e812c483aeca3744651a35e0c5d6050eb486353dfe1e5c96913f06b9b51ff"},{"id":"p4","type":"hn","url":"https://news.ycombinator.com/item?id=44854848","title":"Cloudflare recommends migrating from Pages to Workers","quote":"I had to use Pages since Workers don't support \"Custom domains outside Cloudflare zones\" [1]. There's no way I can transfer the domain since I have subdomains tightly integrated with AWS services.","summary":"Cannot follow Cloudflare's own Pages-to-Workers recommendation because Workers static assets do not support custom domains outside Cloudflare zones and his DNS is bound to AWS. Concrete migration blocker. Negative.","claim_ids":["c19","c21"],"hash":"6020d138c8f5ab48d41b92d99ddbd52c35508f8e44f3410d6b2d7eb7d297aa8e"},{"id":"p5","type":"hn","url":"https://news.ycombinator.com/item?id=45936226","title":"Magit manuals are available online again","quote":"Because Cloudflare pages has this doofy deploy limit hanging over your head. Even if you won't reasonably run into it, it's still weird. R2's free limits are significantly higher.","summary":"Explains choosing R2 over Pages for hosting docs specifically because of the Pages deployments-per-month cap. Negative on Pages' deployment quota as a reason to avoid the product.","claim_ids":["c24"],"hash":"45cb1b69d6a4f0cfc32921dfdb295f7ca0b6f6622a884a2ab43771ab6e426d7c"},{"id":"p6","type":"hn","url":"https://news.ycombinator.com/item?id=43164386","title":"Claude 3.7 Sonnet and Claude Code","quote":"a CloudFlare pages function would return 500 + nonsensical error and an empty response in prod. Tried to figure this out all Friday. It was super annoying to fix as there's no way to add more logging","summary":"Spent a full day on a Pages Function returning a 500 with an empty response only in production, with no way to add logging because the script died before emitting output. An observability complaint specific to Pages Functions. Negative.","claim_ids":["c17"],"hash":"5d5ecba9a95f2455f9b1263d57826deb62495b78d4b93641bd8fe95e83d092b3"},{"id":"p7","type":"hn","url":"https://news.ycombinator.com/item?id=43646198","title":"Journey to Optimize Cloudflare D1 Database Queries","quote":"This is kind of what happened (is happening) with pages right now. Workers gained pretty much all of their features and are now the recommended way to deliver static sites too.","summary":"A Cloudflare fan describing Pages being quietly superseded by Workers as feature parity landed, and predicting the same absorption will happen to Workers by Durable Objects. Mixed — approves the direction while documenting the churn.","claim_ids":["c21"],"hash":"824154b1dfa7bfb8a0594cdbcc5ce0b59c313060bf6e3037f771aef972775f88"},{"id":"p8","type":"hn","url":"https://news.ycombinator.com/item?id=44855519","title":"Cloudflare recommends migrating from Pages to Workers","quote":"I recently ported an entire TS project from cloudflare workers to a django python app since cloudflare workers don't support choice of region/country when deploying workers.","summary":"Ported a whole TypeScript Workers project off Cloudflare to a Django app because Workers offers no region/country placement choice outside Enterprise, which breaks data-residency compliance. Still calls Workers+R2+D1 a great low-overhead stack. Negative move-off.","claim_ids":["c20"],"hash":"afdc8c64c4eb658024e1476cc56d3e9f5eec77b49be5041d764241c357b1ab11"},{"id":"p9","type":"hn","url":"https://news.ycombinator.com/item?id=47146087","title":"5 months ago I'd never coded anything. I now have full-stack analytics platform","quote":"Stack: Next.js 14 + React 18 on Cloudflare Pages, Hono 4.10 API on Cloudflare Workers (60+ route modules), 4x Cloudflare D1 databases (~180 tables total), Neon Postgres via Prisma + Hyperdrive, KV + R2 + Durable Objects + Queues","summary":"A self-described non-coder built and shipped a full NFL projections analytics platform entirely on the Cloudflare stack — Pages front end, Workers API, four D1 databases, plus KV, R2, Durable Objects and Queues, with Access-protected admin routes and 8 cron jobs. He reports it working in production at real schema depth. Positive.","claim_ids":["c22"],"hash":"3772d414b600b4ba2a5f3b06d65169238d9f49381a08d1b06dadfda0b54c2d30"},{"id":"r1","type":"runtime_receipt","url":"https://miscsubjects.com/api/articles/cloudflare-os-functions","title":"Fresh first-party Functions tree inventory","quote":"JavaScript modules under `functions/` | 391","summary":"Filesystem harness counted modules, route files, libraries, handler files, exports and bracket-route forms.","claim_ids":["c7","c8"],"hash":"858f8a222cfd84be98b23bbf81aa33f5988e628f17afce2c2604fd3985dc870c"},{"id":"r2","type":"runtime_receipt","url":"https://miscsubjects.com/api/articles/cloudflare-os-functions","title":"Fresh first-party Pages Functions compilation","quote":"Gzipped bundle | 1,350,472 bytes; 45.0% of the 3 MB free ceiling","summary":"Wrangler pages functions build compiled the current tree into a temporary directory; Node gzip measured the deploy-relevant size.","claim_ids":["c1","c10","c11"],"hash":"154723da5355d354276fdaf9176ac144b1b5682a4d1e71628d976582afd10140"},{"id":"r3","type":"runtime_receipt","url":"https://miscsubjects.com/api/articles/cloudflare-os-functions","title":"First-party cold and warm request timing","quote":"Median time to first byte: 145 ms for the Function route on a warm connection, 68 ms for the excluded static route.","summary":"Published curl harness: five new connections, seven reused Function requests and five reused excluded-static requests.","claim_ids":["c16"],"hash":"83059f9bca82747efe4e49d6b96ef068cd744e33518909b4e51f7abc1269dd60"},{"id":"r4","type":"runtime_receipt","url":"https://miscsubjects.com/api/articles/cloudflare-os-functions","title":"First-party overlapping-route receipt","quote":"The response proves nothing about which one ran","summary":"The exact file and catch-all both return byte-identical markdown for the overlapping design-law skill path.","claim_ids":["c5"],"hash":"f21f6a18b7476298bc3673a51d0352bbe2303c1e06c88e136c696d36a47de962"},{"id":"r5","type":"runtime_receipt","url":"https://miscsubjects.com/api/articles/cloudflare-os-functions","title":"First-party deploy-output receipt","quote":"✨ Uploading Functions bundle","summary":"Exact successful Wrangler deploy line that proves dynamic code, not only static assets, was uploaded.","claim_ids":["c23"],"hash":"67a4db032fc0d1ace40665f73f7b967c0e401f704182091c5b802138612c87ab"},{"id":"r6","type":"runtime_receipt","url":"https://miscsubjects.com/api/articles/cloudflare-os-functions","title":"Fresh first-party _routes.json inventory","quote":"`_routes.json` rules | 1 include + 15 exclude","summary":"Parsed public/_routes.json and counted the current include/exclude rules without modifying it.","claim_ids":["c4","c6"],"hash":"00106aeb567eaa4c314dac6bc4fa1f10326c2ae37eff3546f70b1dfb71d525f4"}],"anecdotal_sources":[],"scientific_sources":[],"user_reports":[],"related_articles":[],"question_graph":{"slug":"cloudflare-os-functions","questions":[],"evidence":[],"edges":[],"counts":{"questions":0,"evidence":0,"edges":0}},"honesty":{"active_claims":25,"retracted_claims":0,"cut_claims":0,"challenges":0,"scrub_events":0,"note":"Retracted/cut claims stay on ledger but are excluded from ask unless ?include_inactive=1"},"counts":{"claims":25,"claims_total":25,"sources":28,"anecdotal":0,"scientific":0,"user_reports":0,"questions":0,"evidence_ingests":0}}