-
Notifications
You must be signed in to change notification settings - Fork 126
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
Add argon2 compatibility with vercel #183
Comments
@nohren can you share a direct replication of the issue? Is it as simple as |
It is as simple as require('argon2') |
Thanks, I was able to reproduce.
We had a special case for argon2 but looks like the directory changed nft/src/utils/special-cases.ts Lines 14 to 19 in 3c179ef
|
Fixed in the latest nft and will be fixed for node deployments here: vercel/vercel#6211 |
FYI, this is broken again now, as the main index file is now called argon2/argon2.cjs in 0.40.x. Is there any way to add our own manual exclusions and handling of dependencies in our projects? My workaround at the moment is to use an older version, 0.31.x, where the file is called argon2.js and not argon2.cjs :) |
Feel free to create a PR and I'll take a look
|
Using argon2@0.27.2
Depoying this to vercel gives a an error in the serverless function tab saying cannot find or reference node module argon 2.
https://vercel.com/support/articles/why-does-my-serverless-function-work-locally-but-not-when-deployed.
Based off this article, I believe the issue is due to argon2 native node-gyp requiring libraries. And it seems vercel cannot support native to node / node to native compiling.
Only solution I see is if argon2 authors create an argon2js or javascript version with 0 dependencies like bcryptjs or vercel changes something about their network but me thinks vercel cannot do that by design with this serverless architecture.
Argon2 is the best open source cryptography available for those wanting to manually hash their own passwords. And vercel network is the best for rapid development and hands free deployment. It would be great if they could get along.
The text was updated successfully, but these errors were encountered: