-
-
Notifications
You must be signed in to change notification settings - Fork 477
electron 18 uses context aware plugin Napi::Addon. Sometimes Devtools reload for electron will lead to render process crash. Is there any way to locate the problem? #1232
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
Comments
Hi @Candylong , Is it possible to provide some repository / minimal reproduction of your crash? It is difficult to diagnose why you are receiving a crash without knowing which Node API features / functions you are using. Thanks, Kevin |
Hi, @KevinEady ,There is a problematic context here,#1224 |
Discussed in the Node-api team meeting, can you provide the updated version of the source you are using? |
hello, @mhdawson ,I used [email protected] |
Hi @Candylong I think that @mhdawson asked also for the source code that causes the crash. Is it public? Could you report an example? |
Hi, @NickNaso, @mhdawson addon.node uses a third party library called.DLL, which has multiple threads calling back to.node, and then using thread-safe functions, crashes occur in thread-safe functions when loading.node multiple times Execute in a thread-safe function |
What we were hoping for is a simple recreate, code that we can run to recreate the crash you were seeing. Is that something you can extract/provide? |
@mhdawson , It is in thread-safe functions that an exception is thrown, as shown below, and when a exception occurs, can I use this interface [GetAndClearPendingException] to clear exceptions |
@NickNaso , Hi, I have arranged my demo and put it here(https://github.com/Candylong/napi-electron-demo). I mainly run it on windows, and it can be reproduced after about 5 operations. Can you have a try |
The relevant questions are as follows,#1244 |
I just tried to run your demo. It says "We are using Node.js 18.12.1, Chromium 110.0.5481.208, and Electron 23.2.2.", and it doesn not crash. |
This issue is stale because it has been open many days with no activity. It will be closed soon unless the stale label is removed or a comment is made. |
electron prompt:
Devtools was disconnected from this page........
Console output:
libc++abi: terminating with uncaught exception of type Napi::Error:
Renderer process crashed - see https://www.electronjs.org/docs/tutorial/application-debugging for potential debugging information.
The text was updated successfully, but these errors were encountered: