Error Adding Home Assistant

I am switching from Vera to Home Assistant. When I add the Home Assistant device source, it adds fine. But right after that I go to save the HRP file and get an Error pop-up with “There was an error generating the XML document.” Could I have too many items in HA (limit?)? Maybe it doesn’t like that some entities start with a number? Is there a log that would spell out the error?

Designed 4.5.0.0

I just tested mine. I started with a new blank file in designer. I added Home Assistant and everything went well through saving the file. I have I believe a couple thousand devices so I don’t think too many items is an issue. I have items that start with a number so I don’t think that is an issue. There is a log icon at the bottom of the screen but it’s rather limited. Take a look and see if it tells you anything. Try starting with a blank designer file and add Home Assistant and see if it’s successful. This will potentially rule out other things.

Thanks for the reply! I opened the designer, created new blank file, added Home Assistant, clicked on Save, and received the same Error: There was an error generating the XML document. The log appears to be blank/empty.

Is there a way to up the logging level? I can save & modify my HRP files - just not after I add Home Assistant.

I’m not aware of upping the log level. Are you able to add HA and actively use it in THR? It just won’t save?

Yes, I am able to add HA to THR and then use HA in THR to activate z-wave devices… I have only tested on one light switch, but it works as expected. I updated the button from the old Vera device to the HA device and it turns off and on as expected and updates state.

But then I am unable to save the file…

Ok, I’m at the end of my knowledge, hopefully someone else will chime in soon. Sorry I couldn’t help more.

Can you try running THR Designer as an administrator?
Or install THR Designer on another computer and try it there to see if it works.

I tried both run as administrator on existing laptop and did a new install on a Win11 desktop that did not previously have THR Designer - same result when I attempt to add HA - I am unable to save.

And if I “open” the HA device so view its config (internal/external URLs) it also produces the XML error when I close it - even if I didn’t make any changes.

Have you tried to save the THR file on the same computer, that the Designer is located. I had a similar problem, some years ago and it was the connection that was wrong.

1 Like

The other thing to try is to delete the app and reinstall on your phone or tablet, then add it (HA) in the app, then if that works, you backup the app from mobile device to a cloud location, like OneDrive. Then open the backup in the designer on your desktop. I had to do that once.

1 Like

THR is being saved on the same computer as the Designer. I attempted to add HA as a device directly on an Android THR add, and it added fine - but when I closed app and restarted it, all devices were missing including HA.

Something about my HA instance is just incompatible with THR. To me this has to be something related to special characters (of some kind) that screw up the XML. Anyone have an idea of where to look?

Sure, if you just want to test special characters, add your HA to designer and sync. Then go in and delete all devices except one that does not have any special characters. Make sure you sync after. Then try to save. If it saves correctly, this tells you it has something to do with a certain device inside HA. If it doesn’t save, then you can safely rule out the special character theory as a problem.

Okay, here’s what you can try:
Make a copy of your HRP file and rename it with the extension zip (example: test.zip).
Now you can unzip the file and check all XML files for errors (e.g., with Notepad++).
I also assume that it is a “character” error, and perhaps you can identify the device in devices.xml.

Kalle

Did you try just the HA app only on your android?

@KalleVC I love your thought process but he can’t save it.