gdgib / span

SPAN Integration for HomeAssistant/HACS
Other
19 stars 4 forks source link

500 error during circuit priority change #10

Open gdgib opened 1 year ago

gdgib commented 1 year ago

As mentioned on #4 both @etmelvin and myself get 500 errors when attempting to change the priority of a circuit. However, since neither of us have a battery, our theory is that circuit priority only works when there's a battery installed. Given that the span UI and this integration BOTH get 500 errors this seems reasonable.

If anyway has a battery and 2min, could you:

  1. Attempt to change circuit priority using this HACS integration? If it works, I'll be very happy.
  2. Attempt to change circuit priority using the SPAN local UI. I'd be curious to see if that works, too.
gdgib commented 1 year ago

@jeffkibuule if you have a battery connected to your span would you be so kind as to try the two things in this issue?

You seem skilled & dedicated, and I could really use a test partner on this one.

etmelvin commented 1 year ago

I just got batteries installed a couple days ago and the API is still throwing 500 errors even when I can see my batteries and the re-prioritization options in the Span app.

From Span Panel's local web server, when attempting to change the circuit priority through its circuit page yields the same issue. Once you made a change via the drop down, refreshing the back will reset it to its previously set value.

This looks like a broken API on Span's side. Hopefully we'll get more information on the fix.

gdgib commented 1 year ago

Good to know! Thanks for reporting. That's a bit unexpected that their local web app is broken, though. Dang.

mbbush commented 1 year ago

Unfortunately this is a regression/bug in the on-device code which implements the local API. There's nothing the home assistant integration can do about it. We've got a ticket documenting it internally, but I can't promise any timelines for a fix, other than to say that I am personally embarrassed that what was once working is now broken.

nathan-curtis commented 1 year ago

@mbbush - any update on that ticket? See next. @gdgib - finally have time to work on the logs you asked for - but waiting on Matthew's response to see if firmware re this has pushed if so, what ver. is required. Let me know if you need anything collected.

nathan-curtis commented 11 months ago

@mbbush Do you know if spanos2/r202342/04 fixes this?

gdgib commented 9 months ago

This error is still happening for me as of 30seconds ago even when I use the SPAN UI, so this isn't something I can fix in the integration.

If anyone with a battery would care to check whether they get a 500 when setting priority through the SPAN UI (navigate to the IP address of your panel, click Circuits and try changing something with the browser dev console open that would be lovely.

gdgib commented 8 months ago

Can confirm this is still an issue. Even weirder: when I use the app to change what's a must have vs non-essential circuit, I could mark a circuit must have and the website reflected that, but when I changed it back, the web site still said "must have" even though it now allowed to control the breaker.

Something ain't right. Leaving this open. I rather suspect we'll have to wait for firmware changes, or I may have to get clever about intercepting app traffic (which I really don't wanna do)

AngellusMortis commented 7 months ago

I do not have my batteries or solar hooked up yet, but definitely getting a 500 from the Span Gateway when trying to change the circuits.

gdgib commented 7 months ago

Thanks @AngellusMortis ! Please let us know when you get both batteries and solar hooked up. If you still see 500s after that, it would be a sign that this is a firmware bug.

AngellusMortis commented 7 months ago

Got the batteries hooked up. Still gives the 500 errors in the Web UI. Works on the app though.