missing template processor ember - ember.js

Very new on using ember (and a js framework in general)
i'm following the official guide on the ember site, installed the ember-cli and create a test app but when i 'server' it a get this message:
Missing template processor
Error: Missing template processor
at module.exports.preprocessTemplates C:\Users\vittorio\AppData\Roaming\npm \node_modules\ember-cli\lib\preprocessors.js:164:11)
at EmberApp._processedTemplatesTree (C:\Users\vittorio\AppData\Roaming\npm\node_modules\ember-cli\lib\broccoli\ember-app.js:567:10)
at EmberApp.appAndDependencies (C:\Users\vittorio\AppData\Roaming\npm\node_modules\ember-cli\lib\broccoli\ember-app.js:808:24)
at EmberApp.javascript (C:\Users\vittorio\AppData\Roaming\npm\node_modules\ember-cli\lib\broccoli\ember-app.js:882:34)
at EmberApp.toArray (C:\Users\vittorio\AppData\Roaming\npm\node_modules\ember-cli\lib\broccoli\ember-app.js:1248:10)
at EmberApp.toTree (C:\Users\vittorio\AppData\Roaming\npm\node_modules\ember-cli\lib\broccoli\ember-app.js:1270:30)
at Object.<anonymous> (e:\web\apps\test_ember\Brocfile.js:20:22)
at Module._compile (module.js:460:26)
at Object.Module._extensions..js (module.js:478:10)
at Module.load (module.js:355:32)
I could not find easy enough info for a beginner and i'm just stuck.
Some info about my environment on windows 7:
$ ember --version
version: 0.2.3
node: 0.12.0
npm: 2.7.6

I case anyone else is getting the same error when trying "ember server" command and the solution above doesn't work (didn't work for me). I realized I had to run:
npm install
bower install
before running the server; after doing this I was able to run "ember server" and worked good.

ember-cli projects can be finicky about its module versions. Try to update your package caches and reinstall ember-cli:
bower cache clean && npm cache clean && npm install -g ember-cli

Related

Ember 2.7.2 and ember-models-table: A helper named "models-table" could not be found

I install Ember 2.7.2 and I create my first application. I install the addon ember-models-table (ember install ember-models-table).
Template:
<h3>Prueba</h3>
{{models-table
data=model
columns=columns}}
I use "ember server" to test my app. When I go to http://localhost:4200/prueba I see this error in console:
Uncaught Error: Assertion Failed: A helper named "models-table" could not be found
Any idea of what is wrong?
Maybe you didn't install this addon correctly for some reason. All I can recommend you is to re-install it by typing these commands:
npm uninstall --save ember-models-table
npm prune
rm -rf node_modules tmp
npm cache clean
npm install
ember install ember-models-table
If the problem still exists after you re-install the addon, probably something is wrong with your environment, not the ember itself.

Error while creating new ember application using ember-cli

I installed ember-cli tools, When i tried to create a new application using ember new book-app i get the following error
installing app
......
create tests/unit/.gitkeep
create vendor/.gitkeep
Successfully initialized git.
Installed packages for tooling via npm.
Error creating new application. Removing generated directory `./book-app`
Package ember not found
Error: Package ember not found
at createError (/usr/local/lib/node_modules/ember-cli/node_modules/bower/lib/util/createError.js:4:15)
at /usr/local/lib/node_modules/ember-cli/node_modules/bower/lib/core/resolverFactory.js:206:23
at _fulfilled (/usr/local/lib/node_modules/ember-cli/node_modules/bower/lib/node_modules/q/q.js:834:54)
at self.promiseDispatch.done (/usr/local/lib/node_modules/ember-cli/node_modules/bower/lib/node_modules/q/q.js:863:30)
at Promise.promise.promiseDispatch (/usr/local/lib/node_modules/ember-cli/node_modules/bower/lib/node_modules/q/q.js:796:13)
at /usr/local/lib/node_modules/ember-cli/node_modules/bower/lib/node_modules/q/q.js:604:44
at runSingle (/usr/local/lib/node_modules/ember-cli/node_modules/bower/lib/node_modules/q/q.js:137:13)
at flush (/usr/local/lib/node_modules/ember-cli/node_modules/bower/lib/node_modules/q/q.js:125:13)
at nextTickCallbackWith0Args (node.js:419:9)
at process._tickCallback (node.js:348:13)
I am not sure what the problem is. I am using ember-cli 2.7.0
Since no answer was provided and I just ran in to this exact error. What worked for me was to reinstall bower.
npm rm -g bower
npm install bower -g

