esphome-zbbridge icon indicating copy to clipboard operation
esphome-zbbridge copied to clipboard

Fix for latest ESPHome version.

Open 5thsymphony opened this issue 3 years ago • 3 comments

See upstream merge for more info on this refactor:

https://github.com/esphome/esphome/commit/471b82f727e2f698b8879fb51c4161a9cf49d34b

5thsymphony avatar Jan 03 '22 17:01 5thsymphony

Hi @5thsymphony !! I have one WeMos Di Mini that is running the old working version and have updated ESPHome so it not working and was testing your patch but i still getting many errors then trying compiling the firmware. Have ESPHome implanting more new futures that is braking the serial server and the very nice binary sensor ??

MattWestb avatar May 31 '22 10:05 MattWestb

I've tried to use this branch to get it to compile with ESPHome 2022.12.8 however I get the following error:

INFO Reading configuration /config/esphome/sonoff_zbbridge.yaml... ERROR Unable to load component serial_server.binary_sensor: Traceback (most recent call last): File "/esphome/esphome/loader.py", line 162, in _lookup_module module = importlib.import_module(f"esphome.components.{domain}") File "/usr/lib/python3.9/importlib/init.py", line 127, in import_module return _bootstrap._gcd_import(name[level:], package, level) File "", line 1030, in _gcd_import File "", line 1007, in _find_and_load File "", line 986, in _find_and_load_unlocked File "", line 680, in _load_unlocked File "", line 790, in exec_module File "", line 228, in _call_with_frames_removed File "/config/esphome/custom_components/serial_server/binary_sensor.py", line 15, in cv.Optional(CONF_DEVICE_CLASS, default=DEVICE_CLASS_CONNECTIVITY): binary_sensor.device_class, AttributeError: module 'esphome.components.binary_sensor' has no attribute 'device_class' Failed config

fraserp avatar Feb 12 '23 11:02 fraserp

I've tried to use this branch to get it to compile with ESPHome 2022.12.8 however I get the following error:

INFO Reading configuration /config/esphome/sonoff_zbbridge.yaml... ERROR Unable to load component serial_server.binary_sensor: Traceback (most recent call last): File "/esphome/esphome/loader.py", line 162, in _lookup_module module = importlib.import_module(f"esphome.components.{domain}") File "/usr/lib/python3.9/importlib/init.py", line 127, in import_module return _bootstrap._gcd_import(name[level:], package, level) File "", line 1030, in _gcd_import File "", line 1007, in _find_and_load File "", line 986, in _find_and_load_unlocked File "", line 680, in _load_unlocked File "", line 790, in exec_module File "", line 228, in _call_with_frames_removed File "/config/esphome/custom_components/serial_server/binary_sensor.py", line 15, in cv.Optional(CONF_DEVICE_CLASS, default=DEVICE_CLASS_CONNECTIVITY): binary_sensor.device_class, AttributeError: module 'esphome.components.binary_sensor' has no attribute 'device_class' Failed config

Same problem here.

INFO Reading configuration /config/esphome/zb-bridge.yaml... ERROR Unable to load component serial_server.binary_sensor: Traceback (most recent call last): File "/esphome/esphome/loader.py", line 165, in _lookup_module module = importlib.import_module(f"esphome.components.{domain}") File "/usr/lib/python3.9/importlib/init.py", line 127, in import_module return _bootstrap._gcd_import(name[level:], package, level) File "", line 1030, in _gcd_import File "", line 1007, in _find_and_load File "", line 986, in _find_and_load_unlocked File "", line 680, in load_unlocked File "", line 790, in exec_module File "", line 228, in call_with_frames_removed File "/config/esphome/custom_components/serial_server/binary_sensor.py", line 10, in class = ns.class('BinarySensor', binary_sensor.BinarySensor, cg.Nameable) AttributeError: module 'esphome.codegen' has no attribute 'Nameable' Failed config

binary_sensor.serial_server: [source /config/esphome/zb-bridge.yaml:36]

Platform not found: 'binary_sensor.serial_server'. platform: serial_server name: Zigbee to serial

where is the problem?

Jarnsen avatar May 03 '23 07:05 Jarnsen