This adds tests for the influxdb component. It also fixes a bug,
where username and password are required, but not gracefully
handled if they're missing from config.
This also fixes issue #1214, and I think another bug. The splunk
code will just take the value of state.state and try to serialize
it to json if it can't make it into a number. It did this before
I generalized that code. Since json.dumps() will fail on most anything
complicated, I think the right thing to do is *not* try to do that.
This adds state_as_number(), a helper method that tries to interpret
state as a number, for cases we can predict. It's a generalization of
what is copy-and-paste-ed into multiple other places.
* Make light controllable independently with types V_LIGHT, V_DIMMER,
V_RGB and V_RGBW. V_RGBW is not implemented in the frontend yet.
* Add discovery for light platform.
* Add optimistic mode config setting for switch and light
to allow feedback state from actuator.
* Move S_LIGHT, V_LIGHT, V_STATUS types from switch to light platform.
* Change node update logging to debug from info level.
* Fix some inaccurate comments.
This is extremely useful if you want to support wemos that are on
another subnet or across a VPN. It also lets you sidestep the discovery
process, which is problematic for a lot of people and situations.
In order for this to work, we need to bump the pywemo requirement to
0.3.10, which includes my changes to make this possible.
WeMo devices can be manually configured by adding a static section to
the config, like this:
switch:
platform: wemo
static:
- 192.168.100.5
- 192.168.100.6
This extends the HoneywellUSThermostat functionality to find and add
all thermostats in your account. So, we add a new config element called
'region' that is the primary trigger for this, and remove the 'id'
trigger since it was never in a released version.
This does a few extra things:
- It names the thermostat what you have it named in your account,
which is not something we get to know *unless* we emumerate.
- It makes all thermostats on a given account use the same session,
and thus we have to avoid doing an explicit login every time we
refresh our data. That was causing some rate-limiting on their
side when I was debugging, so this is probably good. Now, we use
their existing keepalive pinger to determine if we're still logged
in and only re-login if we need to.