mirror of
https://github.com/esphome/esphome.git
synced 2025-09-21 12:42:21 +01:00
Drop Python 2 Support (#793)
* Remove Python 2 support * Remove u-strings * Remove docker symlinks * Remove from travis * Update requirements * Upgrade flake8/pylint * Fixes * Manual * Run pyupgrade * Lint * Remove base_int * Fix * Update platformio_api.py * Update component.cpp
This commit is contained in:
@@ -1,4 +1,3 @@
|
||||
# coding=utf-8
|
||||
from math import log
|
||||
|
||||
import esphome.config_validation as cv
|
||||
@@ -28,7 +27,7 @@ def validate_calibration_parameter(value):
|
||||
value = cv.string(value)
|
||||
parts = value.split('->')
|
||||
if len(parts) != 2:
|
||||
raise cv.Invalid(u"Calibration parameter must be of form 3000 -> 23°C")
|
||||
raise cv.Invalid("Calibration parameter must be of form 3000 -> 23°C")
|
||||
voltage = cv.resistance(parts[0].strip())
|
||||
temperature = cv.temperature(parts[1].strip())
|
||||
return validate_calibration_parameter({
|
||||
|
Reference in New Issue
Block a user