Patched webCoRE for Hubitat (2018/09/09)

The webcore interface can be locally hosted as well, eliminating the web aspect entirely.

I think some of this is because webCoRE does not like it when there are inconsistent versions running. I have both ST and Hubitat webCoRE installed. I was getting messages that one of the child apps needed to be ‘updated’ because it’s version # was outdated. I believe it was comparing the ST main webCoRE version to the Hubitat child version. I updated the Hubitat version by changing their version #s to match the ST versions (no other changes to the code was made) by changing one line with that info towards the top of the code. With that change the error went away and I was able to open/edit/save the Hubitat pistons once again. I am now on @ajayjohnm’s latest code that matches the ST version # so that is not a problem at the moment.

1 Like

Is there a thread on how to do this. I wouldn’t mind giving this a try.

1 Like

I see this error on app log “errorDashboard: Authentication failed due to an invalid token”.
Not sure what to do.

What I’ve seen is as I added more pistons HE appeared to respond more slowly. It may not be related, but when I removed WebCoRE things seemed to get better.

I have only two pistons.

I’m getting this error when saving a piston:

An error occurred while executing the event: java.lang.NullPointerException: Cannot get property 'v' on null object

The piston uses variables for devices. Just guessing, but I wonder if “null object” is because webCoRE doesn’t know the actual device at the time of saving the piston? Anyone really know?

I have a few pistons that use variables that store devices that match certain conditions. Have not faced any issues with it yet.
Do you face this error only when saving that particular piston?

Thanks @ajayjohnm. I found the problem: my stupidity. The more detailed explanation is that it was a piston I imported from ST webCoRE and it used a global variable. Of course, the global variable didn’t exist in HE webCoRE and that made it throw up. Once I initialized the global variable… Voila!

1 Like

@ajayjohnm @jp0550

I’m using your ported version and all is great.

One of my pistons is 34 chunks long and very complicated in regards to functions etc… It works perfectly.

I’m going to put a link to the ported GitHub pinned to the top of the new ‘Hubitat’ category on the webCoRE forum.

2 Likes

I have a question regarding WebCoRE on Hubitat. Does Hubitat’s backup and restore include the pistons, since they apparently run locally? The lack of a backup on ST is a major issue why I went to Hubitat, along with the local processing. I am hesitant to use WebCoRE in Hubitat unless the pistons can be backed up and restored.

Yes, webCoRE piston backup and restore works fine on Hubitat locally.

webCoRE’s own backup and restore function also work nicely! The bin codes unlock encrypted backup files stored on the webCoRE servers.

Taking a ST bin code and restoring in HE also works nicely.

Just keep a paper record of your bin codes, for safekeeping.

1 Like

I want to make sure you understood me. If I need to restore my pistons in Hubitat, I only need to do Hubitat's built-in restore? In other words, the Hubitat restore also includes my pistons? I don't like using the WebCoRE backup, because it requires me to manually record all the bin codes.

Yes, using Hubitats restore feature will restore your pistons, drivers, apps etc.

But you should still keep your webCoRE bin codes as a secondary backup… I save a red snapshot of each piston in folder on my computer, with the bin codes at the start of each file name…

I then occasionally take a screenshot of all the file names and print it out.

The red codes don’t change each time you edit a piston (unlike the green codes), so it’s not as much work as it sounds.

2 Likes

Great. Thanks for the prompt reply!

Tried to add some Tiles but alot are just black:

image

And some work fine:
image

can you post the piston snapshot… black is the default background when the chosen color is setup wrong.

1 Like

Just using the pistons from here: Device Tiles - webCoRE Wiki - Web-enabled Community's own Rule Engine

One snapshot:

I'm taking a punt and you probably have something like this.
Change the expression from the name of the colour to the hex value.
I had the same as you and changed it as per the red box.
It now works.

image

EDIT: Only works when it refreshes!!!!!!

2 Likes

Yes, this works! Thanks mate

1 Like