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

[BUGFIX LTS] Don't run getters while applying mixins #20388

Merged
merged 3 commits into from Mar 8, 2023

Conversation

wycats
Copy link
Member

@wycats wycats commented Mar 1, 2023

This change ensures that getters are never evaluated while applying
mixins.

It relies on the fact that all getters (including undecorated ones) get
converted into classic decorators when the mixin is originally created.

This change ensures that getters are never evaluated while applying
mixins.

It relies on the fact that all getters (including undecorated ones) get
converted into classic decorators when the mixin is originally created.
@chriskrycho
Copy link
Contributor

Looks like this is aimed at the issue ID'd in #19916?

@gitKrystan
Copy link
Contributor

@chriskrycho It's related to #18860 and #20129

@chriskrycho
Copy link
Contributor

Yep, and #20129 was a failing test for #19916. 👍🏼

@wycats
Copy link
Member Author

wycats commented Mar 3, 2023

@chriskrycho Do you mean to refer to "No documented public API for Owner"?

@chriskrycho
Copy link
Contributor

Nope, brain fog. I meant #18860, which Krystan linked. 😮‍💨

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.

Couple small things and then we should be able to land and back port this. Thanks for getting it fixed!

tsconfig.json Outdated Show resolved Hide resolved
packages/@ember/object/mixin.ts Outdated Show resolved Hide resolved
wycats and others added 2 commits March 6, 2023 10:56
Co-authored-by: Chris Krycho <hello@chriskrycho.com>
@gitKrystan
Copy link
Contributor

@chriskrycho I think this is ready

@chriskrycho chriskrycho merged commit 03bc5f9 into master Mar 8, 2023
@chriskrycho chriskrycho deleted the fix-zebra-mixins branch March 8, 2023 01:11
@chriskrycho
Copy link
Contributor

I am planning to do an LTS release (so: back to 4.8) by the end of this week and will make sure this is included!

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

Successfully merging this pull request may close these issues.

None yet

3 participants