It is currently April 26th, 2024, 2:28 pm

New UsageMonitor plugin

Changes made during the Rainmeter 4.2 beta cycle.
User avatar
sephirotess
Posts: 332
Joined: December 8th, 2016, 6:45 am

Re: New UsageMonitor plugin

Post by sephirotess »

tjhrulz wrote:Well that was about the least likely cause of the crash I was expecting. Somehow it would seem that you have two instances in every counter under the Processes (Processus in french) category that share the same key. Unfortunately while my code handles this just fine Microsoft's does not. Given that this is not in a codebase I can fix I am not sure there is too much I can do.

You can try to see if the new version I attached fixes this (In order to test this new version you need to have windows 10 Fall Creators Update or installed .Net 4.7.1 manually) but I doubt it will have any impact and this is more so just so I can send a bug report to Microsoft.
Also can you run this command in powershell and upload the .csv file it makes? Get-Counter "\Processus(*)\% temps processeur" | Export-Counter -FileFormat "csv" PerfMon.csv (If anyone is having this issue in english try Get-Counter "\Process(*)\% Processor Time" | Export-Counter -FileFormat "csv" PerfMon.csv
Once again, thank you very much for your time.

As we expected, the new version does not work on a French Windows. As I mentioned in my first message, the problem is the same as with "NomFerp". I got the same error message: "L'élément a déjà été ajouté. Clé du dictionnaire...". We did tests with another skin designer (Yincognito), on different French Windows (XP, Vista, 7, 8 and 10). The plugin was partially running on an old XP (Service Pack2), but not on other systems. Your plugin seems to work in the same way as "NomFerp".

Here is the log of the new version, as well as the "PerfMon.csv" file. Thanks again and sorry for making you waste your time with my directory errors.

Code: Select all

NOTE (07:19:53.119) RainmeterProcess\RainmeterProcessNew.ini: Refreshing skin
DBUG (07:19:53.127) : Reading file: C:\Users\Sephi\AppData\Roaming\Rainmeter\Rainmeter.ini
DBUG (07:19:53.137) RainmeterProcess\RainmeterProcessNew.ini: Reading file: C:\Users\Sephi\Documents\Rainmeter\Skins\RainmeterProcess\RainmeterProcessNew.ini
ERRO (07:19:55.882) : UsageMonitor crashed trying to update the counterss
DBUG (07:19:55.882) : L'élément a déjà été ajouté. Clé du dictionnaire : 'taille virtuelle (octets)'  Clé ajoutée : 'taille virtuelle (octets)'
DBUG (07:19:56.203) :    à System.Collections.Hashtable.Insert(Object key, Object nvalue, Boolean add)

   à System.Collections.DictionaryBase.System.Collections.IDictionary.Add(Object key, Object value)

   à System.Diagnostics.CategorySample.ReadCategory()

   à UsageMonitor.Categories.Counters.UpdateCategory(String category)
ERRO (07:19:56.429) : UsageMonitor crashed trying to update the counterss
DBUG (07:19:56.429) : L'élément a déjà été ajouté. Clé du dictionnaire : 'taille virtuelle (octets)'  Clé ajoutée : 'taille virtuelle (octets)'
DBUG (07:19:56.445) :    à System.Collections.Hashtable.Insert(Object key, Object nvalue, Boolean add)

   à System.Collections.DictionaryBase.System.Collections.IDictionary.Add(Object key, Object value)

   à System.Diagnostics.CategorySample.ReadCategory()

   à UsageMonitor.Categories.Counters.UpdateCategory(String category)
NOTE (07:19:56.478) RainmeterProcess\RainmeterProcessNew.ini - [MeasureUsedCPU_Starting]: Percent=1 was set on counter:% temps processeur but that counter does not have an _Total instance
NOTE (07:19:56.478) RainmeterProcess\RainmeterProcessNew.ini - [MeasureUsedCPU]: Percent=1 was set on counter:% temps processeur but that counter does not have an _Total instance
NOTE (07:19:56.478) RainmeterProcess\RainmeterProcessNew.ini - [MeasureUsedCPU]: Percent=1 was set on counter:% temps processeur but that counter does not have an _Total instance
ERRO (07:19:57.445) : UsageMonitor crashed trying to update the counterss
DBUG (07:19:57.445) : L'élément a déjà été ajouté. Clé du dictionnaire : 'taille virtuelle (octets)'  Clé ajoutée : 'taille virtuelle (octets)'
DBUG (07:19:57.446) :    à System.Collections.Hashtable.Insert(Object key, Object nvalue, Boolean add)

   à System.Collections.DictionaryBase.System.Collections.IDictionary.Add(Object key, Object value)

   à System.Diagnostics.CategorySample.ReadCategory()

   à UsageMonitor.Categories.Counters.UpdateCategory(String category)
NOTE (07:19:57.456) RainmeterProcess\RainmeterProcessNew.ini - [MeasureUsedCPU]: Percent=1 was set on counter:% temps processeur but that counter does not have an _Total instance
PerfMon.zip
You do not have the required permissions to view the files attached to this post.
User avatar
tjhrulz
Developer
Posts: 268
Joined: October 13th, 2016, 1:28 am
Location: Earth

Re: New UsageMonitor plugin

Post by tjhrulz »

sephirotess wrote:Once again, thank you very much for your time.

As we expected, the new version does not work on a French Windows. As I mentioned in my first message, the problem is the same as with "NomFerp". I got the same error message: "L'élément a déjà été ajouté. Clé du dictionnaire...". We did tests with another skin designer (Yincognito), on different French Windows (XP, Vista, 7, 8 and 10). The plugin was partially running on an old XP (Service Pack2), but not on other systems. Your plugin seems to work in the same way as "NomFerp".

Here is the log of the new version, as well as the "PerfMon.csv" file. Thanks again and sorry for making you waste your time with my directory errors.

Code: Select all

NOTE (07:19:53.119) RainmeterProcess\RainmeterProcessNew.ini: Refreshing skin
DBUG (07:19:53.127) : Reading file: C:\Users\Sephi\AppData\Roaming\Rainmeter\Rainmeter.ini
DBUG (07:19:53.137) RainmeterProcess\RainmeterProcessNew.ini: Reading file: C:\Users\Sephi\Documents\Rainmeter\Skins\RainmeterProcess\RainmeterProcessNew.ini
ERRO (07:19:55.882) : UsageMonitor crashed trying to update the counterss
DBUG (07:19:55.882) : L'élément a déjà été ajouté. Clé du dictionnaire : 'taille virtuelle (octets)'  Clé ajoutée : 'taille virtuelle (octets)'
DBUG (07:19:56.203) :    à System.Collections.Hashtable.Insert(Object key, Object nvalue, Boolean add)

   à System.Collections.DictionaryBase.System.Collections.IDictionary.Add(Object key, Object value)

   à System.Diagnostics.CategorySample.ReadCategory()

   à UsageMonitor.Categories.Counters.UpdateCategory(String category)
ERRO (07:19:56.429) : UsageMonitor crashed trying to update the counterss
DBUG (07:19:56.429) : L'élément a déjà été ajouté. Clé du dictionnaire : 'taille virtuelle (octets)'  Clé ajoutée : 'taille virtuelle (octets)'
DBUG (07:19:56.445) :    à System.Collections.Hashtable.Insert(Object key, Object nvalue, Boolean add)

   à System.Collections.DictionaryBase.System.Collections.IDictionary.Add(Object key, Object value)

   à System.Diagnostics.CategorySample.ReadCategory()

   à UsageMonitor.Categories.Counters.UpdateCategory(String category)
NOTE (07:19:56.478) RainmeterProcess\RainmeterProcessNew.ini - [MeasureUsedCPU_Starting]: Percent=1 was set on counter:% temps processeur but that counter does not have an _Total instance
NOTE (07:19:56.478) RainmeterProcess\RainmeterProcessNew.ini - [MeasureUsedCPU]: Percent=1 was set on counter:% temps processeur but that counter does not have an _Total instance
NOTE (07:19:56.478) RainmeterProcess\RainmeterProcessNew.ini - [MeasureUsedCPU]: Percent=1 was set on counter:% temps processeur but that counter does not have an _Total instance
ERRO (07:19:57.445) : UsageMonitor crashed trying to update the counterss
DBUG (07:19:57.445) : L'élément a déjà été ajouté. Clé du dictionnaire : 'taille virtuelle (octets)'  Clé ajoutée : 'taille virtuelle (octets)'
DBUG (07:19:57.446) :    à System.Collections.Hashtable.Insert(Object key, Object nvalue, Boolean add)

   à System.Collections.DictionaryBase.System.Collections.IDictionary.Add(Object key, Object value)

   à System.Diagnostics.CategorySample.ReadCategory()

   à UsageMonitor.Categories.Counters.UpdateCategory(String category)
NOTE (07:19:57.456) RainmeterProcess\RainmeterProcessNew.ini - [MeasureUsedCPU]: Percent=1 was set on counter:% temps processeur but that counter does not have an _Total instance
PerfMon.zip
I was expecting that file to have a duplicate somewhere or to have a weird french char that caused an issue but somehow it does not. The bug I have isolated has to be in Microsoft's code but I want to find why. (Also don't worry about apologizing, I am more worried I am wasting your time)
Remember how a few weeks back you uploaded a file for us here https://forum.rainmeter.net/viewtopic.php?p=146411#p146411 think you could do the same thing but instead upload it from the key HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows NT\CurrentVersion\Perflib\CurrentLanguage I am trying to figure out what on these machines is causing this crash so we can either remove it or work around it because as it stands right now my potential replacement for that MS code relies on other MS code (Which may still crash) and is really really inefficient because of a poor design choice by MS.
User avatar
sephirotess
Posts: 332
Joined: December 8th, 2016, 6:45 am

