-
-
Notifications
You must be signed in to change notification settings - Fork 33.8k
Use voluptuous for mysensors #2992
8000New 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
Use voluptuous for mysensors #2992
Conversation
I don't think so. |
* Add voluptuous config validation for mysensors * Remove and clean up parts that are not needed for pymysensors 0.7.
1f1b5fa
to
77028c9
Compare
Hmm, when I test to config a |
vol.Required(CONF_GATEWAYS): vol.All(cv.ensure_list, [ | ||
{ | ||
vol.Required(CONF_DEVICE): cv.string, | ||
vol.Optional(CONF_PERSISTENCE_FILE): cv.string, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Persistence_FIle is optionsal, but CONF_PERSISTENCE defaults to true. How does the SerialGateway behave if told to persist without a file?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
That behavior is still left later in the code. I'm using the index of the gateways to set different default filenames, to not overwrite. Any suggestion how I could solve that in voluptuous?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
hrm... well we could move persist to the same level as the persistence file - that would allow you to persist some devices, and not others - more granularity
T-Minus 10 hours until we release 0.27. It would be great if this could make it in time, but no rush if it can't, please don't stress :) |
@robbiet480 Yes, I'll have a look at solving @Teagan42 's question, but everything should be working as it is now, so should be able to get this in before time T. |
I suggest we merge this as is, and I can look if it's possible to move the persistence file name creation to the config validation, later. I'll leave the decision up to y'all. I'll be at a birthday party the rest of the day, so probably AFK. |
Issue created for persistence file @MartinHjelmare |
Description:
Question:
@fabaff Do we need to add something to mysensors platforms that are not configured individually? All configuration for mysensors is done through the component.
Related issue (if applicable):
#2800
Example entry for
configuration.yaml
(if applicable):Checklist:
If code communicates with devices, web services, or a:
tox
run successfully. Your PR cannot be merged unless tests pass