mirror of
https://github.com/ElectronNET/Electron.NET.git
synced 2026-02-03 21:25:13 +00:00
Node process running after stopping app #120
Reference in New Issue
Block a user
Delete Branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Originally created by @pardahlman on GitHub (Feb 11, 2018).
Originally assigned to: @GregorBiswanger on GitHub.
Hello - I'm impressed by the great work in this project and I hope it will continue to evolve 👌. I'm playing around with a ASP.NET Core app, very similar to the demo app in this repo. When I stop the application after starting it from Visual Studio (Windows) there are still node process(es) running. I'm wondering if this is an known issue or if it is I who miss to make some call/dispose some resource in order to signal to Node that the web app has shut down.
Keep up the good work!
@AirLancer commented on GitHub (Feb 11, 2018):
Sound a lot like this issue:
https://github.com/ElectronNET/Electron.NET/issues/68
@pardahlman commented on GitHub (Feb 17, 2018):
You are right @AirLancer - they are probably related. Worth noting is that I do this before shutting down the ASP.NET application
@Jonatthu commented on GitHub (Feb 18, 2018):
I am still having this problem, Is there any solution?
@robertmuehsig commented on GitHub (Feb 19, 2018):
I try to release a new version of the API as well - @GregorBiswanger told me, that there might be a fix included.
@GregorBiswanger commented on GitHub (Feb 25, 2018):
@pardahlman, @Jonatthu, @pardahlman - do you try out the newest version of API and CLI (0.0.9)?
@pardahlman commented on GitHub (Feb 26, 2018):
Hi, @GregorBiswanger - not yet (I didn't know it included a potential fix for this!). Will upgrade later today and report back to you. Thanks!
@pardahlman commented on GitHub (Mar 21, 2018):
0.0.9 is definitely more stable - thanks a bunch!
@flakron commented on GitHub (Apr 16, 2018):
I have version 0.0.9 and have this issue
@GregorBiswanger commented on GitHub (Apr 16, 2018):
@flakron What OS do you use?
@flakron commented on GitHub (Apr 16, 2018):
Sorry, should've left more information.
OS: Ubuntu 16.04,
Dotnet SDK version: 2.1.4
The backend doesn't seem to get that the windows is closed and keeps running in background.
@EldinZenderink commented on GitHub (Jul 18, 2018):
After running & closing 5 times using v0.0.9 . Backend does contain threads but I do know from earlier versions and standalone backend that they stop correctly when told so. I use both OnClose/OnClosed to close the threads running within the back-end.
A simple hack that i can think of is just literally starting a kill command for the back-end process... but that still doesn't tell electron to close.
Edit: welp, i gave up and went directly to main.js file, and adding this fixed it:
@GregorBiswanger commented on GitHub (May 18, 2019):
Fixed with the next Electron.NET update.
@netpoetica commented on GitHub (Jun 3, 2019):
FWIW, I am still seeing this error.
I have a main menu where the user clicks File -> Exit (I only have 1 window)
And then I have an event listener which is attached the app first starts:
I am taking extra care to manually remove all event listeners to ensure this isn't the reason why it fails.
What happens is, the window closes, and the electron process goes away, but the API process remains in the task manager (Activity Monitor on Mac OSX).
This is happening after a /target macosx release using the release version, and with
electronize start.It looks to me like the Click callback to MenuItem with name "exit" is not being called, maybe
This console.log does not occur. If I rename "Exit" to "Go Away", the Click handler does get called, window closes, but the application remains open
@netpoetica commented on GitHub (Jun 3, 2019):
Can you share where that variable "app" came from in your site.js?