scopes: make failure of closing scopes fatal#566
Closed
legendecas wants to merge 1 commit intonodejs:masterfrom
Closed
scopes: make failure of closing scopes fatal#566legendecas wants to merge 1 commit intonodejs:masterfrom
legendecas wants to merge 1 commit intonodejs:masterfrom
Conversation
But not ignoring these failures.
Member
|
Can you give some context on how this would affect existing code. For example, is it going to fail out already just with a poorer stack trace/info or is this potentially going to break some existing code? |
1 task
Member
Author
|
I don't think it would affect the existing working code. Yet it would be helpful to debug possibly misusage of Value doubleCloseScope(const CallbackInfo& info) {
Env env = info.Env();
HandleScope scope(env);
HandleScope scope2 = scope; // this one would be closed with status `napi_handle_scope_mismatch` silently
return env.Undefined();
} |
Member
|
@gabrielschulhof if you agree it's unlikely to affect working code I'm ok with it. |
Member
|
Discussion in N-API team meeting today was that this is directly related to #565. We don't believe that the close should fail except for the case where it had been copied which will no longer be possible. |
Member
|
We did discuss and this should land as a SemVer major even though it should not affect any existing code. |
gabrielschulhof
approved these changes
Oct 21, 2019
mhdawson
pushed a commit
that referenced
this pull request
Oct 23, 2019
Properly handle failures instead of ignoring them. PR-URL: #566 Reviewed-By: NickNaso <nicoladelgobbo@gmail.com> Reviewed-By: Michael Dawson <michael_dawson@ca.ibm.com> Reviewed-By: Gabriel Schulhof <gabriel.schulhof@intel.com>
Member
|
Landed as ce139a0 |
mhdawson
pushed a commit
that referenced
this pull request
Oct 23, 2019
PR-URL: #566 Reviewed-By: NickNaso <nicoladelgobbo@gmail.com> Reviewed-By: Michael Dawson <michael_dawson@ca.ibm.com> Reviewed-By: Gabriel Schulhof <gabriel.schulhof@intel.com>
kevindavies8
added a commit
to kevindavies8/node-addon-api-Develop
that referenced
this pull request
Aug 24, 2022
Properly handle failures instead of ignoring them. PR-URL: nodejs/node-addon-api#566 Reviewed-By: NickNaso <nicoladelgobbo@gmail.com> Reviewed-By: Michael Dawson <michael_dawson@ca.ibm.com> Reviewed-By: Gabriel Schulhof <gabriel.schulhof@intel.com>
kevindavies8
added a commit
to kevindavies8/node-addon-api-Develop
that referenced
this pull request
Aug 24, 2022
PR-URL: nodejs/node-addon-api#566 Reviewed-By: NickNaso <nicoladelgobbo@gmail.com> Reviewed-By: Michael Dawson <michael_dawson@ca.ibm.com> Reviewed-By: Gabriel Schulhof <gabriel.schulhof@intel.com>
Marlyfleitas
added a commit
to Marlyfleitas/node-api-addon-Development
that referenced
this pull request
Aug 26, 2022
Properly handle failures instead of ignoring them. PR-URL: nodejs/node-addon-api#566 Reviewed-By: NickNaso <nicoladelgobbo@gmail.com> Reviewed-By: Michael Dawson <michael_dawson@ca.ibm.com> Reviewed-By: Gabriel Schulhof <gabriel.schulhof@intel.com>
Marlyfleitas
added a commit
to Marlyfleitas/node-api-addon-Development
that referenced
this pull request
Aug 26, 2022
PR-URL: nodejs/node-addon-api#566 Reviewed-By: NickNaso <nicoladelgobbo@gmail.com> Reviewed-By: Michael Dawson <michael_dawson@ca.ibm.com> Reviewed-By: Gabriel Schulhof <gabriel.schulhof@intel.com>
wroy7860
added a commit
to wroy7860/addon-api-benchmark-node
that referenced
this pull request
Sep 19, 2022
Properly handle failures instead of ignoring them. PR-URL: nodejs/node-addon-api#566 Reviewed-By: NickNaso <nicoladelgobbo@gmail.com> Reviewed-By: Michael Dawson <michael_dawson@ca.ibm.com> Reviewed-By: Gabriel Schulhof <gabriel.schulhof@intel.com>
wroy7860
added a commit
to wroy7860/addon-api-benchmark-node
that referenced
this pull request
Sep 19, 2022
PR-URL: nodejs/node-addon-api#566 Reviewed-By: NickNaso <nicoladelgobbo@gmail.com> Reviewed-By: Michael Dawson <michael_dawson@ca.ibm.com> Reviewed-By: Gabriel Schulhof <gabriel.schulhof@intel.com>
johnfrench3
pushed a commit
to johnfrench3/node-addon-api-git
that referenced
this pull request
Aug 11, 2023
Properly handle failures instead of ignoring them. PR-URL: nodejs/node-addon-api#566 Reviewed-By: NickNaso <nicoladelgobbo@gmail.com> Reviewed-By: Michael Dawson <michael_dawson@ca.ibm.com> Reviewed-By: Gabriel Schulhof <gabriel.schulhof@intel.com>
johnfrench3
pushed a commit
to johnfrench3/node-addon-api-git
that referenced
this pull request
Aug 11, 2023
PR-URL: nodejs/node-addon-api#566 Reviewed-By: NickNaso <nicoladelgobbo@gmail.com> Reviewed-By: Michael Dawson <michael_dawson@ca.ibm.com> Reviewed-By: Gabriel Schulhof <gabriel.schulhof@intel.com>
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.
But not ignoring these failures.