Re: New UsageMonitor plugin

Post by sephirotess »

tjhrulz wrote:I was expecting that file to have a duplicate somewhere or to have a weird french char that caused an issue but somehow it does not. The bug I have isolated has to be in Microsoft's code but I want to find why. (Also don't worry about apologizing, I am more worried I am wasting your time)
Remember how a few weeks back you uploaded a file for us here https://forum.rainmeter.net/viewtopic.php?p=146411#p146411 think you could do the same thing but instead upload it from the key HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows NT\CurrentVersion\Perflib\CurrentLanguage I am trying to figure out what on these machines is causing this crash so we can either remove it or work around it because as it stands right now my potential replacement for that MS code relies on other MS code (Which may still crash) and is really really inefficient because of a poor design choice by MS.
Hi,

I put the counters in the zip. I hope that's what you wanted and not the huge registry key :confused:.
You do not have the required permissions to view the files attached to this post.
User avatar
SilverAzide
Rainmeter Sage
Posts: 2611
Joined: March 23rd, 2015, 5:26 pm

Re: New UsageMonitor plugin

Post by SilverAzide »

tjhrulz wrote:Yeah somtimes Percent=1 can cause it to say it is invalid for the alias when it is not for a little bit when first loaded the skin so I still need to fix that. But yeah I will fix the disabled thing tonight.
Yes I think I see what you are describing, I get the following error message:
Percent=1 was set on counter:% Processor Time but that counter does not have an _Total instance

