Skip to content
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

Random Rainmeter Crashes with versions greater than 1.2.0 #8

Closed
BigBagss opened this issue Jul 3, 2023 · 22 comments
Closed

Random Rainmeter Crashes with versions greater than 1.2.0 #8

BigBagss opened this issue Jul 3, 2023 · 22 comments

Comments

@BigBagss
Copy link

BigBagss commented Jul 3, 2023

TL;DR:
Rainmeter crashes at random times with versions greater than 1.2.0. windows event viewer Log included.

hi, thank you for this great plugin!

for some reason new releases (>1.2.0) cause Rainmeter to crash at random times (sometimes no crashes for a couple of days, sometimes a few times a day.)

this is the log i found in windows event viewer, i hope this helps:

Application: Rainmeter.exe
Framework Version: v4.0.30319
Description: The process was terminated due to an unhandled exception.
Exception Info: System.OperationCanceledException
   at System.Threading.CancellationToken.ThrowOperationCanceledException()
   at System.Net.WebSockets.WebSocketBase.ThrowIfConvertibleException(System.String, System.Exception, System.Threading.CancellationToken, Boolean)
   at System.Net.WebSockets.WebSocketBase+<CloseOutputAsyncCore>d__51.MoveNext()
   at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()
   at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(System.Threading.Tasks.Task)
   at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(System.Threading.Tasks.Task)
   at System.Net.WebSockets.WebSocketBase+<CloseAsyncCore>d__56.MoveNext()

Exception Info: System.Net.WebSockets.WebSocketException
   at System.Net.WebSockets.WebSocketBase.ThrowIfAborted(Boolean, System.Exception)
   at System.Net.WebSockets.WebSocketBase.ThrowIfConvertibleException(System.String, System.Exception, System.Threading.CancellationToken, Boolean)
   at System.Net.WebSockets.WebSocketBase+<CloseAsyncCore>d__56.MoveNext()

Exception Info: System.Net.WebSockets.WebSocketException
   at System.Net.WebSockets.WebSocketBase.ThrowIfAborted(Boolean, System.Exception)
   at System.Net.WebSockets.WebSocketBase.ThrowIfConvertibleException(System.String, System.Exception, System.Threading.CancellationToken, Boolean)
   at System.Net.WebSockets.WebSocketBase+<CloseAsyncCore>d__56.MoveNext()
   at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()
   at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(System.Threading.Tasks.Task)
   at WNPReduxAdapterLibrary.WNPHttpServer+<ProcessWebSocketRequest>d__7.MoveNext()
   at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()
   at System.Threading.ExecutionContext.RunInternal(System.Threading.ExecutionContext, System.Threading.ContextCallback, System.Object, Boolean)
   at System.Threading.ExecutionContext.Run(System.Threading.ExecutionContext, System.Threading.ContextCallback, System.Object, Boolean)
   at System.Threading.QueueUserWorkItemCallback.System.Threading.IThreadPoolWorkItem.ExecuteWorkItem()
   at System.Threading.ThreadPoolWorkQueue.Dispatch()

and in the log i see WNPReduxAdapterLibrary so it's something with the plugin i guess.

i don't know much about this but it could be my antivirus (Kaspersky free) blocking this or something like that, not sure.

things i've tried:

  • reinstalled rainmeter.
  • disabled native api support.
    both locally and from the extension:
    ran the command that added this directory ...\AppData\Local\WebNowPlaying\disable_native_apis
    and disabled native API's from the chrome extension popup.

only versions after 1.2.0 have this issue. (with 1.2.0 i have 0 crashes.)
so i don't think this is an issue with Rainmeter/it's skins.

i am sorry if I'm missing the solution / something out about this in the documentation.
thanks!

@keifufu
Copy link
Owner

keifufu commented Jul 3, 2023

Does this happen when you do something specific? Like executing a wnp bang like pausing/skipping, or when closing the browser?

@BigBagss
Copy link
Author

BigBagss commented Jul 3, 2023

funnily enough, this catches me mostly off guard when i leave my computer, and i am pretty sure the browser is minimized (sometimes with a few tabs of youtube videos).
so i come back and see that rainmeter was closed.

@keifufu
Copy link
Owner

keifufu commented Jul 3, 2023

Please give this version a go: WebNowPlaying.zip

@BigBagss
Copy link
Author

BigBagss commented Jul 3, 2023

thanks for the help! i will update if i see any crashes with this version.

@lehuymanhtan
Copy link

lehuymanhtan commented Jul 6, 2023

Please give this version a go: WebNowPlaying.zip

I also had a similar problem like this. But in my case Rainmeter couldn't turn on. Tried this version and the latest but still not working.

@BigBagss
Copy link
Author

BigBagss commented Jul 6, 2023

weird, what used to happen is it would simply crash but i could re open rainmeter normally with no issues and it would crash some time later again.
but ever since using the version above i had 0 crashes so far, seems like it's working for me.

maybe you have some old/broken plugin/skin causing those crashes...

@keifufu
Copy link
Owner

keifufu commented Jul 6, 2023

