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

Make is_on optional #79

Closed
wants to merge 1 commit into from
Closed

Conversation

Sikerdebaard
Copy link

@Sikerdebaard Sikerdebaard commented Jul 13, 2024

The is_on bool is unavailable on some remotes/controllers, which causes Pydantic to crash the app. This change makes is_on optional.

Tested on STYRBAR E2002 and SYMFONISK sound remote gen2 E2123.

The is_on function is unavailable on some remotes/controllers, which causes Pydantic to crash the app.
Copy link
Owner

@Leggin Leggin left a comment

Choose a reason for hiding this comment

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

Thank you for your PR!

@@ -5,7 +5,7 @@


class ControllerAttributes(Attributes):
is_on: bool
is_on: bool = None
Copy link
Owner

Choose a reason for hiding this comment

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

please use the same syntax as with other optionals here:
Optional[bool] = None

@Leggin
Copy link
Owner

Leggin commented Sep 2, 2024

solved in #86

@Leggin Leggin closed this Sep 2, 2024
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