ember.js: Unable to set 'error' route on 2.10
Ember.js is setting the ‘error’ route by default, but route-recognizer does not allow duplicate routes anymore: https://github.com/tildeio/route-recognizer/blame/5d54688f04273d3a921470b903a36266dddcdaf2/dist/route-recognizer.js#L525-L531
Doing so will give you a blank page with an error in your console:
Uncaught Error: You may not add a duplicate route named `error`
Default ‘error’ routes are set here: https://github.com/emberjs/ember.js/blob/10857fd98008bb47bd63bfe3d21b0fc224a197a5/packages/ember-routing/lib/system/dsl.js#L49-L50
You can test it by trying to handle error route using ember g route error.
This functionality worked fine in 2.9 .
About this issue
- Original URL
- State: closed
- Created 8 years ago
- Reactions: 19
- Comments: 29 (14 by maintainers)
Fixed in 2.11.1
We hit this issue upgrading the Bustle app to 2.10, and we’ll need to either refactor our root
errorroute to be named differently or hold off upgrading to 2.10.Please report any issues you find with the beta cycle!
Yes, I think that is a good idea.
Thanks @locks, @rwjblue I can confirm it is working.
Is there a status on this guy?
That’s not the fix, @pixelhandler! That’s where the bug was introduced. 😜This does need a point release once fixed, but I have a few other things to address before I can get back to do the router things. (I’ve got about 5 open issues to address.)
Seems legit. This is by virtue of a
route-recognizerchange I made. Need to lock out the default creation if the user has already created one. (I know how to fix, will get to it.)