New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Unable to set 'error' route on 2.10 #14650
Comments
@diamondo25 Can you reproduce in a Twiddle please? |
I'm seeing this as well and I don't recall seeing it in the most recent beta from yesterday |
Seems legit. This is by virtue of a |
Crosslinking: tildeio/route-recognizer#118 |
@nathanhammond thanks for fixing so quickly! @rwjblue I labeled as "Bug" perhaps this issue can be resolved with an upcoming 2.10.1 release. |
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.) |
Is there a status on this guy? |
We hit this issue upgrading the Bustle app to 2.10, and we'll need to either refactor our root |
We are also interested in the status of this bug. We are holding off from upgrading to 2.10 for the time being. |
I was hoping I could work around this by not explicitly registering the
I am thinking maybe I could leave the template, route, controller, etc. in place and register a custom error route pointing to the same template for my explicitly handled error cases. Maybe this would handle both the caught and uncaught errors with my custom template. @nathanhammond - Do you have any thoughts on the above? Worth the hackery or better to just wait on an official fix? |
Nevermind :( The above proposal would still require the I may just go with making the custom route for my handled errors and using my same error component in the Seems to be the only other approach pending a fix. CC: @nathanhammond |
I've noticed that this is fixed in ember v2.12.0-beta.1, is there any chance to get this fix backported to a 2.11 release? Since the 2.12 beta introduces a whole bunch of new issues. |
Please report any issues you find with the beta cycle!
Yes, I think that is a good idea. |
Fixed in 2.11.1 |
Was this fixed in a different way than beta.1? Just tried out 2.11.1 and that still gives me a duplicate route error about "hotel.error" while the beta doesn't. |
@Glennvd - Yes they are different versions of route-recognizer (0.2.9 for 2.11 and 0.3 for 2.12). It is possible that I mucked this up somehow. Can you share the error and stack trace you get with 2.11? Also, possible a twiddle and/or demo repo? I'm happy to release a 2.11.2 once we figure out what I did wrong.. |
@rwjblue I've got a twiddle here, just needs to be changed to the right ember version https://ember-twiddle.com/e4b8412bf5629483f94276a001598571 Full stacktrace (from my own app) below.
Error is still the same |
@rwjblue running grep --recursive "RouteRecognizer.VERSION" node_modules/ember-source returns
|
Yeah, the issue is that route-recognizer@0.2.9 was released with 0.2.8's dist output. I'm working on it... |
@rwjblue, Much appreciated sir. |
OK, I released route-recognizer@0.2.10 with the updated dist output, then bumped in the release branch (in 6c7e695), and confirmed in the build output (in components/ember@4a9c736). I then confirmed with the twiddle shared by @Glennvd above that when using If someone else can sanity check me here, I can release 2.11.2... |
On it. |
@rwjblue forgive my noobiness, devDependencies: {
// ...
"ember-source": "git://github.com/emberjs/ember.js.git#6c7e6950f127aa31912b5729971703c0c9615655"
// ... but it fails on
What am I doing wrong :)? |
@gmaliar |
This can be closed, it works properly on |
Thanks for confirming! |
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:
Default 'error' routes are set here:
ember.js/packages/ember-routing/lib/system/dsl.js
Lines 49 to 50 in 10857fd
You can test it by trying to handle
error
route usingember g route error
.This functionality worked fine in 2.9 .
The text was updated successfully, but these errors were encountered: