When running: "curl -sL https://appwrite.io/cli/install.sh | bash" I get an error when running appwrite -v:
throw error;
^
Error: Cannot find module '/snapshot/sdk-for-cli/node_modules/axios/dist/node/axios.cjs'
1) If you want to compile the package/file into executable, please pay attention to compilation warnings and specify a literal in 'require' call. 2) If you don't want to compile the package/file into executable and want to 'require' it from filesystem (likely plugin), specify an absolute path in 'require' call using process.cwd() or process.execPath.
at createEsmNotFoundErr (node:internal/modules/cjs/loader:960:15)
at finalizeEsmResolution (node:internal/modules/cjs/loader:953:15)
at resolveExports (node:internal/modules/cjs/loader:482:14)
at Function.Module._findPath (node:internal/modules/cjs/loader:522:31)
at Function.Module._resolveFilename (node:internal/modules/cjs/loader:919:27)
at Function._resolveFilename (pkg/prelude/bootstrap.js:1819:46)
at Function.Module._load (node:internal/modules/cjs/loader:778:27)
at Module.require (node:internal/modules/cjs/loader:1005:19)
at Module.require (pkg/prelude/bootstrap.js:1719:31)
at require (node:internal/modules/cjs/helpers:102:18) {
code: 'MODULE_NOT_FOUND',
path: '/snapshot/sdk-for-cli/node_modules/axios/package.json',
pkg: true
}
Seems to work perfectly fine for me. This was a fresh install though
Maybe try uninstalling the old CLI?
rm -f /usr/local/bin/appwrite | bash
then run
curl -sL https://appwrite.io/cli/install.sh | bash
Hmm uninstalling it does not seem to help. Also tried with npm.. Gives this error when doing appwrite -v:
if (data[key]?.constructor?.name === 'BigNumber') {
^
SyntaxError: Unexpected token '.'
at wrapSafe (internal/modules/cjs/loader.js:915:16)
at Module._compile (internal/modules/cjs/loader.js:963:27)
at Object.Module._extensions..js (internal/modules/cjs/loader.js:1027:10)
at Module.load (internal/modules/cjs/loader.js:863:32)
at Function.Module._load (internal/modules/cjs/loader.js:708:14)
at Module.require (internal/modules/cjs/loader.js:887:19)
at require (internal/modules/cjs/helpers.js:74:18)
at Object.<anonymous> (/usr/local/lib/node_modules/appwrite-cli/index.js:11:44)
at Module._compile (internal/modules/cjs/loader.js:999:30)
at Object.Module._extensions..js (internal/modules/cjs/loader.js:1027:10)
It works fine when installing version 2.0.2, by creating the script locally and replacing 4.0.0 with 2.0.2
Did you do appwrite -v?
ah yes I get the same error in this
Yea, it installs fine, but throws the error when used
what version of node?
16.17.0
FYI, it's best to wrap code in backticks to format a bit nicer. You can use 1 backtick for inline code (https://www.markdownguide.org/basic-syntax/#code) and 3 backticks for multiline code (https://www.markdownguide.org/extended-syntax/#syntax-highlighting.
here's an issue: https://github.com/appwrite/sdk-for-cli/issues/95
something might be weird with your docker version...i would only expect this error on older versiosn of node
looks like you get the error if you're on node 12
Noted
Oh. Thats my bad. I accidently checked the node version of my local pc. It seems that the ubuntu server runs on node 12.22.9. I will update and check soon.
After updating to node version 16.20.2, i still get the same error when trying to use the appwrite CLI 4.0.0
It seems to work fine when installing globally through npm and executing with npx. Guess i can just do that instead.
Same issue here(Windows): https://discord.com/channels/564160730845151244/1149984724547276901
for me, npm install -g appwrite-cli
thrown some permission errors. so had to do sudo npm install -g appwrite-cli
and then it worked fine.
OS: Ubuntu Linux Node: v19.9.0
[SOLVED] Appwrite CLI linux not working
Recommended threads
- Admin Impersonating Clients?
I have a client that needs to use the admin User, to impersonate the Clients in order to debug better the App and the services that they are providing, could yo...
- create project api-rest
Hello good afternoon, I'm developing a project where I need to create a project by apirest, but I'm stuck with this "projects.read" permission, can I change my ...
- Twillio config in Appwrite (sms config r...
Hellow , can I succesfully notify users through sms with the Twillio service through Appwrite without a Sender number from Twillio ?? i don t have that on my ...