Skip to content

Conversation

@tronikos
Copy link
Member

@tronikos tronikos commented May 1, 2025

Breaking change

Proposed change

Use names instead of statistic IDs in the Opower repair issue since the picker now shows names instead of IDs.
Also add a line to skip the issue once done.

Type of change

  • Dependency upgrade
  • Bugfix (non-breaking change which fixes an issue)
  • New integration (thank you!)
  • New feature (which adds functionality to an existing integration)
  • Deprecation (breaking change to happen in the future)
  • Breaking change (fix/feature causing existing functionality to break)
  • Code quality improvements to existing code or addition of tests

Additional information

  • This PR fixes or closes issue: fixes #
  • This PR is related to issue:
  • Link to documentation pull request:
  • Link to developer documentation pull request:
  • Link to frontend pull request:

Checklist

  • The code change is tested and works locally.
  • Local tests pass. Your PR cannot be merged unless tests pass
  • There is no commented out code in this PR.
  • I have followed the development checklist
  • I have followed the perfect PR recommendations
  • The code has been formatted using Ruff (ruff format homeassistant tests)
  • Tests have been added to verify that the new code works.

If user exposed functionality or configuration variables are added/changed:

If the code communicates with devices, web services, or third-party tools:

  • The manifest file has all fields filled out correctly.
    Updated and included derived files by running: python3 -m script.hassfest.
  • New or updated dependencies have been added to requirements_all.txt.
    Updated by running python3 -m script.gen_requirements_all.
  • For the updated dependencies - a link to the changelog, or at minimum a diff between library versions is added to the PR description.

To help with the load of incoming pull requests:

"return_to_grid_migration": {
"title": "Return to grid statistics for account: {utility_account_id}",
"description": "We found negative values in your existing consumption statistics, likely because you have solar. We split those in separate return statistics for a better experience in the Energy dashboard.\n\nPlease visit the [Energy configuration page]({energy_settings}) to add the following statistics in the **Return to grid** section:\n\n{target_ids}"
"description": "We found negative values in your existing consumption statistics, likely because you have solar. We split those in separate return statistics for a better experience in the Energy dashboard.\n\nPlease visit the [Energy configuration page]({energy_settings}) to add the following statistics in the **Return to grid** section:\n\n{target_ids}\n\nOnce you have added them, ignore this issue."
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Can't we get the issue to be automatically removed when we don't detect it anymore ?

Copy link
Member Author

@tronikos tronikos May 5, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

You might have misunderstood the issue.
Historically the Opower integration has been creating a single statistic for both consumption and return to grid. If you returned to the grid it had negative values. Starting with 2025.5.0 we have a separate return to the grid statistic. And we perform a one time migration. We raise this issue so that users update their energy dashboard config and any other manual dashboard they might have. We could check that the user has updated their energy dashboard by checking config/.storage/energy or making API changes in the energy component but it's not something worth doing. And it won't cover manual dashboards users might have.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Do we only open the issue when there has been negative values? That way users without solar won't need to ignore an issue.

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Correct. We migrate and open the issue only if we find at least one negative value.

@balloob balloob merged commit 0043b18 into home-assistant:dev May 5, 2025
30 checks passed
balloob pushed a commit that referenced this pull request May 5, 2025
* Use names instead of statistic IDs in the Opower repair issue

* target_ids
@github-actions github-actions bot locked and limited conversation to collaborators May 6, 2025
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants