RulesEngine.cs errors every second in log

  • 65 Views
  • Last Post 30 September 2013
Axial-User posted this 30 September 2013

Ok support ticket created and db attached. Would be great if DB was an XML file instead of binary


Great for who? XML would be slower, though maybe with a limited set of data that's OK... plus, I'd have to write an XML engine that can do what the SDF can do.

There are apps available to open and view the data in the db. MS Sql Studio Express is one -- it's free too.

Order By: Standard | Newest | Votes
Ryan-Scott posted this 30 September 2013

Please see excerpt of log file below. I just installed the latest software on a series 2 stick tonight. incontrol pro version.
I have 6 scenes, 3 to turn sets of things on 3 to turn them off. All have time triggers, daily recurring.


at MLS.ZWave.Service.Rules.RulesEngine.processRules() in z:\work\mls\MLS.ZWave.Controller\MLS.ZWave.Service\Rules\RulesEngine.cs:line 113
at MLS.ZWave.Service.Rules.RulesEngine.b__8() in z:\work\mls\MLS.ZWave.Controller\MLS.ZWave.Service\Rules\RulesEngine.cs:line 304
9/30/2013 1:50:01 AM: Error during processRules/reloadRules(). Restarting reloadRules(). - System.NullReferenceException
Object reference not set to an instance of an object.


Which version of InControl are you using? It shows you at the top in your titlebar - if it's not 3.35, you can get that one from http://www.incontrolzwave.com/page/Download.aspx. That error happens when you have a "device at state condition" that has a value which wasn't set, but it should be fixed in the latest version.

Axial-User posted this 30 September 2013

I was using a version older than 3.35, I stopped the service, installed 3.35, deleted the log file, restarted the service (I run it in service mode) and I have the same issue (different source lines).

Is there a log that tells us which scene, trigger, or device is causing a problem?


9/30/2013 11:24:49 AM: Error during processRules/reloadRules(). Restarting reloadRules(). - System.NullReferenceException
Object reference not set to an instance of an object.

at MLS.ZWave.Service.Rules.RulesEngine.processRules() in z:\work\mls\MLS.ZWave.Controller\MLS.ZWave.Service\Rules\RulesEngine.cs:line 116
at MLS.ZWave.Service.Rules.RulesEngine.ba() in z:\work\mls\MLS.ZWave.Controller\MLS.ZWave.Service\Rules\RulesEngine.cs:line 319
9/30/2013 11:24:54 AM: Error during processRules/reloadRules(). Restarting reloadRules(). - System.NullReferenceException
Object reference not set to an instance of an object.

at MLS.ZWave.Service.Rules.RulesEngine.processRules() in z:\work\mls\MLS.ZWave.Controller\MLS.ZWave.Service\Rules\RulesEngine.cs:line 116
at MLS.ZWave.Service.Rules.RulesEngine.b
a() in z:\work\mls\MLS.ZWave.Controller\MLS.ZWave.Service\Rules\RulesEngine.cs:line 319
9/30/2013 11:24:59 AM: Error during processRules/reloadRules(). Restarting reloadRules(). - System.NullReferenceException
Object reference not set to an instance of an object.

at MLS.ZWave.Service.Rules.RulesEngine.processRules() in z:\work\mls\MLS.ZWave.Controller\MLS.ZWave.Service\Rules\RulesEngine.cs:line 116
at MLS.ZWave.Service.Rules.RulesEngine.ba() in z:\work\mls\MLS.ZWave.Controller\MLS.ZWave.Service\Rules\RulesEngine.cs:line 319
9/30/2013 11:25:01 AM: Service base running
9/30/2013 11:25:02 AM: Original FolderC:\Windows\system32
9/30/2013 11:25:02 AM: Changed to:C:\Program Files\Moonlit Software, LLC\InControl HA
9/30/2013 11:25:02 AM: Starting Service
9/30/2013 11:25:02 AM: Preparing service base
9/30/2013 11:25:02 AM: Original FolderC:\Program Files\Moonlit Software, LLC\InControl HA
9/30/2013 11:25:02 AM: Changed to:C:\Program Files\Moonlit Software, LLC\InControl HA
9/30/2013 11:25:02 AM: Running service base
9/30/2013 11:25:03 AM: Starting version 3.35.5014.14446
ZenLib: False
StickType:OpenZWave
ComPort:3
Service:True
9/30/2013 11:25:03 AM: Error during processRules/reloadRules(). Restarting reloadRules(). - System.NullReferenceException
Object reference not set to an instance of an object.

at MLS.ZWave.Service.Rules.RulesEngine.processRules() in z:\work\mls\MLS.ZWave.Controller\MLS.ZWave.Service\Rules\RulesEngine.cs:line 116
at MLS.ZWave.Service.Rules.RulesEngine.b
a() in z:\work\mls\MLS.ZWave.Controller\MLS.ZWave.Service\Rules\RulesEngine.cs:line 319
9/30/2013 11:25:04 AM: Loaded Plugin HaFoscamController
9/30/2013 11:25:04 AM: Loaded Plugin VirtualHaController
9/30/2013 11:25:04 AM: Loaded Plugin WeatherDevicePlugin
9/30/2013 11:25:05 AM: DirectConnect: New client connected from 127.0.0.1
9/30/2013 11:25:07 AM: Weather plugin using coordiates ,
9/30/2013 11:25:08 AM: Error during processRules/reloadRules(). Restarting reloadRules(). - System.NullReferenceException
Object reference not set to an instance of an object.

at MLS.ZWave.Service.Rules.RulesEngine.processRules() in z:\work\mls\MLS.ZWave.Controller\MLS.ZWave.Service\Rules\RulesEngine.cs:line 116
at MLS.ZWave.Service.Rules.RulesEngine.b__a() in z:\work\mls\MLS.ZWave.Controller\MLS.ZWave.Service\Rules\RulesEngine.cs:l

Axial-User posted this 30 September 2013

Since the error is in RulesEngine.cs I looked at the rules, I have a rule "4pm lights" which I do not need but am not able to delete. Is there any way to delete rules if the GUI won't delete them?

Axial-User posted this 30 September 2013

Ok I was finally able to delete that rule by going in and deleting conditions in the rule. I restarted the services and still get the error. I have NO rules enabled, and only the 3 default rules that come with the system in there (sunrise, sunset, vacation).

Axial-User posted this 30 September 2013

Also - triggers are not making scenes activate.

Ryan-Scott posted this 30 September 2013

Also - triggers are not making scenes activate.


What kinds of conditions do you have set on your current triggers? Can you send me a screen shot of each one or describe what they "say" when you open each one up? Finally... were you using version 3.35 when you created the conditions?

Axial-User posted this 30 September 2013

Also - triggers are not making scenes activate.

What kinds of conditions do you have set on your current triggers? Can you send me a screen shot of each one or describe what they "say" when you open each one up? Finally... were you using version 3.35 when you created the conditions?


I was mistakenly using conditions when I first started, at some point I figured out what I needed was just scenes that are triggered, one scene for turning things on one for turning things off. Triggers are repeating time-based. At some point I saw somewhere that conditions are just limits on when other things happen (so apparently a trigger will be ignored if there is a condition that overrides it).

I want a scene to turn on a set of lights at 4pm and another to turn them off at 6am, etc.

Do you still need screenshots of conditions since I have none, and I don't use rules.

All I have is 6 scenes, 3 pairs, each pair turns a set of switches on and off based on recurring time triggers.

Axial-User posted this 30 September 2013

And yes, when I first created the conditions they were in the older version (the most recent one that the autoupdate function installs when you first install the version that the purchase e-mail gives you).

Ryan-Scott posted this 30 September 2013

Also - triggers are not making scenes activate.

What kinds of conditions do you have set on your current triggers? Can you send me a screen shot of each one or describe what they "say" when you open each one up? Finally... were you using version 3.35 when you created the conditions?

I was mistakenly using conditions when I first started, at some point I figured out what I needed was just scenes that are triggered, one scene for turning things on one for turning things off. Triggers are repeating time-based. At some point I saw somewhere that conditions are just limits on when other things happen (so apparently a trigger will be ignored if there is a condition that overrides it).

I want a scene to turn on a set of lights at 4pm and another to turn them off at 6am, etc.

