It is currently March 28th, 2024, 10:32 am

[Bug] UsageMonitor crash with unhandled null exception

Report bugs with the Rainmeter application and suggest features.
Sky YoNG
Posts: 1
Joined: June 22nd, 2018, 12:54 pm

[Bug] UsageMonitor crash with unhandled null exception

Post by Sky YoNG »

As stated.

Rainmeter just quit without any error dialog when this happened. Also I running 3 monitor setup and this issue occurred mostly when my monitor going into sleep mode.

Windown Event Viewer
Untitled.png
Untitled1.png
Untitled2.png
Untitled3.png
Rainmeter Version
4.2.0 beta r3088 64-bit (Jun 15 2018) - English (1033)
Windows 10 Pro 1803 64-bit (build 17134) - English (1033)
User avatar
tjhrulz
Developer
Posts: 267
Joined: October 13th, 2016, 1:28 am
Location: Earth
Contact:

Re: [Bug] UsageMonitor crash with unhandled null exception

Post by tjhrulz »

Fixed as of Rainmeter 4.2 Beta Release - r3101.
ManiusNG
Posts: 7
Joined: June 24th, 2018, 10:30 pm

Re: [Bug] UsageMonitor crash with unhandled null exception

Post by ManiusNG »

I suppose it's not fully fixed (happened with 3104)
Attachments
RainMeter_2.PNG
RainMeter_1.PNG
User avatar
tjhrulz
Developer
Posts: 267
Joined: October 13th, 2016, 1:28 am
Location: Earth
Contact:

Re: [Bug] UsageMonitor crash with unhandled null exception

Post by tjhrulz »

ManiusNG wrote:I suppose it's not fully fixed (happened with 3104)
You know what this is a different error than the one I fixed, odd that GetString is causing a crash because there is not much in there that should have the potential to cause a crash.

I have attached a version with special debug logging added to it, do you mind trying that and seeing what it says in the Rainmeter log (Turn on debugging in the settings and in the log as well so you can see the full stacktrace and message so you wont need another program)?

To install it just go into the plugins folder where you installed Rainmeter (Typically C:\Program Files\Rainmeter\Plugins\) and replace the UsageMonitor.dll with the one in the included zip
Attachments
UsageMonitor.zip
(12.05 KiB) Downloaded 48 times
Last edited by tjhrulz on June 30th, 2018, 3:07 am, edited 1 time in total.
ManiusNG
Posts: 7
Joined: June 24th, 2018, 10:30 pm

Re: [Bug] UsageMonitor crash with unhandled null exception

Post by ManiusNG »

tjhrulz wrote:You know what this is a different error than the one I fixed, odd that GetString is causing a crash because there is not much in there that should have the potential to cause a crash.

I have attached a version with special debug logging added to it, do you mind trying that and seeing what it says in the Rainmeter log (Turn on debugging in the settings and in the log as well so you can see the full stacktrace and message so you wont need another program)?

To install it just go into the plugins folder where you installed Rainmeter (Typically C:\Program Files\Rainmeter\Plugins\) and replace the UsageMonitor.dll with the one in the included zip
Hi,

I've installed the supplied version and turned on debugging. As soon as I get crash, I'll keep You updated.

Cheers,
Rafal
User avatar
tjhrulz
Developer
Posts: 267
Joined: October 13th, 2016, 1:28 am
Location: Earth
Contact:

Re: [Bug] UsageMonitor crash with unhandled null exception

Post by tjhrulz »

ManiusNG wrote:Hi,

I've installed the supplied version and turned on debugging. As soon as I get crash, I'll keep You updated.

Cheers,
Rafal
It actually should stop rainmeter from crashing and instead it will just log it if a crash *would* have happened. You can log it to a file you have that active or just to the console if you don't. So I would check that for an error that says something like "UsageMonitor crashed trying to return the new String value of this measure"
Last edited by tjhrulz on June 30th, 2018, 3:09 am, edited 1 time in total.
User avatar
jsmorley
Developer
Posts: 22628
Joined: April 19th, 2009, 11:02 pm
Location: Fort Hunt, Virginia, USA

Re: [Bug] UsageMonitor crash with unhandled null exception

Post by jsmorley »

Rafal,

If we can get you to take a minute to test what tjhrulz has provided and give us some feedback, it would be a huge help.
User avatar
SilverAzide
Rainmeter Sage
Posts: 2588
Joined: March 23rd, 2015, 5:26 pm
Contact:

Re: [Bug] UsageMonitor crash with unhandled null exception