Code: Select all

[MeasureCPU]
Measure=Plugin
Plugin=UsageMonitor
Alias=CPU
Index=1
(i.e., no Percent=1 is set explicitly)
Gadgets Wiki GitHub More Gadgets...
User avatar
jsmorley
Developer
Posts: 22630
Joined: April 19th, 2009, 11:02 pm
Location: Fort Hunt, Virginia, USA

Re: New UsageMonitor plugin

Post by jsmorley »

sephirotess wrote:Once again, thank you very much for your time.

As we expected, the new version does not work on a French Windows. As I mentioned in my first message, the problem is the same as with "NomFerp". I got the same error message: "L'élément a déjà été ajouté. Clé du dictionnaire...". We did tests with another skin designer (Yincognito), on different French Windows (XP, Vista, 7, 8 and 10). The plugin was partially running on an old XP (Service Pack2), but not on other systems. Your plugin seems to work in the same way as "NomFerp".
To be clear, are you saying that the plugin also doesn't work right on a computer owned by Yincognito, which is also in native French? I'm trying hard to understand if this is a problem with "French", or a problem with your computer or computers.

What I'm struggling with is that tjhrulz has created a VM and installed Windows and the French language. When he is running Windows in French, the plugin is working fine. The key to this is figuring out why it does for him and not for you. What is the difference?
User avatar
sephirotess
Posts: 332
Joined: December 8th, 2016, 6:45 am

Re: New UsageMonitor plugin

