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

Add blog post for entry.runtime_data #2160

Merged
merged 2 commits into from
Apr 30, 2024

Conversation

cdce8p
Copy link
Member

@cdce8p cdce8p commented Apr 30, 2024

Proposed change

Blog post for entry.runtime_data implemented in home-assistant/core#115669.
/CC @frenck

Type of change

  • Document existing features within Home Assistant
  • Document new or changing features which there is an existing pull request elsewhere
  • Spelling or grammatical corrections, or rewording for improved clarity
  • Changes to the backend of this documentation
  • Removed stale or deprecated documentation

Additional information

  • This PR fixes or closes issue: fixes #
  • Link to relevant existing code or pull request:

@joostlek
Copy link
Member

One thing I was also wondering, currently we don't want people to touch hass.data in tests. Is this going to be the same with runtime data?

@frenck
Copy link
Member

frenck commented Apr 30, 2024

One thing I was also wondering, currently we don't want people to touch hass.data in tests. Is this going to be the same with runtime data?

The use is the same on both. It is merely the location is different.

Copy link
Member

@frenck frenck left a comment

Choose a reason for hiding this comment

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

Thanks, @cdce8p 👍

../Frenck

@frenck frenck merged commit 3bb9851 into home-assistant:master Apr 30, 2024
4 checks passed
@cdce8p cdce8p deleted the blog-entry-runtime_data branch April 30, 2024 13:14
@epenet
Copy link
Contributor

epenet commented Apr 30, 2024

Reading this, I wasn't sure how to check if services should be registered and de-registered.
Should there be note to use this?

        loaded_entries: list[MyConfigEntry] = [
            entry
            for entry in hass.config_entries.async_entries(DOMAIN)
            if entry.state == ConfigEntryState.LOADED
        ]

(spotted in home-assistant/core#116454)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

4 participants