@lehuymanhtan If possible, please provide some Rainmeter logs or event viewer logs as without those there is nothing I can diagnose.

@keifufu
Copy link
Owner

keifufu commented Jul 6, 2023

@BigBagss Good to know it's going well so far, I'm hoping it'll stay that way.
Have you had issues with it not reporting media at all, instead of crashing?

@lehuymanhtan
Copy link

@lehuymanhtan If possible, please provide some Rainmeter logs or event viewer logs as without those there is nothing I can diagnose.

I think I found out why my Rainmeter crashed. The plugin somehow can’t start the WebSocket. In version 1.2.0, if it can’t start the WebSocket, it writes it in the log. However, in newer versions, it crashes Rainmeter.

And here is crash log from Event Viewer:

Application: Rainmeter.exe
Framework Version: v4.0.30319
Description: The process was terminated due to an unhandled exception.
Exception Info: System.Net.HttpListenerException
   at System.Net.HttpListener.AddAllPrefixes()
   at System.Net.HttpListener.Start()
   at WNPReduxAdapterLibrary.WNPHttpServer+<StartThreaded>d__6.MoveNext()
   at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()
   at System.Threading.ExecutionContext.RunInternal(System.Threading.ExecutionContext, System.Threading.ContextCallback, System.Object, Boolean)
   at System.Threading.ExecutionContext.Run(System.Threading.ExecutionContext, System.Threading.ContextCallback, System.Object, Boolean)
   at System.Threading.QueueUserWorkItemCallback.System.Threading.IThreadPoolWorkItem.ExecuteWorkItem()
   at System.Threading.ThreadPoolWorkQueue.Dispatch()

@BigBagss
Copy link
Author

BigBagss commented Jul 6, 2023

@BigBagss Good to know it's going well so far, I'm hoping it'll stay that way. Have you had issues with it not reporting media at all, instead of crashing?

nope, as far as i can tell everything is working normally. thanks!

@keifufu
Copy link
Owner

keifufu commented Jul 6, 2023

@lehuymanhtan I see, I can definitely catch this error but why can't it start it in the first place... Any other program running the same port?

@lehuymanhtan
Copy link

@lehuymanhtan I see, I can definitely catch this error but why can't it start it in the first place... Any other program running the same port?

Nope. I checked Process Hacker and found no applications running on that port.
By the way, I have fixed it just by restarting my computer.

@lehuymanhtan
Copy link

Anyway, thank you all for your help.

@keifufu
Copy link
Owner

keifufu commented Jul 6, 2023

Interesting, I'll still implement better error handling for it soon.

@mrinmaydhar
Copy link

Please give this version a go: WebNowPlaying.zip

Just an FYI, this version did not work for me.
Getting the same WebSocket error in EventViewer
I replaced the DLL provided in the zip in the following location:
C:\Users\<username>\OneDrive\Documents\Rainmeter\Skins\@Vault\Plugins\WebNowPlaying\2.0.5.0\64bit
Event Viewer logs

If you need any logs, feel free to message me.

@keifufu
Copy link
Owner

keifufu commented Jul 14, 2023

@mrinmaydhar The plugin needs to be replaced in %AppData%\Rainmeter\Plugins, so you didn't actually replace it.

@BigBagss
Copy link
Author

Please give this version a go: WebNowPlaying.zip

Just an FYI, this version did not work for me. Getting the same WebSocket error in EventViewer I replaced the DLL provided in the zip in the following location: C:\Users\<username>\OneDrive\Documents\Rainmeter\Skins\@Vault\Plugins\WebNowPlaying\2.0.5.0\64bit Event Viewer logs

If you need any logs, feel free to message me.

i had no crashes after using this version. here is everything i did:

  • disabled native api support. docs
    both locally and from the extension:
    ran the command that added this directory ...\AppData\Local\WebNowPlaying\disable_native_apis
    and disabled native API's from the chrome extension popup.

  • replaced WNPR in %AppData%\Rainmeter\Plugins

also check in rainmeter About Rainmeter->Plugins to ensure that the new version is 2.0.5.1

@keifufu
Copy link
Owner

keifufu commented Jul 14, 2023

@BigBagss native API shouldn't be the cause btw as they don't touch websockets.

@BigBagss
Copy link
Author

@BigBagss native API shouldn't be the cause btw as they don't touch websockets.

yeah i suspected something like that, i don't really use the native API so i left it disabled and had no crashes with the new version. thanks!

@keifufu
Copy link
Owner

keifufu commented Jul 14, 2023

I'll be waiting for a bit longer and if you still don't experience any crashes on the new version I'll release it and consider this closed.

@mrinmaydhar
Copy link

mrinmaydhar commented Jul 14, 2023

@BigBagss I've confirmed the version as 2.0.5.1 as you suggested in About Rainmeter. (Did not disable native API support, however)
@keifufu I've also replaced the DLL as you mentioned.
I'll keep a lookout for any more crashes. Thank you.

@keifufu
Copy link
Owner

keifufu commented Jul 18, 2023

Going to assume this has been resolved. Released v2.0.6 with this and another crash hopefully fixed.

@keifufu keifufu closed this as completed Jul 18, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants