-
Notifications
You must be signed in to change notification settings - Fork 17k
Description
Preflight Checklist
- I have read the Contributing Guidelines for this project.
- I agree to follow the Code of Conduct that this project adheres to.
- I have searched the issue tracker for an issue that matches the one I want to file, without success.
Issue Details
- Electron Version:
- 6.0.10
- Operating System:
- Windows 10 (1903)
- Last Known Working Electron version:
- 5.0.10
Expected Behavior
Invoking a method (defined in and provided by the main process) from the renderer process (attached to the global object in the preload script), should work and not crash the renderer process.
Actual Behavior
Invoking such method with simple arguments like a string or a simple object works, but invoking it with a complex nested object (no circular dependency and low in size) causes the renderer process to crash.
To Reproduce
Git Repo URL: https://github.com/flashd2n/electron-submit
$ git clone https://github.com/flashd2n/electron-submit.git
$ npm install
$ npm startAdditional Information
Starting the app will open a single window and it's devtools console. The main process will pass to the renderer an object (reproduce) with a property (invoke) - a method which returns a success message. In the renderer's preload script this object is assigned to the global window object. The spawned window has three buttons:
- Simple - invokes window.reproduce.invoke with a simple string and prints the result
- Medium - invokes window.reproduce.invoke with a medium in complexity object and prints the result
- Complex - invokes window.reproduce.invoke with a high in complex object and prints the result
Simple or Medium will print the success message the the window console, but Complex will crash subprocess and close the window - a crash message is displayed in the main process's console.
This was tried in Electron:
- 5.0.10 - all invocations work.
- 6.0.10 - the complex invocation crashes the subprocess.
- 7.0.0-beta.4 - the complex invocation crashes the subprocess.