rospogrigio / localtuya

local handling for Tuya devices
GNU General Public License v3.0
2.96k stars 563 forks source link

OSError: [Errno 113] Connect call failed - Combo-Smoke and Carbon Monoxide Alarm #697

Open Belcraig opened 2 years ago

Belcraig commented 2 years ago

The problem

Have added a "Combo - Combination smoke and Carbon Monoxide Alarm [CS01]. to my "smart life" app. Works as expected. I've tried to add it as a local integration when selecting the add integration the device show up in the list. Selecting and adding the details, Local key obtained from the tuya IoT but I get the error listed in the topic. Using both 3.1 and 3.3. the item is connected to the internet as it show up in the app. Wasn't using the Cloud Tuya app but have installed it to see if improved

Environment

Steps to reproduce

Configuration--> Integrations--> add integration --> localtuya integration --> select device from list or select manual addition --> enter details local key from device details from IoT platform --> click submit

Configuration configuration.yaml or config_flow

Home assistant log.txt

Provide Home Assistant taceback/logs

Log file.txt

Additional information

dedepene commented 2 years ago

I get the same error, only my devices are Ledvance lights with extracted local key. They work fine with the local tuya integration, and this error only starts appearing when I take a device offline. I get a HA log entry like this every minute, and it's getting a bit spammy....

2022-02-03 11:14:44 ERROR (MainThread) [custom_components.localtuya.common] [bf6...xry] Connect to 192.168.1.74 failed Traceback (most recent call last): File "/config/custom_components/localtuya/common.py", line 145, in _make_connection self._interface = await pytuya.connect( File "/config/custom_components/localtuya/pytuya/__init__.py", line 669, in connect _, protocol = await loop.create_connection( File "/usr/local/lib/python3.9/asyncio/base_events.py", line 1056, in create_connection raise exceptions[0] File "/usr/local/lib/python3.9/asyncio/base_events.py", line 1041, in create_connection sock = await self._connect_sock( File "/usr/local/lib/python3.9/asyncio/base_events.py", line 955, in _connect_sock await self.sock_connect(sock, address) File "/usr/local/lib/python3.9/asyncio/selector_events.py", line 502, in sock_connect return await fut File "/usr/local/lib/python3.9/asyncio/selector_events.py", line 537, in _sock_connect_cb raise OSError(err, f'Connect call failed {address}') OSError: [Errno 113] Connect call failed ('192.168.1.74', 6668)

Xitee1 commented 2 years ago

I also get that error. I have only one device set up with local tuya and I get this error every time when home assistant starts. However the switch works normal. There is just this error in the logs.