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

Add a test that dedupeTracked works with EmberObject #61

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

boris-petrov
Copy link
Contributor

@chriskrycho
Copy link
Contributor

@boris-petrov it's failing on the lint stage – mind updating accordingly? Thanks!

Copy link
Contributor

@chriskrycho chriskrycho left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I haven't had time to dig into the details here, but here's an intuitive explanation of what's happening based on what I see in the stack trace:

  1. Decorators1 work by doing a defineProperty call in the constructor, just like class fields do, but with all the extra hooks for actually doing the right things as decorated properties.
  2. Ember object initialization does its very best to interoperate correctly with that (see in particular its check for whether what it gets back is a descriptor).

Best guess is that what this is currently returning is incompatible with how Ember expects a descriptor to come back (missing a name, maybe?). That's all I have at the moment.

Footnotes

  1. under the current spec, at least; I don't remember if the semantics are the same under the updated proposal which is being presented at TC39 this month

@boris-petrov
Copy link
Contributor Author

I don't remember why I had this use case. I now don't so for me this is low priority. If someone has the time, they could try to see what's going on. If not, still fine. :) Let's just leave this PR open and we'll merge it once it passes.

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

Successfully merging this pull request may close these issues.

3 participants