Post by SilverAzide »

jsmorley wrote:If we can get you to take a minute to test what tjhrulz has provided and give us some feedback, it would be a huge help.
Today I got the APPCRASH issue, which I've been getting for a while but on very rare occasions. It seems to always happen when the machine has been idle (monitor asleep, screensaver active). Symptom are the same as the original poster's, in that Rainmeter is just gone (no error message dialog). I don't have much useful to give you, my event log just indicates a crash in the CLR. I installed TJHrulz's debug DLL and I get a humongous dump of errors. I've attached a zip containing the following:

Rainmeter.log
Event1.txt (EventViewer event #1)
Event2.txt (EventViewer event #2)
Event3.txt (EventViewer event #3)
Report.wer (Windows error report)

One oddity about the Rainmeter log... the massive unending stream of debug messages about being "Could not find a counter..." are happening on measures that are disabled as well as ones that are enabled.

P.S.: The log file was collected after the crash (the Windows events are for the crash), the log is for when I installed the debug DLL, so the two things are not necessarily related.

4.2.0 beta r3104 64-bit (Jun 23 2018) - English (1033)
Windows 10 Pro 1803 64-bit (build 17134) - English (1033)
Path: C:\Program Files\Rainmeter\
SkinPath: C:\Users\...\Documents\Rainmeter\Skins\
SettingsPath: C:\Users\...\AppData\Roaming\Rainmeter\
IniFile: C:\Users\ripsn\AppData\Roaming\Rainmeter\Rainmeter.ini
Attachments
Rainmeter.zip
(31.31 KiB) Downloaded 35 times
User avatar
tjhrulz
Developer
Posts: 267
Joined: October 13th, 2016, 1:28 am
Location: Earth
Contact:

Re: [Bug] UsageMonitor crash with unhandled null exception

Post by tjhrulz »

SilverAzide wrote:Today I got the APPCRASH issue, which I've been getting for a while but on very rare occasions. It seems to always happen when the machine has been idle (monitor asleep, screensaver active). Symptom are the same as the original poster's, in that Rainmeter is just gone (no error message dialog). I don't have much useful to give you, my event log just indicates a crash in the CLR. I installed TJHrulz's debug DLL and I get a humongous dump of errors. I've attached a zip containing the following:

Rainmeter.log
Event1.txt (EventViewer event #1)
Event2.txt (EventViewer event #2)
Event3.txt (EventViewer event #3)
Report.wer (Windows error report)

One oddity about the Rainmeter log... the massive unending stream of debug messages about being "Could not find a counter..." are happening on measures that are disabled as well as ones that are enabled.

P.S.: The log file was collected after the crash (the Windows events are for the crash), the log is for when I installed the debug DLL, so the two things are not necessarily related.

4.2.0 beta r3104 64-bit (Jun 23 2018) - English (1033)
Windows 10 Pro 1803 64-bit (build 17134) - English (1033)
Path: C:\Program Files\Rainmeter\
SkinPath: C:\Users\...\Documents\Rainmeter\Skins\
SettingsPath: C:\Users\...\AppData\Roaming\Rainmeter\
IniFile: C:\Users\ripsn\AppData\Roaming\Rainmeter\Rainmeter.ini

Oops went a little overkill on the logging and had left in some bad code I was testing in that one. I reattached a new version that should better log everything if that crash happens again.

Ill try some extra testing with a screensaver. I have seen no random crashes myself though but I will try a screensaver. (Also are we talking actual sleep mode ever or just pure screensaver relate (It may be crashing while it is happening too and you just don't see it till you come back too I guess)
User avatar
SilverAzide
Rainmeter Sage
Posts: 2588
Joined: March 23rd, 2015, 5:26 pm
Contact:

Re: [Bug] UsageMonitor crash with unhandled null exception

Post by SilverAzide »

tjhrulz wrote:Ill try some extra testing with a screensaver. I have seen no random crashes myself though but I will try a screensaver. (Also are we talking actual sleep mode ever or just pure screensaver relate (It may be crashing while it is happening too and you just don't see it till you come back too I guess)
To clarify my comment, I don't have my machine configured to actually go into sleep mode. Basically, after 10 minutes or so of being idle, the normal Windows screensaver (slideshow, in my case) will kick in, and after about a half-hour the PC will turn off the monitor. When I eventually log back into the machine, I sometimes -- admittedly very rarely -- will see that Rainmeter has been killed.

I'll try the new DLL and let you know if anything crops up...
Post Reply