-
Notifications
You must be signed in to change notification settings - Fork 24
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 bundle doesn't work on mod.ts #39
Comments
I don't think this is an issue for this library. I think it would be great if you would open this issue in the deno repo. |
Currently djwt can not be bundled. Libraries bundling is a common and widely used Deno feature. I agree it might not be an issue with the djwt library itself, but an easy work around can be implemented, see the suggested fix above. I think bundle doesn't work well with circular dependencies. I will definitely submit an issue with Deno itself. But just food for thought, is _deps.ts really needed for djwt? If you strongly believe that it does, I'd like to understands what are the benefits so the broken Deno bundle of djwt library can be justified. |
Deno bundle command doesn't error out but the bundled code doesn't contain the implementation for convertUint8ArrayToHex which is essentially encodeToString function from "https://deno.land/[email protected]/encoding/hex.ts" that's how issue manifests itself:
|
Just started with Deno, so not sure if I can provide much insight, but I am receiving the error:
when running |
What exactly do I have to do in order to replicate this? |
@timonson I've put together a quick test, follow the readme steps to reproduce https://github.com/alexanderGalushka/djwt_test |
i.e. import { create } from 'https://deno.land/[email protected]/djwt/mod.ts'; Then running deno run test.ts results in the error
|
@bicarlsen it seems you are using a wrong url. Try this one: https://deno.land/x/[email protected]/mod.ts |
Great! That resolved the loading issue. Just a heads up, that URL was copied from the README on the deno.land page. |
@timonson were you be able to reproduce |
Yes I was and it seems to be a |
totally |
warning: Compiled module not found "https://deno.land/x/[email protected]/mod.ts" |
Hi @BayoKwendo , this seems to be a |
Hi @alexanderGalushka , I believe this issue has been fixed now or am I wrong? |
I just upgraded to deno v1.5.4, would like to test it out
getting the following error:
@timonson can u please try to bundle as well to confirm |
I tried your test out before I asked the question and it worked for me. |
@timonson seems to be working |
tried deno 1.5.1 all the way down to 1.0.0 - no luck
getting rid of _deps.ts and putting decodeString and encodeToString directly from deno encoding lib for each module _signature.ts and mod.ts make the bundle work fine
The text was updated successfully, but these errors were encountered: