Code Monkey home page Code Monkey logo

ha-dyson-cloud's Introduction

Hi there 👋

Buy Me A Coffee

Xiaonan Shen's github stats

ha-dyson-cloud's People

Contributors

pfrybar avatar shenxn avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar

ha-dyson-cloud's Issues

Failed to Connect

Hi All,
I have recently replaced my home router and wifi ssid changed.
I can no longer get my Dyson Cloud & Dyson Local to work. I have uninstalled and reinstalled both integrations and now I cant even get pass the setup screen.
on Dyson Cloud, after enter my region and email address, Im getting "Failed to Connect"
on Dyson Local, im getting "Failed to parse device WiFi information" on wifi setup method.

Please help :(

Thanks.

Failed to set up

I'm able to connect without problem after logging in and out of the mobile app but as soon as the integration is created it crashes with the following logged errors:

Logger: aiohttp.server
Source: custom_components/dyson_cloud/config_flow.py:71
Integration: Dyson Cloud (documentation, issues)
First occurred: 12:39:41 AM (1 occurrences)
Last logged: 12:39:41 AM

Error handling request
Traceback (most recent call last):
  File "/usr/local/lib/python3.9/site-packages/aiohttp/web_protocol.py", line 435, in _handle_request
    resp = await request_handler(request)
  File "/usr/local/lib/python3.9/site-packages/aiohttp/web_app.py", line 504, in _handle
    resp = await handler(request)
  File "/usr/local/lib/python3.9/site-packages/aiohttp/web_middlewares.py", line 117, in impl
    return await handler(request)
  File "/usr/src/homeassistant/homeassistant/components/http/security_filter.py", line 60, in security_filter_middleware
    return await handler(request)
  File "/usr/src/homeassistant/homeassistant/components/http/forwarded.py", line 98, in forwarded_middleware
    return await handler(request)
  File "/usr/src/homeassistant/homeassistant/components/http/request_context.py", line 28, in request_context_middleware
    return await handler(request)
  File "/usr/src/homeassistant/homeassistant/components/http/ban.py", line 78, in ban_middleware
    return await handler(request)
  File "/usr/src/homeassistant/homeassistant/components/http/auth.py", line 181, in auth_middleware
    return await handler(request)
  File "/usr/src/homeassistant/homeassistant/components/http/view.py", line 137, in handle
    result = await result
  File "/usr/src/homeassistant/homeassistant/components/config/config_entries.py", line 157, in post
    return await super().post(request, flow_id)
  File "/usr/src/homeassistant/homeassistant/components/http/data_validator.py", line 62, in wrapper
    result = await method(view, request, *args, **kwargs)
  File "/usr/src/homeassistant/homeassistant/helpers/data_entry_flow.py", line 110, in post
    result = await self._flow_mgr.async_configure(flow_id, data)
  File "/usr/src/homeassistant/homeassistant/data_entry_flow.py", line 252, in async_configure
    result = await self._async_handle_step(flow, cur_step["step_id"], user_input)
  File "/usr/src/homeassistant/homeassistant/data_entry_flow.py", line 325, in _async_handle_step
    result: FlowResult = await getattr(flow, method)(user_input)
  File "/config/custom_components/dyson_cloud/config_flow.py", line 71, in async_step_email
    self._verify = await self.hass.async_add_executor_job(
  File "/usr/local/lib/python3.9/concurrent/futures/thread.py", line 52, in run
    result = self.fn(*self.args, **self.kwargs)
  File "/usr/local/lib/python3.9/site-packages/libdyson/cloud/account.py", line 121, in login_email_otp
    raise DysonServerError
  File "/usr/local/lib/python3.9/site-packages/libdyson/cloud/account.py", line 113, in request
    auth=self._auth if auth else None,
libdyson.exceptions.DysonInvalidAuth
Logger: homeassistant.config_entries
Source: custom_components/dyson_cloud/__init__.py:43
Integration: Dyson Cloud (documentation, issues)
First occurred: 12:40:36 AM (2 occurrences)
Last logged: 1:30:15 AM

Error setting up entry [email protected] (SE) for dyson_cloud
Traceback (most recent call last):
  File "/usr/src/homeassistant/homeassistant/config_entries.py", line 313, in async_setup
    result = await component.async_setup_entry(hass, self)  # type: ignore
  File "/config/custom_components/dyson_cloud/__init__.py", line 43, in async_setup_entry
    devices = await hass.async_add_executor_job(account.devices)
  File "/usr/local/lib/python3.9/concurrent/futures/thread.py", line 52, in run
    result = self.fn(*self.args, **self.kwargs)
  File "/usr/local/lib/python3.9/site-packages/libdyson/cloud/account.py", line 167, in devices
  File "/usr/local/lib/python3.9/site-packages/libdyson/cloud/account.py", line 113, in request
    auth=self._auth if auth else None,
libdyson.exceptions.DysonInvalidAuth

Dyson Heurist - No Camera Entities

Core Version
core-2021.4.0

Supervisor Version
supervisor-2021.03.9

ha-dyson-cloud v 0.10.0

When using a Dyson Heurist, no camera entities are created - which I believe should show a map?

In the code, I note only a reference to DysonCloud360Eye - is the Heurist currently unsupported for this?

New actively maintained integration! Collaborators welcome! Details inside.

What Happened?

I've created a new Github organization, The libdyson Working Group and published updated versions of libdyson, ha-dyson, and ha-dyson-cloud. The new forks are actively maintained, and I would be excited to talk with any contributors about joining the organization.

I'm currently working on merging all the commits from Pull Requests, then I'll address all the Issues. There are a few conflicts in the Pull Requests regarding newer devices (Formaldehyde fans/heaters, Humidifiers, and refreshes like the HP07 refresh of the HP04). For the time being, Formaldehyde models are the next on my list of things to tackle.

How can I help?

Anyone interested in helping, even if it's just reviewing and merging Pull Requests, please let me know here in this thread, or via email ([email protected])!

Why Fork?

I'm really grateful to @shenxn for their dedication to the project over the years. Sadly, they've been pretty quiet for the past 4~5 months and the integration has started breaking for some people, especially people using new unsupported devices. Eventually, it seemed appropriate to talk about making a community fork to keep things moving.

I especially want to make sure there's at least two people who can merge Pull Requests. This isn't the biggest repo in the world, but it is used by people and gives us some really nice features that are otherwise impossible to access. So I want to make sure all of us continue to have that.

What are the goals?

Primarily, just to keep this working and maintained. I'd personally like to make the integrations and library easier to use, and I'm open to any kind of improvements that the community might have - PR's welcome! Other than that, my short term goals over the next few days are:

  1. Finish merging all the PR's from the past few months to add support for new devices, features for vacuums. This is partially complete right now.
  2. Get Formaldehyde, Humidifier, and other new models working and reporting the correct information.
    • There are some PRs, but Dyson is being weird and giving different models the same Device ID's which confuses the logic of libdyson right now.
  3. Done: Work with Github support to remove the Fork status so that the new repos can have their own dedicated Issues tracker.
  4. Get some more members on the working group to ensure PRs get merged quickly and updates happen.
  5. Try my best to help people get migrated if they need to.

How do I switch from @shenxn's repos to the new repos?

Experimental no-reconfiguration swap

I haven't tested this method very much, but in my experiments it seems possible to switch over with zero impact to your current integration configuration, entities/devices, or dashboards. I don't know what side-effects it may have though (leftover old config data might start causing issues or something - no guarantees).

  1. Remove the ha-dyson and ha-dyson-cloud custom repositories from HACS
    • Without removing the integrations themselves.
  2. Add the new ha-dyson and ha-dyson-cloud custom repositories
    • The ha-dyson-cloud repository is only necessary if you already use it, or are intending to use its features. It is not required, but currently, it makes setting up new devices like HP07 (527K) much simpler.
  3. Update the ha-dyson and ha-dyson-cloud repositories using the HACS updater

Proven some-reconfiguration swap

This is proven to work without any side effects. If you used the default IDs for the entities and devices, then you'll just need to re-configure the devices but your dashboards will not need updating.

  1. Remove the Dyson Local and Dyson Cloud integrations from your /config/integrations page.
  2. Remove the Dyson Local and Dyson Cloud integrations from your /hacs/integrations page.
  3. Remove the dyson-ha and dyson-ha-cloud custom repositories from HACS
  4. Add the new dyson-ha and dyson-ha-cloud custom repositories
    • The libdyson-ha-cloud repository is only necessary if you already use it, or are intending to use its features. It is not required, but currently, it makes setting up new devices like HP07 (527K) much simpler.
  5. Update the dyson-ha and dyson-ha-cloud repositories

That should be it! But if you have any issues doing this, please share: https://github.com/libdyson-wg/ha-dyson-cloud/issues

Installation via HACS - Integrations does not work

get the following error:
Logger: homeassistant.config_entries
Source: config_entries.py:698
First occurred: 10:17:04 (1 occurrences)
Last logged: 10:17:04

Error occurred loading configuration flow for integration dyson_cloud: No module named 'custom_components.dyson_local'

Not shown under integration

Hi,
I installed in HACS the local and cloud version.
Both I can see in HACS integration but if I would add the integration to home assist only the local version I can select. The cloud one is not listet...

I would like to use the local one but can't find the wifi information on the device (pure cool link fan)

Thanks for help

Integration is not loading after reboot

Integration is not loading after reboot.

Logger: homeassistant.setup
Source: setup.py:162
First occurred: 14:32:53 (2 occurrences)
Last logged: 14:32:55

Setup failed for custom integration dyson_cloud: Unable to import component: cannot import name 'DysonPurifierHumidifyCoolFormaldehyde' from 'libdyson' (/usr/local/lib/python3.10/site-packages/libdyson/init.py)
Setup failed for custom integration dyson_local: Unable to import component: cannot import name 'DysonPurifierHumidifyCoolFormaldehyde' from 'libdyson' (/usr/local/lib/python3.10/site-packages/libdyson/init.py)

Invalid path to TLS CA certificate bundle

Attempting to set up the integration fails with:

Traceback (most recent call last):
  File "/usr/local/lib/python3.9/site-packages/aiohttp/web_protocol.py", line 435, in _handle_request
    resp = await request_handler(request)
  File "/usr/local/lib/python3.9/site-packages/aiohttp/web_app.py", line 504, in _handle
    resp = await handler(request)
  File "/usr/local/lib/python3.9/site-packages/aiohttp/web_middlewares.py", line 117, in impl
    return await handler(request)
  File "/usr/src/homeassistant/homeassistant/components/http/security_filter.py", line 60, in security_filter_middleware
    return await handler(request)
  File "/usr/src/homeassistant/homeassistant/components/http/forwarded.py", line 98, in forwarded_middleware
    return await handler(request)
  File "/usr/src/homeassistant/homeassistant/components/http/request_context.py", line 28, in request_context_middleware
    return await handler(request)
  File "/usr/src/homeassistant/homeassistant/components/http/ban.py", line 78, in ban_middleware
    return await handler(request)
  File "/usr/src/homeassistant/homeassistant/components/http/auth.py", line 181, in auth_middleware
    return await handler(request)
  File "/usr/src/homeassistant/homeassistant/components/http/view.py", line 137, in handle
    result = await result
  File "/usr/src/homeassistant/homeassistant/components/config/config_entries.py", line 157, in post
    return await super().post(request, flow_id)
  File "/usr/src/homeassistant/homeassistant/components/http/data_validator.py", line 62, in wrapper
    result = await method(view, request, *args, **kwargs)
  File "/usr/src/homeassistant/homeassistant/helpers/data_entry_flow.py", line 110, in post
    result = await self._flow_mgr.async_configure(flow_id, data)
  File "/usr/src/homeassistant/homeassistant/data_entry_flow.py", line 252, in async_configure
    result = await self._async_handle_step(flow, cur_step["step_id"], user_input)
  File "/usr/src/homeassistant/homeassistant/data_entry_flow.py", line 325, in _async_handle_step
    result: FlowResult = await getattr(flow, method)(user_input)
  File "/config/custom_components/dyson_cloud/config_flow.py", line 71, in async_step_email
    self._verify = await self.hass.async_add_executor_job(
  File "/usr/local/lib/python3.9/concurrent/futures/thread.py", line 52, in run
    result = self.fn(*self.args, **self.kwargs)
  File "/usr/local/lib/python3.9/site-packages/libdyson/cloud/account.py", line 127, in login_email_otp
    )
  File "/usr/local/lib/python3.9/site-packages/libdyson/cloud/account.py", line 107, in request
    headers=DYSON_API_HEADERS,
  File "/usr/local/lib/python3.9/site-packages/requests/api.py", line 61, in request
    return session.request(method=method, url=url, **kwargs)
  File "/usr/local/lib/python3.9/site-packages/requests/sessions.py", line 542, in request
    resp = self.send(prep, **send_kwargs)
  File "/usr/local/lib/python3.9/site-packages/requests/sessions.py", line 655, in send
    r = adapter.send(request, **kwargs)
  File "/usr/local/lib/python3.9/site-packages/requests/adapters.py", line 416, in send
    self.cert_verify(conn, request.url, verify, cert)
  File "/usr/local/lib/python3.9/site-packages/requests/adapters.py", line 227, in cert_verify
    raise IOError("Could not find a suitable TLS CA certificate bundle, "
OSError: Could not find a suitable TLS CA certificate bundle, invalid path: /usr/local/lib/python3.9/site-packages/libdyson/cloud/certs/DigiCert-chain.crt

Can’t install local or cloud integration due to handler error

When trying to install integration I am getting an error message.

Device: Dyson Purifier HEPA Cool™ Formaldehyde purifying fan

Config flow could not be loaded: {"message":"Invalid handler specified"}

Below is the entry from the log:

Dyson cloud integration error

Logger: homeassistant.config_entries Source: config_entries.py:810 First occurred: 12:17:47 (5 occurrences) Last logged: 23:43:08

Error occurred loading configuration flow for integration dyson_cloud: cannot import name 'DysonPurifierHumidifyCoolFormaldehyde' from 'libdyson' (/usr/local/lib/python3.10/site-packages/libdyson/__init__.py) Error occurred loading configuration flow for integration dyson_local: cannot import name 'DysonPurifierHumidifyCoolFormaldehyde' from 'libdyson' (/usr/local/lib/python3.10/site-packages/libdyson/__init__.py)

Dyson local integration error

Logger: homeassistant.config_entries Source: config_entries.py:810 First occurred: 23:52:50 (1 occurrences) Last logged: 23:52:50

Error occurred loading configuration flow for integration dyson_local: cannot import name 'DysonPurifierHumidifyCoolFormaldehyde' from 'libdyson' (/usr/local/lib/python3.10/site-packages/libdyson/__init__.py)

Integration now Unavailable

For some reason my Dyson Pure Hot+Cold Link is now shows as Unavailable.
widget
There is no error code, or any form of guidance on how to fix the problem

I cannot pin-point when it happened but the only change has been an upgrade to the latest version of Home Assistant.

I have tried restarting, no change

I have deleted the integration and tried to set it up again using
Setup using WiFi information but I now get Failed to find the device using discovery
failed

Is there anyway to set this up again?

Thanks

Unable to auth via cloud

Receiving the error below (with a correct email address)

Screen Shot 2021-07-11 at 10 03 23 pm

Logger: aiohttp.server
Source: custom_components/dyson_cloud/config_flow.py:71
Integration: dyson_cloud (documentation, issues)
First occurred: 10:00:31 PM (3 occurrences)
Last logged: 10:00:54 PM

Error handling request
Traceback (most recent call last):
  File "/usr/local/lib/python3.9/site-packages/aiohttp/web_protocol.py", line 422, in _handle_request
    resp = await self._request_handler(request)
  File "/usr/local/lib/python3.9/site-packages/aiohttp/web_app.py", line 499, in _handle
    resp = await handler(request)
  File "/usr/local/lib/python3.9/site-packages/aiohttp/web_middlewares.py", line 119, in impl
    return await handler(request)
  File "/usr/src/homeassistant/homeassistant/components/http/security_filter.py", line 60, in security_filter_middleware
    return await handler(request)
  File "/usr/src/homeassistant/homeassistant/components/http/forwarded.py", line 197, in forwarded_middleware
    return await handler(request)
  File "/usr/src/homeassistant/homeassistant/components/http/request_context.py", line 24, in request_context_middleware
    return await handler(request)
  File "/usr/src/homeassistant/homeassistant/components/http/ban.py", line 78, in ban_middleware
    return await handler(request)
  File "/usr/src/homeassistant/homeassistant/components/http/auth.py", line 144, in auth_middleware
    return await handler(request)
  File "/usr/src/homeassistant/homeassistant/components/http/view.py", line 135, in handle
    result = await result
  File "/usr/src/homeassistant/homeassistant/components/config/config_entries.py", line 155, in post
    return await super().post(request, flow_id)
  File "/usr/src/homeassistant/homeassistant/components/http/data_validator.py", line 63, in wrapper
    result = await method(view, request, *args, **kwargs)
  File "/usr/src/homeassistant/homeassistant/helpers/data_entry_flow.py", line 109, in post
    result = await self._flow_mgr.async_configure(flow_id, data)
  File "/usr/src/homeassistant/homeassistant/data_entry_flow.py", line 202, in async_configure
    result = await self._async_handle_step(flow, cur_step["step_id"], user_input)
  File "/usr/src/homeassistant/homeassistant/data_entry_flow.py", line 260, in _async_handle_step
    result: FlowResult = await getattr(flow, method)(user_input)
  File "/config/custom_components/dyson_cloud/config_flow.py", line 71, in async_step_email
    self._verify = await self.hass.async_add_executor_job(
  File "/usr/local/lib/python3.9/concurrent/futures/thread.py", line 52, in run
    result = self.fn(*self.args, **self.kwargs)
  File "/usr/local/lib/python3.9/site-packages/libdyson/cloud/account.py", line 127, in login_email_otp
    response = self.request(
  File "/usr/local/lib/python3.9/site-packages/libdyson/cloud/account.py", line 119, in request
    raise DysonInvalidAuth
libdyson.exceptions.DysonInvalidAuth

Invalid authentication

Hello and thank your for your work, this is really promising.

I am having an issue while using this integration. It refuses to login with my credentials (which work with the official app and
worked with official ha integration as well).

To be sure, I created a new account and test the connection with the same effect.

The error is "Invalid authentication"

Would you know where it could come from ?
Thank you

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.