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

Change mqtt lights to new schema attribute #689

Merged
merged 2 commits into from
Dec 13, 2018
Merged

Change mqtt lights to new schema attribute #689

merged 2 commits into from
Dec 13, 2018

Conversation

cbrherms
Copy link
Contributor

@cbrherms cbrherms commented Dec 12, 2018

Repull of #656

Original pull blurb:

This pull is in prep for Homeassistant 0.84 when light.mqtt_json will become a schema for mqtt.light.

As noted in #646 mqtt_json lights are not showing in the mqtt config entry (configuration -> integrations).
light.mqtt_json is now being incorporated in to light.mqtt (This is a breaking change as mqtt_json platform now errors in 0.84).

This pull makes the minor change to lights exposed via mqtt discovery to use the new "schema": attribute, allowing HA to set them up in the correct manner while also allowing the entities to be added to the entity registry. This will then in turn make them appear in the device registry once that pull is merged from dev to master in 0.84.

If used against 0.83.3 the entity will show up in the entity registry correctly but the light will be only a basic light so this has only been tested against the dev branch. Can be tested against master / merged once 0.84 is released.

  • Refactored for new schema attribute added in pull 18227

@Koenkk
Copy link
Owner

Koenkk commented Dec 13, 2018

Can you run npm run docgen to fix the checks? Then this can be merged.

@Koenkk
Copy link
Owner

Koenkk commented Dec 13, 2018

Thanks 😄

@Koenkk Koenkk merged commit b59afbd into Koenkk:dev Dec 13, 2018
Koenkk added a commit that referenced this pull request Dec 14, 2018
qm3ster pushed a commit to zigbeer/zigbeer that referenced this pull request Mar 11, 2019
wilmardo pushed a commit to wilmardo/zigbee2mqtt that referenced this pull request Sep 26, 2019
* Change mqtt lights to new schema attribute

* Update docs
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.

2 participants