Post by sephirotess »

jsmorley wrote:To be clear, are you saying that the plugin also doesn't work right on a computer owned by Yincognito, which is also in native French? I'm trying hard to understand if this is a problem with "French", or a problem with your computer or computers.

What I'm struggling with is that tjhrulz has created a VM and installed Windows and the French language. When he is running Windows in French, the plugin is working fine. The key to this is figuring out why it does for him and not for you. What is the difference?
The test that I realized with Yincognito concerned "NomFerp", not the current plugin. The fact is that the 2 plugins react in the same way on a French Windows (same error message). That's why I talked about this reference. Yincognito uses an English system, but it is for tests (NomFerp), he installed French windows (on virtual machines).

For your other question, there is a difference between using a Windows 100% French and a English Windows with a French language pack. The English Windows retains its English references as well as its construction (which seems different in French).
User avatar
jsmorley
Developer
Posts: 22630
Joined: April 19th, 2009, 11:02 pm
Location: Fort Hunt, Virginia, USA

Re: New UsageMonitor plugin

Post by jsmorley »

sephirotess wrote:The test that I realized with Yincognito concerned "NomFerp", not the current plugin. The fact is that the 2 plugins react in the same way on a French Windows (same error message). That's why I talked about this reference. Yincognito uses an English system, but it is for tests (NomFerp), he installed French windows (on virtual machines).

For your other question, there is a difference between using a Windows 100% French and a English Windows with a French language pack. The English Windows retains its English references as well as its construction (which seems different in French).
NomFerp is using an entirely different approach to localization, and as far as I know, it never really worked, in any language other than English.

So we don't have any example except for you of a system that is installed natively in French. This is hard for us, as determining if the problem is with your system, or all systems installed in French, is key to solving this.
User avatar
sephirotess
Posts: 332
Joined: December 8th, 2016, 6:45 am

Re: New UsageMonitor plugin

Post by sephirotess »

jsmorley wrote:NomFerp is using an entirely different approach to localization, and as far as I know, it never really worked, in any language other than English.

So we don't have any example except for you of a system that is installed natively in French. This is hard for us, as determining if the problem is with your system, or all systems installed in French, is key to solving this.

You are right. If other people could test the plugin on a French system, you would be sure that there is a problem with a French Windows. I tested the plugin on 2 different Windows 10 (different versions) and the result is always the same (as for NomFerp with Vista, 7 and 8).

NomFerp was working on other non-English systems, but with translations, if I'm not saying nonsense.
User avatar
jsmorley
Developer
Posts: 22630
Joined: April 19th, 2009, 11:02 pm
Location: Fort Hunt, Virginia, USA

Re: New UsageMonitor plugin

Post by jsmorley »

sephirotess wrote:You are right. If other people could test the plugin on a French system, you would be sure that there is a problem with a French Windows. I tested the plugin on 2 different Windows 10 (different versions) and the result is always the same (as for NomFerp with Vista, 7 and 8).

NomFerp was working on other non-English systems, but with translations, if I'm not saying nonsense.
I'm literally not interested in NomFerp, that just clouds the issue without helping. In fact, be entirely sure you don't have any skins running NomFerp loaded while you test. I'd prefer it if you just deleted NormFerp entirely, or moved the plugin .dll and restarted Rainmeter.

So you have at least two entirely separate physical computers, both running Windows 10, both installed natively in French, and UsageMonitor won't work on either of them?
User avatar
sephirotess
Posts: 332
Joined: December 8th, 2016, 6:45 am

Re: New UsageMonitor plugin

Post by sephirotess »

jsmorley wrote:I'm literally not interested in NomFerp, that just clouds the issue without helping. In fact, be entirely sure you don't have any skins running NomFerp loaded while you test. I'd prefer it if you just deleted NormFerp entirely, or moved the plugin .dll and restarted Rainmeter.

So you have at least two entirely separate physical computers, both running Windows 10, both installed natively in French, and UsageMonitor won't work on either of them?
I do not use NormFerp, because it does not work on a French Windows, so I do not have it in my system. Sorry to have talked about it, but since the error messages are the same, it seemed interesting that I talk about it. Obviously, it was not a good idea ...

For my Windows, they are on the same PC. These are different versions (build). I did not try on another PC. The machine is not the problem in this case.