Module not found when running deno run
Something weird has started happening.
When I run
deno run src/main.ts
it seems as if Deno is trying to run it from a completely bonkers file path.
error: Module not found "file:///Users/me/Projects/my-project/src/Users/me/Projects/my-project/src/main.ts".
I don't know what's happened and why it seems to append the Users folder twice.
Does anyone have any idea?4 Replies
What does
pwd
return?Is your 'src' a symlink perhaps to "Users/me/Project/my-project/src"?
That would not make sense.
Or maybe.
/Users/me/Projects/my-project
I have not symlinked anything by my own hand 🙂
I figured out the culprit.
in my deno.json
imports
Which means deno run ./src/main.ts
has to change to deno run /main.ts