Use constants from const.py (#21068)

* Use constants from const.py

* Fix lint issues
This commit is contained in:
Fabian Affolter 2019-02-19 14:09:06 +01:00 committed by GitHub
parent 9d3eaada27
commit 2d2c6cf4a1
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
21 changed files with 105 additions and 188 deletions

View file

@ -1,15 +1,11 @@
"""
Support for Etherscan sensors.
For more details about this platform, please refer to the documentation at
https://home-assistant.io/components/sensor.etherscan/
"""
"""Support for Etherscan sensors."""
from datetime import timedelta
import voluptuous as vol
from homeassistant.components.sensor import PLATFORM_SCHEMA
from homeassistant.const import ATTR_ATTRIBUTION, CONF_NAME
from homeassistant.const import (
ATTR_ATTRIBUTION, CONF_ADDRESS, CONF_NAME, CONF_TOKEN)
import homeassistant.helpers.config_validation as cv
from homeassistant.helpers.entity import Entity
@ -17,8 +13,6 @@ REQUIREMENTS = ['python-etherscan-api==0.0.3']
ATTRIBUTION = "Data provided by etherscan.io"
CONF_ADDRESS = 'address'
CONF_TOKEN = 'token'
CONF_TOKEN_ADDRESS = 'token_address'
SCAN_INTERVAL = timedelta(minutes=5)