Skip to content
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

queryRecord Regression in Ember Data 2.4 #4219

Closed
jherdman opened this issue Mar 7, 2016 · 4 comments
Closed

queryRecord Regression in Ember Data 2.4 #4219

jherdman opened this issue Mar 7, 2016 · 4 comments

Comments

@jherdman
Copy link

jherdman commented Mar 7, 2016

Issue #3790 allowed for queryRecord to work with empty responses, e.g. { my_model: [] }. This worked with Ember Data 2.3, but not with Ember Data 2.4. I have a reproduction app available:

The repo lives here: https://github.com/jherdman/issue-3790-reproduction. Run the app, hit the index page in your browser. Note the Ember Data 2.4 complains about the empty response, whereas 2.3.3 does not.

@floqqi
Copy link

floqqi commented Mar 7, 2016

Having exactly the same issue as mentioned in #4205 (comment).

This only happens using the development build of ember-cli in my app. In the production build (with ember-data at version 2.4.0) the API of queryRecord behaves like in 2.3.3 -> no complaining.

I'm not exactly sure what causes this issue. Tested with exactly the same server response in both build modes. Maybe the proxy-server of ember-cli?

@pangratz
Copy link
Member

pangratz commented Mar 8, 2016

Looks like regression has been added in #3864.

@floqqi
Copy link

floqqi commented Mar 8, 2016

API-Docs:

Ember build tools will remove any calls to Ember.assert() when doing a production build.

That would explain why it only fails in development.

bmac added a commit to bmac/data that referenced this issue Mar 21, 2016
The origial intent was for a queryRecord with no response to reject the promise so it would act like a `findRecord` with a 404. This change introduced a regression that broke existing apps so it is going to be reverted.

Closes emberjs#4219
bmac added a commit that referenced this issue Mar 22, 2016
The origial intent was for a queryRecord with no response to reject the promise so it would act like a `findRecord` with a 404. This change introduced a regression that broke existing apps so it is going to be reverted.

Closes #4219

(cherry picked from commit 274d7b1)
bmac added a commit that referenced this issue Mar 22, 2016
The origial intent was for a queryRecord with no response to reject the promise so it would act like a `findRecord` with a 404. This change introduced a regression that broke existing apps so it is going to be reverted.

Closes #4219

(cherry picked from commit 274d7b1)
bmac added a commit that referenced this issue Mar 22, 2016
The origial intent was for a queryRecord with no response to reject the promise so it would act like a `findRecord` with a 404. This change introduced a regression that broke existing apps so it is going to be reverted.

Closes #4219

(cherry picked from commit 274d7b1)
@bmac
Copy link
Member

bmac commented Mar 22, 2016

This fix has been released as Ember Data v2.4.3

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants