Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

SoC does not get updated #1078

Closed
daniel-zullo-frequenz opened this issue Sep 23, 2024 · 3 comments · Fixed by #1081
Closed

SoC does not get updated #1078

daniel-zullo-frequenz opened this issue Sep 23, 2024 · 3 comments · Fixed by #1081
Assignees
Labels
part:microgrid Affects the interactions with the microgrid priority:high Address this as soon as possible type:bug Something isn't working
Milestone

Comments

@daniel-zullo-frequenz
Copy link
Contributor

daniel-zullo-frequenz commented Sep 23, 2024

What happened?

An application kept reporting 100% SoC while the real SoC queried from the components was around 20%. It seems the application kept the outdated SoC as there wasn't any update for this metric. Apparently the SoC was no longer reported when new PV inverters were added to the microgrid (the PV inverters were reporting only Error state). It took around 5 days to find out about the issue when the components low SoC alert triggered. Unfortunately there is no logs available.

What did you expect instead?

The SoC is reported and it is up-to-date

Affected version(s)

Observed in v1.0.0-rc601

Affected part(s)

Microgrid (API, component graph, etc.) (part:microgrid)

Extra information

The SoC was reported correctly once the application was restarted

@daniel-zullo-frequenz daniel-zullo-frequenz added priority:high Address this as soon as possible type:bug Something isn't working part:microgrid Affects the interactions with the microgrid labels Sep 23, 2024
@llucax
Copy link
Contributor

llucax commented Sep 25, 2024

We observed this issue when the component graph was misconfigured as follows (meter_3 was added to the component graph):

      grid_1
     /        \
meter_2    meter_3

meter_3 was added by mistake and wasn't really a meter at all, so it was reporting no data. Because of this the SDK gave up on calculating the grid load.

This shouldn't affect how the SoC is calculated, but it might be relevant and some unexpected side-effect.

@shsms
Copy link
Contributor

shsms commented Sep 25, 2024

We have tasks that calculate the SoC and stream it. My theory is that the tasks must have crashed because of an exception.

The only real case I can see now is if both soc_upper_bound and soc_lower_bound are equal. I'll add a fix for that.

soc_scaled = (
(soc - soc_lower_bound) / (soc_upper_bound - soc_lower_bound) * 100.0
)

But I am continuing to look for other ways to reproduce.

@llucax
Copy link
Contributor

llucax commented Oct 11, 2024

We are just speculating about #1081 being the fix for this, right? I guess we can still leave it closed and reopen if it happens again.

@llucax llucax added this to the v1.0.0-rc1000 milestone Oct 11, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
part:microgrid Affects the interactions with the microgrid priority:high Address this as soon as possible type:bug Something isn't working
Projects
Development

Successfully merging a pull request may close this issue.

3 participants