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 device info to Chromecast #16261

Merged
merged 1 commit into from
Aug 29, 2018
Merged

Add device info to Chromecast #16261

merged 1 commit into from
Aug 29, 2018

Conversation

balloob
Copy link
Member

@balloob balloob commented Aug 29, 2018

Description:

Add device info to Chromecast.

        "devices": [
            {
                "config_entries": [
                    "da9310b48d94474088d0f26e7cca851a"
                ],
                "connections": [],
                "id": "102d6511c8794ad5884a38cf4377beeb",
                "identifiers": [
                    [
                        "cast",
                        "ae7943b2dcfb1"
                    ]
                ],
                "manufacturer": "Google Inc.",
                "model": "Google Home",
                "name": "Keuken",
                "sw_version": null
            }
        ]

Checklist:

  • The code change is tested and works locally.
  • Local tests pass with tox. Your PR cannot be merged unless tests pass


return {
'name': cast_info.friendly_name,
'identifiers': [
Copy link
Member

Choose a reason for hiding this comment

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

Identifiers should be set with tuples

Copy link
Member Author

Choose a reason for hiding this comment

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

Tuples with 1 entry are very error prone, as the comma is what makes it the tuple. We can pass in list because DeviceEntry will convert it to a set anyway.

Copy link
Member

Choose a reason for hiding this comment

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

Ok, then perhaps I should update deconz to do the same?

Copy link
Member Author

Choose a reason for hiding this comment

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

Made them sets. You're right that it's better to stay in line with how they will end up on the device.

@balloob balloob merged commit 3934f7b into dev Aug 29, 2018
@balloob balloob deleted the dev-info-cast branch August 29, 2018 13:46
@ghost ghost removed the in progress label Aug 29, 2018
girlpunk pushed a commit to girlpunk/home-assistant that referenced this pull request Sep 4, 2018
@balloob balloob mentioned this pull request Sep 17, 2018
@home-assistant home-assistant locked and limited conversation to collaborators Dec 10, 2018
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.

None yet

4 participants