Skip to content

Commit

Permalink
remove unnecessary compat flag
Browse files Browse the repository at this point in the history
  • Loading branch information
anonrig committed Jan 13, 2025
1 parent 9380b4c commit c197b93
Show file tree
Hide file tree
Showing 4 changed files with 1 addition and 18 deletions.
1 change: 0 additions & 1 deletion src/node/internal/compatibility-flags.d.ts
Original file line number Diff line number Diff line change
Expand Up @@ -31,4 +31,3 @@ export const workerdExperimental: boolean;
export const durableObjectGetExisting: boolean;
export const vectorizeQueryMetadataOptional: boolean;
export const nodeJsZlib: boolean;
export const nodeJsCompatNet: boolean;
8 changes: 0 additions & 8 deletions src/node/net.ts
Original file line number Diff line number Diff line change
Expand Up @@ -27,14 +27,6 @@

import inner from 'cloudflare-internal:sockets';

import { default as compatFlags } from 'workerd:compatibility-flags';

if (!compatFlags.nodeJsCompatNet || !compatFlags.workerdExperimental) {
throw new Error(
'To use the node:net built-in module, set the nodejs_compat_net flag'
);
}

import {
ERR_INVALID_ARG_VALUE,
ERR_INVALID_ARG_TYPE,
Expand Down
2 changes: 1 addition & 1 deletion src/workerd/api/node/tests/net-nodejs-test.wd-test
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ const unitTests :Workerd.Config = (
(name = "worker", esModule = embed "net-nodejs-test.js")
],
compatibilityDate = "2025-01-09",
compatibilityFlags = ["nodejs_compat", "nodejs_compat_net", "experimental"],
compatibilityFlags = ["nodejs_compat"],
)
),
( name = "internet", network = ( allow = ["private"] ) ),
Expand Down
8 changes: 0 additions & 8 deletions src/workerd/io/compatibility-date.capnp
Original file line number Diff line number Diff line change
Expand Up @@ -679,12 +679,4 @@ struct CompatibilityFlags @0x8f8c1b68151b6cef {
$compatDisableFlag("cache_no_cache_disabled")
$experimental;
# Enables the use of cache: no-cache in the fetch api.

nodeJsCompatNet @71 :Bool
$compatEnableFlag("nodejs_compat_net")
$compatDisableFlag("no_nodejs_compat_net")
$compatEnableDate("2025-06-01")
$experimental;
# When the nodejs_compat or nodejs_compat v2 flags are enabled, the nodejs_compat_net
# flag determines if the node:net built-in module is also available.
}

0 comments on commit c197b93

Please sign in to comment.