Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

deno asks for NODE_CLUSTER_SCHED_POLICY every time on deno run #17414

Closed
scarf005 opened this issue Jan 14, 2023 · 1 comment · Fixed by denoland/std#3111
Closed

deno asks for NODE_CLUSTER_SCHED_POLICY every time on deno run #17414

scarf005 opened this issue Jan 14, 2023 · 1 comment · Fixed by denoland/std#3111
Assignees

Comments

@scarf005
Copy link
Contributor

scarf005 commented Jan 14, 2023

Summary

// hello.ts
console.log('hello world')

from deno 1.29.3, every deno run reqeusts env access to NODE_CLUSTER_SCHED_POLICY, which is a bit inconvenient.

Log

$ deno --version
deno 1.29.3 (release, x86_64-unknown-linux-gnu)
v8 10.9.194.5
typescript 4.9.4

$ deno run hello.ts 
⚠️  ┌ Deno requests env access to "NODE_CLUSTER_SCHED_POLICY".
   ├ Run again with --allow-env to bypass this prompt.
   └ Allow? [y/n] (y = yes, allow; n = no, deny) > 

❌ Denied env access to "NODE_CLUSTER_SCHED_POLICY".
error: Uncaught PermissionDenied: Requires env access to `NODE_CLUSTER_SCHED_POLICY`, run again with the --allow-env flag
    return Deno.env.get(name);
                    ^
    at Object.getEnv [as get] (deno:runtime/js/30_os.js:86:16)
    at denoEnvGet (https://deno.land/std@0.172.0/node/_process/process.ts:38:21)
    at Object.get (https://deno.land/std@0.172.0/node/_process/process.ts:59:24)
    at https://deno.land/std@0.172.0/node/internal/cluster/primary.ts:45:41
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 a pull request may close this issue.

3 participants