ember-data-has-many-query icon indicating copy to clipboard operation
ember-data-has-many-query copied to clipboard

Does not work with Ember Data > 3.14

Open iamareebjamal opened this issue 5 years ago • 1 comments

Relevant Upstream Issue - https://github.com/emberjs/data/issues/7074

await eventDetails.query('sessions', {
  include      : 'speakers,track,microlocations',
  filter       : scheduledFilterOptions,
  'page[size]' : 0
});

await eventDetails.query('sessions', {
  include      : 'speakers,track',
  filter       : unscheduledFilterOptions,
  'page[size]' : 0
});

After loading the first query using the URL - /events/123/sessions?include=speakers,track,microlocations...&page[size]=0

On running the second query, it just requests every entity loaded in first query individually

/sessions/1 /sessions/2 /sessions/3 ...

It doesn't matter what you passed in the query params, it returns same thing over and over again. I did not find any release notes (checking for breaking changes) beyond 3.14.1 here, which is the last version with correct behaviour.

Here's a reproduction of the bug https://github.com/iamareebjamal/ember-data-bug

Code is self-explanatory and bug is evident on visiting index page and viewing the network panel. Changing ember-data to 3.14.1 fixes the bug

iamareebjamal avatar Apr 15 '20 23:04 iamareebjamal

I'm late to this issue, unfortunately. However I'm in the same position but I'm at Ember 3.24. I'm about to start my journey through all the referenced links and issues. But, is there a summary of what needs to be done in order to get past this issue? Do I stop using this addon? Can I locally change the addon so that it works (it appears this project is in hibernation mode)? Any guidance is welcomed.

melriffe avatar Aug 05 '21 19:08 melriffe