Ember-cli upgrade broke everything

I had a running Ember program built using Ember-Cli 1.13.12 using Node 4.2.4. I tried to upgrade to Ember-Cli 2.3.0 running on Node 4.2.6. I followed the procedure outlined in: https://github.com/ember-cli/ember-cli/releases. After the upgrade, my program generated all sorts of errors. I spent an entire day trying to get the program to work but couldn't. So I decided to try reverting back to Ember-cli 1.13.12. I checked out the lastest working version of my program before the upgrade attempt using git. I did the following to revert back to Ember-cli 1.13.12:
npm uninstall -g ember-cli
npm cache clean
bower cache clean
npm install -g ember-cli#1.13.12
rm -rf node_modules bower_components dist tmp
npm install
bower install
But the system still doesn't work. 'Ember Server' works as expected. But when I go to localhost:4200 in my browser, I get two errors:
Uncaught Error: Assertion Failed: Ember Views require jQuery between 1.7 and 2.1
Uncaught Error: Could not find module `ember` imported from `tw/app`
Can someone please help me figure out what's going on?
I think you're being hit by the problem in this post.
You can probably fix the issue by upgrading to ember-cli 1.13.14, if not check bellow.
For reference, the fix (if you're not updating ember-cli) is (from this answer by Lawree)
This is a bug due to a new version of jQuery. For now you can change
the following line in your bower.json file. Then run bower install and
it should work.
"jquery": "^1.11.3", to
"jquery": "1.11.3",

How do I update ember.js to version 2.0.1

I'm fairly new to ember.js
Before starting my project I wanted to upgrade my version to the latest 2.0.1 release.
I went through the steps in the guide.
sudo npm uninstall -g ember-cli
sudo npm cache clean
bower cache clean
sudo npm install -g ember-cli
typing: ember -v gives 1.13.8 just as it did before the 'update'
I can see that the ember-cli website says 1.13.8 is the latest version of ember-cli.
However since the emberjs.com site says the latest release is 2.0.1 and on the homepage the isntruction is to run npm install -g ember-cli I would expect the command
ember -v to return 2.0.1 if I was using the latest release.
I created a new ember project using ember new test and ran
grep -r 'version' * to see if there were any clues but found nothing of interest.
Looking at package.json reveals that ember-data 1.13.8 is one of the dependencies which is also not the latest version (2.0.0)
What (if any) is the difference between ember-cli and ember.js versions?
When I type ember -v the version of which program is being displayed?
If I'm not on the latest release, how can I get it installed?
I'm running ubuntu 14.04
The current version of Ember-cli installs Ember 1.13.8. You need to update your bower.json to use the 2.0.1 version of ember.
"dependencies": {
"ember": "2.0.1",
},
and then run bower install.

Error: Cannot find module 'socket.io/node_modules/redis' on Mac

I am trying to run this example (http://maxburstein.com/blog/realtime-django-using-nodejs-and-socketio/) but I'm getting this error:
module.js:340
throw err;
^
Error: Cannot find module 'socket.io/node_modules/redis'
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> (/Users/felipemoran/Desktop/django-realtime-tutorial-master/nodejs/chat.js:7: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 Function.Module.runMain (module.js:497:10)
What I did so far was:
Unpack the source files - ok
Start Redis server (by typing on terminal redis-server) - ok
Start Django server (by typing on a different window python manage.py runserver, while in the propper folder) - ok
The next step would be, on a third terminal window, run the command node chat.js, while in the folder nodejs folder from the example files, but I'm getting this error.
I'm on Mac OS X Maverics, I installed node.js from the official mac installer and I installed socket.io using the npm command.
I also tried running rpm install socket.io -g , rpm install -g socket.io, those two with sudo and runing these commands from the nodejs folder but still no success.
Thanks!
Running npm install socket.io installs the latest version from npm which is now 1.1.0. Your tutorial uses version 0.9 and a lot changed from that to 1.0, including how to use the Redis adapter. Since the tutorial does not use a package.json to manage the dependencies you ended up with wrong version.
You can either upgrade your server code to work with latest socket.io (for which you need to install socket.io-redis) or check the latest version from the 0.9 branch by running npm view socket.io versions and then install npm install socket.io#0.9.17.
And please remove the global installations, they will cause you gray hair later (npm uninstall -g socket.io).