Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Error communicating with Tapo Camera. Status code: 500 (C210) #442

Closed
rark-ha opened this issue Nov 7, 2023 · 3 comments
Closed

Error communicating with Tapo Camera. Status code: 500 (C210) #442

rark-ha opened this issue Nov 7, 2023 · 3 comments
Labels
Duplicate This issue or pull request already exists

Comments

@rark-ha
Copy link

rark-ha commented Nov 7, 2023

Description

Restarting Home Assistant I suddenly had two cameras not working in the integration. I am getting a Migration Error in the integrations GUI, with the log showing the error;

Error communicating with Tapo Camera. Status code: 500

Trying to set up one of these cameras on my test system I can get the IP and Camera Account done, but the Cloud account step fails (even though the password is the same as the Camera Account, and works for the other 6 cameras still).

The two devices are C210, but I have another couple of these models that are working as expected.

Reproduction Steps

  1. Restart Home Assistant
  2. Two camera's not loading from the integration (6 other camera's loading as expected)
  3. Error Migrating Entry for IP-Address for Tapo Control show in log (full log from main HA system below)

Expected behavior

Device expected to setup as normal.

If applicable, add error logs.

Traceback (most recent call last):
File "/config/custom_components/tapo_control/init.py", line 196, in async_migrate_entry
tapoController = await hass.async_add_executor_job(
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/local/lib/python3.11/concurrent/futures/thread.py", line 58, in run
result = self.fn(*self.args, **self.kwargs)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/config/custom_components/tapo_control/utils.py", line 81, in registerController
return Tapo(host, username, password, password_cloud, super_secret_key, device_id)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/local/lib/python3.11/site-packages/pytapo/init.py", line 66, in init
self.basicInfo = self.getBasicInfo()
^^^^^^^^^^^^^^^^^^^
File "/usr/local/lib/python3.11/site-packages/pytapo/init.py", line 743, in getBasicInfo
return self.executeFunction(
^^^^^^^^^^^^^^^^^^^^^
File "/usr/local/lib/python3.11/site-packages/pytapo/init.py", line 296, in executeFunction
data = self.performRequest(
^^^^^^^^^^^^^^^^^^^^
File "/usr/local/lib/python3.11/site-packages/pytapo/init.py", line 335, in performRequest
self.ensureAuthenticated()
File "/usr/local/lib/python3.11/site-packages/pytapo/init.py", line 86, in ensureAuthenticated
return self.refreshStok()
^^^^^^^^^^^^^^^^^^
File "/usr/local/lib/python3.11/site-packages/pytapo/init.py", line 265, in refreshStok
raise Exception("Invalid authentication data")
Exception: Invalid authentication data

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
File "/usr/src/homeassistant/homeassistant/config_entries.py", line 633, in async_migrate
result = await component.async_migrate_entry(hass, self)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/config/custom_components/tapo_control/init.py", line 225, in async_migrate_entry
raise ConfigEntryNotReady
homeassistant.exceptions.ConfigEntryNotReady: None

Device Firmware

1.3.9 Build 231019 Rel.31045n(4555)

Using stream component

Yes

Does camera work via official integrations?

Yes

Camera has all attributes filled out in developer tools

No

HASS Environment

Docker on Synology NAS

Search for similar issues

Yes

Additional information

No response

@kobrata0912
Copy link

@rark-ha Try using "admin" as a user, regardless of your actual username setup in your camera settings.

@rark-ha
Copy link
Author

rark-ha commented Nov 7, 2023

@rark-ha Try using "admin" as a user, regardless of your actual username setup in your camera settings.

No. That gives me an error when trying to update the config on the main HA instance, and fails with a similar username error when trying to setup the device on my test HA.

@JurajNyiri
Copy link
Owner

JurajNyiri commented Nov 7, 2023

Update to latest version of integration.

#438
#437
#436

@JurajNyiri JurajNyiri added the Duplicate This issue or pull request already exists label Nov 7, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Duplicate This issue or pull request already exists
Projects
None yet
Development

No branches or pull requests

3 participants