Do you still need screenshots of conditions since I have none, and I don't use rules.

All I have is 6 scenes, 3 pairs, each pair turns a set of switches on and off based on recurring time triggers.


No conditions? Interesting... would you mind sending your database to us by submitting a new support ticket (click "Contact Us" in the menu)? The DB is located in your %ProgramData%\zwave folder (it's a .SDF file).

Axial-User posted this 30 September 2013

Ok support ticket created and db attached. Would be great if DB was an XML file instead of binary

Ryan-Scott posted this 30 September 2013

Ok support ticket created and db attached. Would be great if DB was an XML file instead of binary


Great for who? XML would be slower, though maybe with a limited set of data that's OK... plus, I'd have to write an XML engine that can do what the SDF can do.

There are apps available to open and view the data in the db. MS Sql Studio Express is one -- it's free too.

Axial-User posted this 30 September 2013

Ok support ticket created and db attached. Would be great if DB was an XML file instead of binary

Great for who? XML would be slower, though maybe with a limited set of data that's OK... plus, I'd have to write an XML engine that can do what the SDF can do.

There are apps available to open and view the data in the db. MS Sql Studio Express is one -- it's free too.


Good point I don't really care how you implement your database, I just need this software to work

What do I have to do to fix it?

I don't mind recreating all the scenes.

What is the correct approach? I looked at the online docs, they are not quite complete.

I have the most basic use case here - a certain set of lights is to come on at 4pm and go off at 6am.

It seemed like there were 2 or 3 different ways to accomplish this task in the software (rules, scenes with triggers, and maybe conditions but I think conditions just limit when other things can happen, I'm not sure).

What do you recommend as the simplest way? If I can do something to get this thing working now I'm willing to do it? I'm ok with deleting all the scenes, though I would rather not exclude and include all the devices again (that means I have to go on site - have remote access to the PC with the zstick and prefer to not have to go on site again).

Thanks!

Ryan-Scott posted this 30 September 2013

Based on your DB, it looks like the scene named "Lights 4 PM" is the one that has some corrupt data attached to it. The DB feels there is a condition there, but the UI doesn't concur with it...

Did anything odd happen with the creation of that one? Perhaps you started a condition but somehow aborted it or received an error during the process? Anything you can recall will help fix and prevent it in the future.

To resolve, if you select that scene, choose conditions and then select in the top portion of the table, it'll highlight a blank condition. Remove it and you'll be good to go. You can optionally delete and recreate that scene as well.

Axial-User posted this 30 September 2013

Hmm, I have 2 scenes that have 4pm lights in them:

"4pm lights" (turns a set of lights on at 4pm) "4pm lights off" (turns that set of lights off at 5am)

I may at one point have had a condition or something called "Lights 4 PM" but I have nothing I can see from the GUI by that name right now.

I have no way to delete a scene called "Lights 4 PM" from the GUI. Can you delete it in the DB and send me back the DB?

I don't see how to attach a screenshot here so I put it up here:

http://bteamguild.com/pics/scenes.png

Thanks!

Axial-User posted this 30 September 2013

"4pm lights" had a highlightable blank condition.

Stopped service, deleted log file, started service, no more exceptions in the log.
Will test that the scenes work on triggers now.

Is that the best way to implement the simple use case of

System turns a set of lights on at 4pm and off at 6am?

Thanks

Axial-User posted this 30 September 2013

Verified that the scenes are now triggering based on the time trigger. Thanks for the help.

Is there a way to do level-triggered events instead of edge-triggered? So I would always like this set of lights to be on between these hours and off outside of those hours. Right now with time triggers for a scene, if the service is down when the time rolls around, it misses the trigger and the lights stay in their previous state.

Axial-User posted this 30 September 2013

Problem solved. Solution summary - there was a blank condition in one of the scenes. Had to select it and delete it.
Moving the rest of the question about rules to another post.

Ryan-Scott posted this 30 September 2013

Problem solved. Solution summary - there was a blank condition in one of the scenes. Had to select it and delete it.
Moving the rest of the question about rules to another post.


kk, I'll make a perma fix for this in the next release.

Also, awaiting your question about rules.

Close