Jump to content

Integration Fails: "Retrying setup: Invalid XML response from ISY"


Recommended Posts

Posted

Hi everyone. I've just started on a Home Assistant setup, with the primary goal of getting my ISY devices into it. Unfortunately, I can't get the ISY integration to work. I add it, and it seems to at least pick up on the name of the controller, but it ends up with:

Retrying setup: Invalid XML response from ISY; Ensure the ISY is running the latest firmware: ISY Could not parse response, poorly formatted XML.

I've tried with TLS 1.1 and TLS 1.2 (but I'm just using HTTP with the IP address, e.g. http://192.168.1.x:80)

The Home Assistant log just has entries like this:

2022-10-28 11:48:10.813 WARNING (MainThread) [homeassistant.config_entries] Config entry 'My Lighting (192.168.1.x)' for isy994 integration not ready yet: Invalid XML response from ISY; Ensure the ISY is running the latest firmware: ISY Could not parse response, poorly formatted XML.; Retrying in background
2022-10-28 11:48:25.349 ERROR (MainThread) [pyisy] ISY Could not parse response, poorly formatted XML.: NetworkResources
2022-10-28 11:48:43.569 ERROR (MainThread) [pyisy] ISY Could not parse response, poorly formatted XML.: NetworkResources
2022-10-28 11:49:12.830 ERROR (MainThread) [pyisy] ISY Could not parse response, poorly formatted XML.: NetworkResources

When I manually GET the config from the ISY using CURL, the responses look fine (/rest/config, /rest/nodes, /rest/sys, /rest/programs, etc). I don't know if there's a way to tell which call is actually returning "poorly formatted XML".

I've got a few dozen nodes, scenes, plenty of programs, variables of both types, etc. The ISY994 is running v5.3.4.

I'm kind of at a loss right now. Hopefully someone has some insights!

Thanks!

Posted

Do you have  at least one Program, one state variable and one integer variable?  If not, try adding at least one of each.  I ran into a similar problem adding an empty Polisy to HA.  The program doesn't actually need to do anything meaningful it just needs to exist.  Based on some testing I did following that incident I believe on the program preventing it.

Posted (edited)

I enabled more logging and can see a bit more information:

2022-10-28 13:53:50.302 INFO (MainThread) [pyisy] ISY Loaded Clock Information
2022-10-28 13:53:50.378 INFO (MainThread) [pyisy] ISY Loaded/Updated Programs
[...truncated a couple dozen of these lines...]
2022-10-28 13:53:50.385 INFO (MainThread) [pyisy] ISY Loaded/Updated Programs
2022-10-28 13:53:50.391 INFO (MainThread) [pyisy] ISY Loaded Variables
2022-10-28 13:53:50.391 ERROR (MainThread) [pyisy] ISY Could not parse response, poorly formatted XML.: NetworkResources
2022-10-28 13:53:50.396 WARNING (MainThread) [homeassistant.config_entries] Config entry 'My Lighting (192.168.1.x)' for isy994 integration not ready yet: Invalid XML response from ISY; Ensure the ISY is running the latest firmware: ISY Could not parse response, poorly formatted XML.; Retrying in background

So it looks like it is getting the programs and variables and it's only after that point that it runs into the problem.

In pyisy, after the programs and variables are loaded it loads network resources, which seems to go along with the "Could not parse response, poorly formatted XML.: NetworkResources" line in the logs.

But using CURL to GET 192.168.1.x/rest/networking/resources works fine, so I'm still not sure why the HA integration is failing there.

Edited by phoenix96
Posted

Good news, I figured it out! So it turns out that although /rest/networking/resources returned a result and it looked alright, it wasn't in fact valid XML - because it left unescaped ampersands in the names of some of the NetRules. So this was actually apparently the fault of the ISY rather than the HA integration.

I removed the ampersands from the names of those network resources and the integration then loaded correctly.

  • Like 1
  • 1 month later...
Posted

I'm getting the same thing....how did you identify the exact culprit?

Logger: pyisy
Source: components/isy994/__init__.py:180
First occurred: November 28, 2022 at 1:30:20 PM (942 occurrences)
Last logged: 10:29:57 AM

ISY Could not parse response, poorly formatted XML.: NetworkResources

 

Posted
1 hour ago, atmarosi said:

I'm getting the same thing....how did you identify the exact culprit?

Logger: pyisy
Source: components/isy994/__init__.py:180
First occurred: November 28, 2022 at 1:30:20 PM (942 occurrences)
Last logged: 10:29:57 AM

ISY Could not parse response, poorly formatted XML.: NetworkResources

 

The easiest way is to use a web browser and go to http://yourisyipaddress/rest/networking/resources

Use something like https://www.xmlvalidation.com/ to show you where the problem is.

  • Like 1
  • Thanks 1
Guest
This topic is now closed to further replies.

×
×
  • Create New...