keybase / keybase-issues

A single repo for managing publicly recognized issues with the keybase client, installer, and website.
902 stars 37 forks source link

Cannot find module 'sodium' from 'keybase-nacl/lib' #2291

Open iamolivinius opened 8 years ago

iamolivinius commented 8 years ago

I'm trying to use kbpgp as a module in our js application. Therefor I installed kbpgp via:

npm install kbpgp

To build the application I use the browserify cli

browserify index.js

index.js looks like

var kbpgp = require('kbpgp')

After waiting a few seconds browserify exits with the following failure:

Error: Cannot find module 'sodium' from '/home/USER1/Documents/test/node_modules/keybase-nacl/lib'
    at /home/USER1/.npm-packages/lib/node_modules/browserify/node_modules/resolve/lib/async.js:46:17
    at process (/home/USER1/.npm-packages/lib/node_modules/browserify/node_modules/resolve/lib/async.js:173:43)
    at ondir (/home/USER1/.npm-packages/lib/node_modules/browserify/node_modules/resolve/lib/async.js:188:17)
    at load (/home/USER1/.npm-packages/lib/node_modules/browserify/node_modules/resolve/lib/async.js:69:43)
    at onex (/home/USER1/.npm-packages/lib/node_modules/browserify/node_modules/resolve/lib/async.js:92:31)
    at /home/USER1/.npm-packages/lib/node_modules/browserify/node_modules/resolve/lib/async.js:22:47
    at FSReqWrap.oncomplete (fs.js:117:15)

➜  test node -v
v6.2.1
➜  test npm -v
3.9.3
maxtaco commented 8 years ago

Should be fixed in keybase-nacl@1.0.4 (see https://github.com/keybase/node-nacl/commit/f1aee92a6003388a4b6e3a86b168041cda24eb43)

maxtaco commented 8 years ago

Thanks for the bug report...

elrondshep commented 3 years ago

I'm still getting this. I'm using kbpgp 2.1.15. I even tried bringing in keybase-nacl 1.1.3 directly. I removes it sense it should be handled by kbpgp. Any thoughts on how to get past this?