[BUGFIX beta] Raise by default when ENV.RAISE_ON_DEPRECATION is true#11432
Merged
rwjblue merged 1 commit intoemberjs:masterfrom Jun 12, 2015
Merged
[BUGFIX beta] Raise by default when ENV.RAISE_ON_DEPRECATION is true#11432rwjblue merged 1 commit intoemberjs:masterfrom
ENV.RAISE_ON_DEPRECATION is true#11432rwjblue merged 1 commit intoemberjs:masterfrom
Conversation
Member
|
👍 |
Member
|
Thank you for the tests |
Member
Author
|
I clearly didn't run w/ JSCS. Sorry, will fix the tests now. |
Fixes an issue introduced by emberjs#11419 where the evaluation of `ENV.RAISE_ON_DEPRECATION` was moved to boot-time rather than run-time. Previously, it was possible to set `RAISE_ON_DEPRECATION` to true midway through running an app, and all deprecations after that would throw because `Ember.deprecate` would check the value of the env variable every time it was called. The code in emberjs#11419 changed to a [one-time evaulation at boot-time](https://github.com/emberjs/ember.js/blob/master/packages/ember-debug/lib/main.js#L279-L281), breaking that original behavior. This commit restores the old behavior while still allowing changing deprecation behavior for specific deprecations by id.
9e81055 to
7290c71
Compare
rwjblue
added a commit
that referenced
this pull request
Jun 12, 2015
[BUGFIX beta] Raise by default when `ENV.RAISE_ON_DEPRECATION` is true
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Fixes an issue introduced by #11419 where the evaluation of
ENV.RAISE_ON_DEPRECATIONwas moved to boot-time rather than run-time.Previously, it was possible to set
RAISE_ON_DEPRECATIONto true midwaythrough running an app, and all deprecations after that would throw
because
Ember.deprecatewould check the value of the env variableevery time it was called.
The code in #11419 changed to a one-time evaulation at boot-time,
breaking that original behavior. This commit restores the old behavior
while still allowing changing deprecation behavior for specific
deprecations by id.