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

Panic when DENO_DIR not owned by current user #2731

Closed
ry opened this issue Aug 5, 2019 · 5 comments · Fixed by #5120
Closed

Panic when DENO_DIR not owned by current user #2731

ry opened this issue Aug 5, 2019 · 5 comments · Fixed by #5120
Labels
bug Something isn't working

Comments

@ry
Copy link
Member

ry commented Aug 5, 2019

> deno version
deno: 0.13.0
v8: 7.7.200
typescript: 3.5.1
> deno install gist https://deno.land/std/examples/gist.ts -A
Download https://deno.land/std@v0.11/installer/mod.ts
thread 'tokio-runtime-worker-0' panicked at 'called `Result::unwrap()` on an `Err` value: Os { code: 13, kind: PermissionDenied, message: "Permission denied" }', src/libcore/result.rs:999:5
note: Run with `RUST_BACKTRACE=1` environment variable to display a backtrace.
thread 'main' panicked at 'internal error: entered unreachable code', ../../third_party/rust_crates/registry/src/github.com-1ecc6299db9ec823/tokio-0.1.21/src/runtime/threadpool/mod.rs:296:26
thread 'tokio-runtime-worker-3' panicked at 'unexpected state while aborting task: Complete', ../../third_party/rust_crates/registry/src/github.com-1ecc6299db9ec823/tokio-threadpool-0.1.14/src/task/mod.rs:216:21
@ry ry added the bug Something isn't working label Aug 5, 2019
@bartlomieju
Copy link
Member

Still relevant?

@ry
Copy link
Member Author

ry commented Aug 5, 2019

I realized it happens when the cache directory is owned by some one else. A very valid reason to die, but it shouldn't panic - it ought to print a nicer message.

@nimish-gupta
Copy link

Hey @ry, can i start working on this issue?

@ry
Copy link
Member Author

ry commented Aug 6, 2019

@nimish-gupta Please do! It should be a small change.

@bartlomieju bartlomieju changed the title panic during deno install Panic when DENO_DIR not owned by current user Feb 5, 2020
@bnoordhuis
Copy link
Contributor

Seems to work okay now. Can this be closed?

$ env DENO_DIR=/root target/debug/deno install gist https://deno.land/std/examples/gist.ts -A
Download https://deno.land/std/examples/gist.ts
Source code header cache failed for 'https://deno.land/std/examples/gist.ts': Permission denied (os error 13) (for '"/root/deps/https/deno.land/std/examples/gist.ts.headers.json"')

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

Successfully merging a pull request may close this issue.

4 participants