Cannot find where you keep your Bower packages. (Ionic Framework) - node.js

I'm stuck.
I tried almost everything. From reinstalling, updating and installing in a different order.
First I used:
$ bower install
Everything went great so far, but at the end I got this:
bower date.format#~1.2.3 ECMDERR Failed to execute "git ls-remote --tags --heads https://github.com/tiger-seo/date.format.git",
exit code of #128 fatal: unable to access 'https://github.com/tiger-seo/date.format.git/': Server aborted the SSL handshake
Additional error details:
fatal: unable to access 'https://github.com/tiger-seo/date.format.git/': Server aborted the SSL handshake
I ignored that (don't know if it's necessary) and build the Node Packages with
$ npm install
and got this:
Running "wiredep:app" (wiredep) task
Warning: Error: Cannot find where you keep your Bower packages. Use --force to continue.
Aborted due to warnings.
The npm-debug.log can you find here: https://www.dropbox.com/s/istqfl11xulkod9/npm-debug.log?dl=0
My installed versions:
Bower: 1.8.0
npm: 3.10.10
node: v6.11.0
Ionic: 3.3.0
Cordova: 7.0.1

Related

How do I install gRPC for electron version 4.0.x

Installed electron#4.0.0 (also tried #4.0.7) and installed grpc and #grpc/proto-loader. When I launch electron I get a runtime error
Uncaught Error: Failed to load gRPC binary module because it was not installed for the current system
Expected directory: electron-v4.0-darwin-x64-unknown
Found: [node-v64-darwin-x64-unknown]
This problem can often be fixed by running "npm rebuild" on the current system
Of course I tried running the suggested solution, npm rebuild, but that did not solve the problem. I also tried rebuilding the grpc module
npm rebuild grpc --build-from-source --runtime=electron --target=4.0.0 --target_archx64 --dturl=https://atom.io/download/electron
I tried uninstalling everything and starting from scratch. We're cloning the electron quick start repo and so after cloning and installing modules I installed grpc targeting a specific version
npm install grpc --runtime=electron --target=<electron version>
Which resulted in the same error so then I tried rebuilding
npm install --save-dev electron-rebuild // to rebuild grpc module
And if I delete node_modules and package-lock.json and then re-install npm install I get a success message (don't pay attention to the version, I'm watching my versions are matching) which looks like the "missing" module was installed
node-pre-gyp WARN Using request for node-pre-gyp https download
[grpc]
Success: "/../electron/node_modules/grpc/src/node/extension_binary/node-v64-darwin-x64-unknown/grpc_node.node" is installed via remote
protobufjs#6.8.8 postinstall /../electron/node_modules/protobufjs
node scripts/postinstall
electron#4.0.8 postinstall /../electron/node_modules/electron
node install.js
I found the answer here:
https://github.com/grpc/grpc-node/issues/762
Still, the solution I tried is the solution I needed. Not sure what I was doing wrong initially!
For future Googlers the summary is this:
The grpc_node module seems to be compiled for NODE_MODULE_VERSION=64,
but Electron 4 since 4.0.4 switched ... to
specifying NODE_MODULE_VERSION=69 and there is a mismatch at runtime
trying to load the module.
So, what I did to solve was
Clone the electron quick start repo
Uninstall the version of electron that came with quick start
Install electron#4.0.0
Install gRPC with target to 4.0.0
npm install grpc --runtime=electron --target=4.0.0

NPM module not found grunt sass

Local Npm module "grunt-sass" not found. Is it installed?
Running "serve" task
Running "clean:server" (clean) task
0 paths cleaned.
Running "generateConstantsFileWithConfig" task
Running "ngconstant:local" (ngconstant) task
Creating module config at app/res/config/config.js...OK
Running "wiredep:app" (wiredep) task
Warning: Error: Cannot find where you keep your Bower packages. Use --force to continue.
Aborted due to warnings.
To resolve any problem related with the npm module you could use: —unsafe-perm
when you are installing that module or package. For example if you have problems when you install bowel and node you could use:
sudo npm install --unsafe-perm && bower install —unsafe-perm
which solve the problem I had.

grunt-bower-task throws "Warning: Cannot find module 'bower' Use --force to continue."

