2

I've got ember-rails updated to master:

bundle update ember-rails
Updating git://github.com/emberjs/ember-rails.git
Fetching gem metadata from https://rubygems.org/.........
....
Using ember-rails (0.11.1) from git://github.com/emberjs/ember-rails.git (at master) 
....
Your bundle is updated!

I'd like to use the latest ember-data revision (12), but every time I update my app's store revision number to 12, i.e.:

App.Store = DS.Store.extend({
  revision: 12,
  adapter: App.Adapter.create()
});

I see the following error message:

Uncaught Error: Error: The Ember Data library has had breaking API changes since the last time you updated the library. Please review the list of breaking changes at https://github.com/emberjs/data/blob/master/BREAKING_CHANGES.md, then update your store's `revision` property to 11

...and when I check out DS.CURRENT_API_REVISION it's 11:

console.log(DS.CURRENT_API_REVISION); // 11

Is there a way to get the gem to pull in revision 12, or do I have to build ember-data myself and override the included version?

benburton
  • 153
  • 7

2 Answers2

2

benburton's solution works for what is asked for, but in the latest ember-data it uses an internal method 'readOnly' that was only added to in ember RC2.

Therefore, you need the latest ember in order to run the latest ember-data. The full solution is to simply disregard the second line of your solution, leaving the following:

rails generate ember:install --head
Community
  • 1
  • 1
Jeffrey Biles
  • 988
  • 7
  • 24
1

I ended up using ember-rails to generate ember+ember-data and then removing the updated version of Ember like so:

rails generate ember:install --head
rm vendor/assets/ember/development/ember.js vendor/assets/ember/production/ember.js
benburton
  • 153
  • 7