Claude Opus 5.5

wrangler-4-122-0-2-b

Claude Code's read-only tools, web search on, ludion sync off

Question

Is adding no_nodejs_compat to compatibility_flags enough to opt a recent Worker out of Node.js APIs?

Answer key

A correct answer says
To turn Node.js compatibility off on a compatibility date of 2026-08-04 or later, set both `no_nodejs_compat` and `no_nodejs_compat_v2` flags.
The stale answer
Node.js compatibility is off unless you add `nodejs_compat`, so you simply leave the flag out to disable it.

The change's lesson

Answer

No, not by itself. For Workers with a compatibility date of 2026-08-04 or later, Node.js compatibility is on by default. To turn it off, Cloudflare's docs say to add **both** `no_nodejs_compat` and `no_nodejs_compat_v2` to `compatibility_flags`, and to remove `nodejs_compat` or `nodejs_compat_v2` if they're there. Workers with an earlier compatibility date don't get Node.js APIs unless you add `nodejs_compat`, so you don't need an opt-out flag for those. This change is recent, so check the compatibility flags page before you depend on the exact cutoff date.

Sources:
- [Compatibility flags · Cloudflare Workers docs](https://developers.cloudflare.com/workers/configuration/compatibility-flags/)
- [Node.js compatibility is now enabled by default · Changelog](https://developers.cloudflare.com/changelog/post/2026-08-04-nodejs-compat-default/)
- [Node.js compatibility · Cloudflare Workers docs](https://developers.cloudflare.com/workers/runtime-apis/nodejs/)

Answering cost $0.11.

Grade

correct

The judge's reason: It says no_nodejs_compat alone is not enough and that dates 2026-08-04 or later need both no_nodejs_compat and no_nodejs_compat_v2; it describes the older off-by-default behavior only for earlier compatibility dates.

The judge's log

Session log

What the agent wrote, the tools it called, and what they returned, from docs/bench/2026-10-11-done3/runs/B-project/wrangler-4-122-0-2-b.jsonl. Thinking and the session's settings are left out. The raw log

  1. Tool call: ToolSearch

    {
      "query": "select:WebSearch",
      "max_results": 1
    }
  2. Tool output

    {"type":"tool_reference","tool_name":"WebSearch"}
  3. Tool call: WebSearch

    {
      "query": "Cloudflare Workers no_nodejs_compat compatibility flag default enabled compatibility date",
      "mode": "standard",
      "allowed_domains": [
        "developers.cloudflare.com"
      ]
    }
  4. Tool output

    Web search results for query: "Cloudflare Workers no_nodejs_compat compatibility flag default enabled compatibility date"
    
    Links: [{"title":"Compatibility flags · Cloudflare Workers docs","url":"https://developers.cloudflare.com/workers/configuration/compatibility-flags/"},{"title":"Node.js compatibility · Cloudflare Workers docs","url":"https://developers.cloudflare.com/workers/runtime-apis/nodejs/"},{"title":"Workers Best Practices · Cloudflare Workers docs","url":"https://developers.cloudflare.com/workers/best-practices/workers-best-practices/"},{"title":"http · Cloudflare Workers docs","url":"https://developers.cloudflare.com/workers/runtime-apis/nodejs/http/"},{"title":"Node.js compatibility is now enabled by default · Changelog","url":"https://developers.cloudflare.com/changelog/post/2026-08-04-nodejs-compat-default/"},{"title":"https · Cloudflare Workers docs","url":"https://developers.cloudflare.com/workers/runtime-apis/nodejs/https/"},{"title":"fs · Cloudflare Workers docs","url":"https://developers.cloudflare.com/workers/runtime-apis/nodejs/fs/"},{"title":"Configuration explorer · Cloudflare CLI docs","url":"https://developers.cloudflare.com/cf/projects/config-explorer/"},{"title":"OpenNext adapter · Cloudflare Workers docs","url":"https://developers.cloudflare.com/workers/framework-guides/web-apps/opennext/"},{"title":"New Best Practices guide for Workers · Changelog","url":"https://developers.cloudflare.com/changelog/post/2026-02-15-workers-best-practices/"}]
    
    Per Cloudflare's docs and changelog, `nodejs_compat` is now on by default for newer compatibility dates, and `no_nodejs_compat` is the way to turn it off.
    
    - **Default for new dates:** Cloudflare's August 4, 2026 changelog says Workers with a compatibility date of 2026-08-04 or later get Node.js compatibility automatically, Workers with a compatibility date of 2026-08-04 or later enable Node.js compatibility by default.
    - **Opting out:** The compatibility flags page describes the switch-off: for dates from 2026-08-04 onward, you remove the positive flags if present and add both no_nodejs_compat and no_nodejs_compat_v2.
    - **Older dates:** Workers on earlier dates still need to opt in, and the docs say that for compatibility dates before 2026-08-04, add the nodejs_compat compatibility flag to your Wrangler configuration file.
    - **Existing projects:** Updating an existing project's date doesn't require removing the flags. The docs note that existing projects do not need to remove them when updating their compatibility date.
    
    The results don't say whether `nodejs_compat_v2` has its own separate default, and the changelog and docs both describe the 2026-08-04 change as recent, so check the current docs before relying on the exact cutoff.
    
    
    REMINDER: You MUST include the sources above in your response to the user using markdown hyperlinks.
  5. Agent

    No, not by itself. For Workers with a compatibility date of 2026-08-04 or later, Node.js compatibility is on by default. To turn it off, Cloudflare's docs say to add **both** `no_nodejs_compat` and `no_nodejs_compat_v2` to `compatibility_flags`, and to remove `nodejs_compat` or `nodejs_compat_v2` if they're there. Workers with an earlier compatibility date don't get Node.js APIs unless you add `nodejs_compat`, so you don't need an opt-out flag for those. This change is recent, so check the compatibility flags page before you depend on the exact cutoff date.
    
    Sources:
    - [Compatibility flags · Cloudflare Workers docs](https://developers.cloudflare.com/workers/configuration/compatibility-flags/)
    - [Node.js compatibility is now enabled by default · Changelog](https://developers.cloudflare.com/changelog/post/2026-08-04-nodejs-compat-default/)
    - [Node.js compatibility · Cloudflare Workers docs](https://developers.cloudflare.com/workers/runtime-apis/nodejs/)