deno icon indicating copy to clipboard operation
deno copied to clipboard

Create root directory implicitly if `DENO_INSTALL_ROOT` does not exist

Open idletea opened this issue 2 years ago • 2 comments

If you install deno and attempt to install something when the deno root does not exist and is set with DENO_INSTALL_ROOT you get an incredibly unhelpful error:

error: No such file or directory (os error 2)

This is because inside the resolve_shim_data call an attempt is made to canonicalize the path which doesn't yet exist.

I'm not sure this PR is the right approach to fix the issue, it might be better to try and replicate what I assume happens elsewhere in the codebase to ensure .deno exists, because I can't replicate this issue when I unset DENO_INSTALL_ROOT

idletea avatar May 21 '22 16:05 idletea

CLA assistant check
Thank you for your submission! We really appreciate it. Like many open source projects, we ask that you sign our Contributor License Agreement before we can accept your contribution.
You have signed the CLA already but the status is still pending? Let us recheck it.

CLAassistant avatar May 21 '22 16:05 CLAassistant

This pull request has been automatically marked as stale because it has not had recent activity. It will be closed in 7 days if no further activity occurs. Thank you for your contributions.

stale[bot] avatar Jul 25 '22 03:07 stale[bot]

This pull request has been automatically marked as stale because it has not had recent activity. It will be closed in 7 days if no further activity occurs. Thank you for your contributions.

stale[bot] avatar Sep 24 '22 02:09 stale[bot]