When doing grunt bower:install grunt throws the following error
kaushiks-MacBook-Pro:ama ghost$ grunt bower:install
Running "bower:install" (bower) task
Warning: Cannot find module 'bower' Use --force to continue.
Aborted due to warnings.
kaushiks-MacBook-Pro:ama ghost$
I have tried npm install bower -g but still din't work. Please help.
You probably need Bower as a local dependency and not global. If you are using grunt-bower-task you should've downloaded Bower from its dependencies already - but since the error specifically says that it cannot find module bower you should install it locally in your project's root with npm install bower -D.
The -D option is shorthand for --save-dev which only installs the dependency if NODE_ENV environment variable is development, which it is by default.

Grunt serve "configureProxies:server" not found and "connect_proxy.js" error

I'm trying to run a http server using grunt. However, when I type grunt serve in the appropriate directory, I'm presented with the following errors:
Loading "connect_proxy.js" tasks...ERROR
>> TypeError: Cannot read property 'prototype' of undefined
Running "serve" task
Warning: Task "configureProxies:server" not found. Use --force to continue.
My nodejs, node package manager, and ruby installations are at the following versions:
npm -v
1.3.10
nodejs -v
v0.10.25
ruby -v
ruby 1.9.3p484 (2013-11-22 revision 43786) [x86_64-linux]
How do I get the missing dependency? I've tried this both on Windows 8 and on a fresh install of elementaryOS Freya. The exact same problem arises on both. Any ideas?
The problem was resolved by going into package.json and updating "grunt-connect-proxy" to ^0.2 to obtain the missing dependency.

ember-cli ember new ENOENT error

Fresh install on a Xubuntu desktop VM, fully updated, running ember new gets me this:
jrusso#ember:~$ ember new jossdo
version: 0.0.37
installing
create .bowerrc
create .jshintrc
create Brocfile.js
...
create tests/test-helper.js
create tests/unit/.gitkeep
create vendor/.gitkeep
Installing packages for tooling via npm...
npm ERR! registry error parsing json
stream.js:94
throw er; // Unhandled stream error in pipe.
^
Error: ENOENT, lstat '/home/jrusso/jossdo/node_modules/ember-cli/node_modules/leek/node_modules/request/node_modules/form-data/node_modules/async/lib/async.js'
at Error (native)
Here are versions of the software I'm using
jrusso#ember:~/jossdo$ git --version
git version 1.9.1
jrusso#ember:~/jossdo$ bower --version
1.3.5
jrusso#ember:~/jossdo$ nvm --version
0.7.0
jrusso#ember:~/jossdo$ npm --version
1.4.9
jrusso#ember:~/jossdo$ node --version
v0.11.13
jrusso#ember:~/jossdo$ phantomjs --version
1.9.7
jrusso#ember:~/jossdo$ uname -a
Linux ember 3.13.0-30-generic #54-Ubuntu SMP Mon Jun 9 22:45:01 UTC 2014 x86_64 x86_64 x86_64 GNU/Linux
Tried npm cache clear in home prior to ember new and got the same result. I had 0.0.35 working but I wanted to do a clean install of 0.0.37 so I cloned my virtualbox snapshot prior to installing any node software, followed the ember-cli gh-pages install procedure and this is what I got. Relatively new to ember.js, node and linux webdev so please go easy on me.
UPDATE
Not sure what the issue is here, but after trying a few subsequent ember new commands, it does seem to be working. My first subsequent run completed npm installs and bower installs though it had a few messages for me:
npm ERR! registry error parsing json
npm ERR! registry error parsing json
make: Entering directory `/home/jrusso/testrun/node_modules/ember-cli/node_modules/testem/node_modules/socket.io/node_modules/socket.io-client/node_modules/ws/build'
CXX(target) Release/obj.target/bufferutil/src/bufferutil.o
make: Leaving directory `/home/jrusso/testrun/node_modules/ember-cli/node_modules/testem/node_modules/socket.io/node_modules/socket.io-client/node_modules/ws/build'
Didn't run ember serve on that, but I rm -rf testrun and then ran ember new testrun again and this time I didn't get the npm ERR! messages but I still got the make messages.
Removed it again and tried ember new testrun --verbose and it appears that the NPM errors are sporadic and non-descriptive (the message doesn't contain any indication of which package.json it's unable to parse). I'll continue to update if I have any more issues with this.
Ha!
Just finished resolving the same issue.
Luckily I saw "you have not agreed to the Xcode license agreements...".
Ran:
sudo xcodebuild -license
Drop the sudo for user-level only.
I'd also updated npm.
Furthermore, I grabbed the latest Xcode command line tools.
Ran the command again for ember-cli global install. This time no issues. Tested to create a new site - all good.
Stef has some further tips for updating an ember-cli project here.

Resources