I've just upgraded to the new version of Appcelerator Studio and now when I try to start it I get an error.
When I start the app I'm asked for my email and password and after entering credentials I get the following error message:
Login Error
module.js:327
throw err;
^
Error: Cannot find module 'fstream'
at Function.Module._resolveFilename (module.js:325:15)
at Function.Module._load (module.js:276:25)
at Module.require (module.js:353:17)
at require (internal/module.js:12:17)
at Object.<anonymous> (/usr/local/node_modules/appcelerator/node_modules/tar/lib/entry.js:14:15)
at Module._compile (module.js:387:26)
at Object.Module._extensions.js (module.js:404:10)
at Module.load (module.js:343:32)
at Function.Module._load (module.js:300:12)
at Module.require (module.js:353:17)
I've also tried downloading setup from the site and reinstalling - didn't help.
I'm running on MAC OS X.
I've had this as well, thought it was some kind of an issue at my system, but I'll report it.
You can resolve this by reinstalling the Appcelerator CLI:
sudo npm i -g appcelerator
appc use 5.2.0 --force
I tried to reinstall cli and got this:
Annas-iMac:bin annakozy$ sudo npm i -g appcelerator
Password:
npm WARN install:object-assign ENOENT: no such file or directory, rename '/usr/local/etc/lib/node_modules/appcelerator/node_modules/got/node_modules/object-assign' -> '/usr/local/etc/lib/node_modules/appcelerator/node_modules/got/node_modules/object-assign'
npm WARN install:ansi-regex ENOENT: no such file or directory, rename '/usr/local/etc/lib/node_modules/appcelerator/node_modules/update-notifier/node_modules/ansi-regex' -> '/usr/local/etc/lib/node_modules/appcelerator/node_modules/update-notifier/node_modules/ansi-regex'
npm WARN install:ansi-styles ENOENT: no such file or directory, rename '/usr/local/etc/lib/node_modules/appcelerator/node_modules/update-notifier/node_modules/ansi-styles' -> '/usr/local/etc/lib/node_modules/appcelerator/node_modules/update-notifier/node_modules/ansi-styles'
npm WARN install:supports-color ENOENT: no such file or directory, rename '/usr/local/etc/lib/node_modules/appcelerator/node_modules/update-notifier/node_modules/supports-color' -> '/usr/local/etc/lib/node_modules/appcelerator/node_modules/update-notifier/node_modules/supports-color' object-assign#3.0.0 node_modules/appcelerator/node_modules/got/node_modules/object-assign -> node_modules/appcelerator/node_modules/got/node_modules/object-assign ansi-regex#2.0.0 node_modules/appcelerator/node_modules/update-notifier/node_modules/ansi-regex -> node_modules/appcelerator/node_modules/update-notifier/node_modules/ansi-regex ansi-styles#2.2.0 node_modules/appcelerator/node_modules/update-notifier/node_modules/ansi-styles -> node_modules/appcelerator/node_modules/update-notifier/node_modules/ansi-styles has-ansi#2.0.0 node_modules/appcelerator/node_modules/update-notifier/node_modules/has-ansi -> node_modules/appcelerator/node_modules/update-notifier/node_modules/has-ansi strip-ansi#3.0.1 node_modules/appcelerator/node_modules/update-notifier/node_modules/strip-ansi -> node_modules/appcelerator/node_modules/update-notifier/node_modules/strip-ansi supports-color#2.0.0 node_modules/appcelerator/node_modules/update-notifier/node_modules/supports-color -> node_modules/appcelerator/node_modules/update-notifier/node_modules/supports-color chalk#1.1.1 node_modules/appcelerator/node_modules/update-notifier/node_modules/chalk -> node_modules/appcelerator/node_modules/update-notifier/node_modules/chalk - /usr/local/etc/lib/node_modules/appcelerator/node_modules/update-notifier node_modules/appcelerator/node_modules/update-notifier /usr/local/etc/lib └── (empty)
npm ERR! code 1
Related
I'm unable to install strapi. When I run the quickstart, it gives an error about not being able to find "sharp".
I tried downgrading node - from 16.x.x to 14.18.1, and I get fewer warnings, but still threw the same error.
OS: Windows
Node: 14.18.1
NPM: 6.14.15
❯ npx create-strapi-app jeffsdata-cms --quickstart 401ms user
npx: installed 146 in 13.315s
Creating a quickstart project.
Creating a new Strapi application at C:\Users\user\source\repos\jeffsdata-strapi\jeffsdata-cms.
Creating files.
Dependencies installed successfully.
Your application was created at C:\Users\user\source\repos\jeffsdata-strapi\jeffsdata-cms.
Available commands in your project:
npm run develop
Start Strapi in watch mode.
npm run start
Start Strapi without watch mode.
npm run build
Build Strapi admin panel.
npm run strapi
Display all available commands.
You can start by doing:
cd C:\Users\user\source\repos\jeffsdata-strapi\jeffsdata-cms
npm run develop
> jeffsdata-cms#0.1.0 build
> strapi build "--no-optimization"
Building your admin UI with development configuration ...
√ Webpack
Compiled successfully in 34.99s
Running your Strapi application.
> jeffsdata-cms#0.1.0 develop
> strapi develop
[2021-11-26T15:48:12.185Z] debug ⛔️ Server wasn't able to start properly.
[2021-11-26T15:48:12.186Z] error Error:
Something went wrong installing the "sharp" module
Cannot find module '../build/Release/sharp.node'
Require stack:
- C:\Users\user\source\repos\jeffsdata-strapi\jeffsdata-cms\node_modules\sharp\lib\constructor.js
- C:\Users\user\source\repos\jeffsdata-strapi\jeffsdata-cms\node_modules\sharp\lib\index.js
- C:\Users\user\source\repos\jeffsdata-strapi\jeffsdata-cms\node_modules\strapi-plugin-upload\services\image-manipulation.js
- C:\Users\user\source\repos\jeffsdata-strapi\jeffsdata-cms\node_modules\strapi\lib\load\load-files.js
- C:\Users\user\source\repos\jeffsdata-strapi\jeffsdata-cms\node_modules\strapi\lib\core\load-apis.js
- C:\Users\user\source\repos\jeffsdata-strapi\jeffsdata-cms\node_modules\strapi\lib\core\load-modules.js
- C:\Users\user\source\repos\jeffsdata-strapi\jeffsdata-cms\node_modules\strapi\lib\Strapi.js
- C:\Users\user\source\repos\jeffsdata-strapi\jeffsdata-cms\node_modules\strapi\lib\index.js
- C:\Users\user\source\repos\jeffsdata-strapi\jeffsdata-cms\node_modules\strapi\lib\commands\develop.js
- C:\Users\user\source\repos\jeffsdata-strapi\jeffsdata-cms\node_modules\strapi\bin\strapi.js
- Remove the "node_modules/sharp" directory then run
"npm install --ignore-scripts=false --verbose sharp" and look for errors
- Consult the installation documentation at https://sharp.pixelplumbing.com/install
- Search for this error at https://github.com/lovell/sharp/issues
at Object.<anonymous> (C:\Users\user\source\repos\jeffsdata-strapi\jeffsdata-cms\node_modules\sharp\lib\constructor.js:32:9)
at Module._compile (internal/modules/cjs/loader.js:1085:14)
at Object.Module._extensions..js (internal/modules/cjs/loader.js:1114:10)
at Module.load (internal/modules/cjs/loader.js:950:32)
at Function.Module._load (internal/modules/cjs/loader.js:790:12)
at Module.require (internal/modules/cjs/loader.js:974:19)
at require (internal/modules/cjs/helpers.js:93:18)
at Object.<anonymous> (C:\Users\user\source\repos\jeffsdata-strapi\jeffsdata-cms\node_modules\sharp\lib\index.js:3:15)
at Module._compile (internal/modules/cjs/loader.js:1085:14)
at Object.Module._extensions..js (internal/modules/cjs/loader.js:1114:10)
I tried to delete the sharp folder and reinstall while on node 16, but that didn't fix this issue.
I tried to reinstall sharp on 14.18.1, but got a different error.
Downgrade node to 14.18.1 (windows: control panel, remove node, then download 14.18.1 (or whatever the most recent one, if it upgrades) from here).
Run the quickstart command npx create-strapi-app jeffsdata-cms --quickstart
Still throws the error complaining about sharp.
Delete the npm_modules/sharp folder
Reinstall sharp with npm install --ignore-scripts=false --verbose sharp.
Confirm it's working with node run develop.
This didn't fix the issue for me - now it just throws another error:
❯ node run develop 1m 34.989s user
internal/modules/cjs/loader.js:905
throw err;
^
Error: Cannot find module 'C:\Users\user\source\repos\jeffsdata-strapi\jeffsdata-cms\run'
at Function.Module._resolveFilename (internal/modules/cjs/loader.js:902:15)
at Function.Module._load (internal/modules/cjs/loader.js:746:27)
at Function.executeUserEntryPoint [as runMain] (internal/modules/run_main.js:76:12)
at internal/main/run_main_module.js:17:47 {
code: 'MODULE_NOT_FOUND',
requireStack: []
}
I next tried to roll back to Node 16 and use the beta...
Uninstall Node 14
Install Node 16
Install strapi beta - npm install strapi#beta -g
Create new project: strapi new jeffsdata-cms --quickstart
Now I get this error...
❯ strapi develop
4.469s user
[2021-11-26T16:58:19.646Z] error The client `sqlite3` is not installed.
[2021-11-26T16:58:19.647Z] error You can install it with `$ npm install sqlite3 --save`.
So, I obviously install sqlite3 - npm install sqlite3 --save, but it doesn't change the error.
So, I try running strapi build, then strapi develop... Same error - "The client sqlite3 is not installed."
My Keystone.js 4 project using Node 10.15 is failing to start on Heroku:
Error: Cannot find module './lib/core/importer'
at Function.Module._resolveFilename (internal/modules/cjs/loader.js:581:15)
at Function.Module._load (internal/modules/cjs/loader.js:507:25)
at Module.require (internal/modules/cjs/loader.js:637:17)
at require (internal/modules/cjs/helpers.js:22:18)
at Object.<anonymous> (/app/node_modules/keystone/index.js:6:16)
at Module._compile (internal/modules/cjs/loader.js:689:30)
at Object.Module._extensions..js (internal/modules/cjs/loader.js:700:10)
at Module.load (internal/modules/cjs/loader.js:599:32)
at tryModuleLoad (internal/modules/cjs/loader.js:538:12)
at Function.Module._load (internal/modules/cjs/loader.js:530:3)
Process exited with status 1
State changed from crashed to starting
Starting process with command `node ./dist/keystone.js`
State changed from starting to crashed
Process exited with status 1
internal/modules/cjs/loader.js:583
throw err;
I have other Keystone applications configured in exactly the same way that run correctly.
I have tried disabling the build cache, creating a new application instance to deploy to and have verified through the Heroku console that the file in question does exist in the source.
The project builds and runs correctly in Windows 10 and *nix environments locally.
What can I do to debug this?
So it seems the problem is due to npm 6.5.x not installing all of Keystone's dependencies. Switching to Yarn as the package manager fixes this.
I installed the latest version of Yarn, 1.13.0 as of now.
Installed dependencies via yarn
Committed the yarn.lock file
Specified "yarn": "1.13.0" in the "engines" section of my package.json and removed "npm" from the engines.
Re-deployed to Heroku and it works as expected.
Hope this helps someone!
I'm getting this error while trying to build my electron app using electron-builder on Mac with code signing. Identity is properly set on keychain.
Error: Command failed: codesign --sign Company Name --force /Users/nterms/Projects/my-app/dist/mac/MyApp.app/Contents/Resources/app.asar.unpacked/node_modules/electron-prebuilt/dist/Electron.app/Contents/Frameworks/Electron Framework.framework
/Users/nterms/Projects/my-app/dist/mac/MyApp.app/Contents/Resources/app.asar.unpacked/node_modules/electron-prebuilt/dist/Electron.app/Contents/Frameworks/Electron Framework.framework: bundle format unrecognized, invalid, or unsuitable
at ChildProcess.exithandler (child_process.js:213:12)
at emitTwo (events.js:87:13)
at ChildProcess.emit (events.js:172:7)
at maybeClose (internal/child_process.js:827:16)
at Socket.<anonymous> (internal/child_process.js:319:11)
at emitOne (events.js:77:13)
at Socket.emit (events.js:169:7)
at Pipe._onclose (net.js:477:12)
From previous event:
at tsAwaiter (/Users/nterms/Projects/my-app/node_modules/electron-builder/src/util/awaiter.ts:10:47)
at MacPackager.sign (/Users/nterms/Projects/my-app/node_modules/electron-builder/src/macPackager.ts:100:75)
at /Users/saranga/Projects/my-app/node_modules/electron-builder/src/macPackager.ts:80:26
From previous event:
at MacPackager.<anonymous> (/Users/nterms/Projects/my-app/node_modules/electron-builder/src/macPackager.ts:80:10)
at next (native)
From previous event:
at tsAwaiter (/Users/nterms/Projects/my-app/node_modules/electron-builder/src/util/awaiter.ts:10:47)
at Object.build (/Users/nterms/Projects/my-app/node_modules/electron-builder/src/builder.ts:195:52)
at Object.<anonymous> (/Users/nterms/Projects/my-app/node_modules/electron-builder/src/build-cli.ts:27:28)
at Module._compile (module.js:409:26)
at Object.Module._extensions..js (module.js:416:10)
at Module.load (module.js:343:32)
at Function.Module._load (module.js:300:12)
at Function.Module.runMain (module.js:441:10)
at startup (node.js:139:18)
at node.js:968:3
However the building smoothly goes on the same app when packaging without code signing.
I'm on a Mac with OSX El Captain (10.11.6) and XCode is updated to the latest version.
Any help is greatly appreciated.
Ok, I found the issue and get it solved. Posting it here so that it will help someone else who has the same issue.
Error was raised due to electron-prebuilt was installed in the production node_modules folder. It should only be installed in development modules.
I removed the electron-prebuilt from production modules and it works fine now.
After updating cordova to version 4.3.0 the command:
cordova build
returns the following error:
module.js:340
throw err;
^
Error: Cannot find module 'Q'
at Function.Module._resolveFilename (module.js:338:15)
at Function.Module._load (module.js:280:25)
at Module.require (module.js:364:17)
at require (module.js:380:17)
at Object.<anonymous> (/Volumes/CaseSensitive/ios_projects/_Tests/testGruntCordova/testGruntCordova/platforms/ios/cordova/lib/check_reqs.js:25:13)
at Module._compile (module.js:456:26)
at Object.Module._extensions..js (module.js:474:10)
at Module.load (module.js:356:32)
at Function.Module._load (module.js:312:12)
at Module.require (module.js:364:17)
ERROR building one of the platforms: Error: /Volumes/CaseSensitive/ios_projects/_Tests/testGruntCordova/testGruntCordova/platforms/ios/cordova/build: Command failed with exit code 8
You may not have the required environment or OS to build this project
Error: /Volumes/CaseSensitive/ios_projects/_Tests/testGruntCordova/testGruntCordova/platforms/ios/cordova/build: Command failed with exit code 8
at ChildProcess.whenDone (/usr/local/lib/node_modules/cordova/node_modules/cordova-lib/src/cordova/superspawn.js:131:23)
at ChildProcess.EventEmitter.emit (events.js:98:17)
at maybeClose (child_process.js:753:16)
at Process.ChildProcess._handle.onexit (child_process.js:820:5)
I have already tried to remove and add the platform ios but nothing changes.
I have tried to run:
sudo npm install -g cordova / sudo npm install cordova
sudo npm install -g Q / sudo npm install Q
but nothing changes.
Any help?
Thank you very much
There was a bug and I have released a patch to it:
Apache Cordova ios - Git Repository
This is a bug shown on case-sensitive systems such as Unix, Linux and some OS X (if set as case-sensitive).
So far, to fix it, you have to locate those files containing a line like this:
Q = require('Q')
You can locate the files while standing on your project directory using grep:
grep -HnrI "require('Q" *;
then, use any text editor to manually change the mentioned line to:
Q = require('q')
Alternatively you can edit the related files on a more straight forward way by running the following command on your project directory:
grep -rl "require('Q" * | xargs sed -i "" "s/'Q'/'q'/g";
The single line above searches and edits the files that need the change.
Removing and then re-adding the platform again also works:
cordova platform remove ios
cordova platform add ios
Now you can cordova build ios :)
As mentioned by MeV this was a bug.
I tried to install howtonode.org on my Osx
cd ~/Sites/
git clone git#github.com:creationix/howtonode.org
My context is the following:
OSx version: 10.7.4
node -v v0.6.15
When I try to run the following command
~/Sites/howtonode.org node server/server.js &
I get the following error:
node.js:201
throw e; // process.nextTick error, or 'error' event on first tick
^
Error: Cannot find module 'stack'
at Function._resolveFilename (module.js:332:11)
at Function._load (module.js:279:25)
at Module.require (module.js:354:17)
at require (module.js:370:17)
at Object.<anonymous> (/Users/antoniopierro/Sites/howtonode.org/server/server.js:2:13)
at Module._compile (module.js:441:26)
at Object..js (module.js:459:10)
at Module.load (module.js:348:31)
at Function._load (module.js:308:12)
at Array.0 (module.js:479:10)
[1]+ Exit 1 node server/server.js
any ideas?
Try running node ~/Sites/howtonode.org/server/server.js & or go to ~/Sites/howtonode.org/server/ and runnode server
Also, you have not installed the dependencies from package.json.
Go to ~/Sites/howtonode.org/ and type inn npm install. This will install all the dependencies in ~/Sites/howtonode.org/node_modules. You can then run the server.