-
Notifications
You must be signed in to change notification settings - Fork 5.2k
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
Incorrect relative module imports from remote scripts #645
Comments
Windows can't handle ":" in path names, so we use a special directory format .deno/deps/localhost_PORT4545/ to represent hosts with non-default ports. Fixes denoland#645.
Windows can't handle ":" in path names, so we use a special directory format .deno/deps/localhost_PORT4545/ to represent hosts with non-default ports. Fixes denoland#645.
Windows can't handle ":" in path names, so we use a special directory format .deno/deps/localhost_PORT4545/ to represent hosts with non-default ports. Fixes denoland#645.
* Fixes module resolution error denoland#645 * Better flag parsing * lStatSync -> lstatSync * Added deno.renameSync() * Added deno.mkdirSync() * Fix circular dependencies denoland#653 * Added deno.env() and --allow-env
* Fixes module resolution error denoland#645 * Better flag parsing * lStatSync -> lstatSync * Added deno.renameSync() * Added deno.mkdirSync() * Fix circular dependencies denoland#653 * Added deno.env() and --allow-env
I might be having the same error at v0.1.3. I have this source file at Gist but my local module isn't able to import it:
import { factorial } from "https://gist.githubusercontent.com/DanielRamosAcosta/ad514503b1c7cf8290dadb96a5fddee9/raw/4733e267f05d20110ba962c4418bab5e98abfe93/factorial.ts"
console.log(factorial(10)) When executing I'm having the following error:
Deno version:
Any ideas? |
@DanielRamosAcosta I was unable to repeat the error - it works for me.... I'm not sure what's happening |
@ry I am trying to run this example from https://deno.land/: import { serve } from "https://deno.land/x/http/server.ts";
const s = serve("0.0.0.0:8000");
async function main() {
for await (const req of s) {
req.respond({ body: new TextEncoder().encode("Hello World\n") });
}
}
main(); Then I got this error:
I guess you can reproduce this error after clearing the cache directory. |
@johnsoncodehk Please try:
Edit: Actually this will work too:
but we should prefer and specifying the version in the url. |
@hayd Yes, it works, thank you! |
The following
main.ts
bar.ts
In the second example, foo.ts ends up resolving to "$HOME/.deno/deps/example.com/foo.ts" instead of the expected "https://example.com/foo.ts".
The text was updated successfully, but these errors were encountered: