Andre0512 / hon

Home Assistant integration for Haier hOn: support for Haier/Candy/Hoover home appliances like washing machines and air conditioners in 28 languages.
MIT License
1.3k stars 2.46k forks source link

hOn Authentication Error while trying to add a newly created account #230

Open 48mWsPK opened 4 months ago

48mWsPK commented 4 months ago

Describe the bug Trying to setup a newly created non-Gmail account results in hOn Authentication Error 1 200 - https://account2.hon-smarthome.com/hOnRedirect?startURL=/setup/secur/RemoteAccessAuthorizationPage.apexp?source....

To Reproduce Steps to reproduce the behavior:

  1. Add hon custom component to HA
  2. Add hOn integration
  3. Provide correct account login info - works on mobile
  4. See error

Expected behavior Successfully setup the hOn HA integration

Screenshots image

Environment (please complete the following information):

Additional context n/a

Home Assistant Logs Check System -> Logs if you can find any logs related to this integration and post it here.

Device Log

2024-07-09 15:32:56.764 ERROR (MainThread) [pyhon.connection.auth] hOn Authentication Error
1 200 - https://account2.hon-smarthome.com/hOnRedirect?startURL=/setup/secur/RemoteAccessAuthorizationPage.apexp?source%3DCAAAAZCcoebLMDAwMDAwMDAwMDAwMDAwAAAA-hPIMSrShOCaS_nzv1mPVc__ZIVsxf5QXEQnXosVHvlPqM5l48WnsXn0y3ZTEczc2c893sBM_EqnVOs_qjyw-gaRmembGvbDX5qykspJ0jdzLGAWTZ0FtME0iRR3LtvxS7mwuO3yIf_4aQ5VGFJS-iIWW8WmFMyiPfb87lq9XcJWfeb0ej0P9TKRjZNzrd9h9c3O_oKChN2Hzx8s8eEja5jIniUVuPMA-t9HcCvyEFD4ed5p7EOlXm-USZClqOq_ibu8ih6ZEKSHmpn72Z7WfU0rzueg6BjlRy49qFpeTAv0fFR60sIaudCnUYkNSJGfX305Tm3h-k5uePSH153yRePTHHIzVWZMPg8XtC2gTl3aFRQyPD05bMpJd6IxVFVI6NAUZRD42uOgfNcSNOA4t0QzcP--N2_40bLOU7g48KxnQkEfPI7bXsbkZU02Q61pmBSjIzT6VyZ1sYnGIITFu8MJIeX_Ay--IjxQkGA4RZ6He1FYnGG9nGGmnrrM6A0bKU4j-COTDoaMRy-A0UjSW_3s8FCmbARLGMiEnM7HcAUq8FlrnA3LzzpHQHr4T0AGA7Wn2l1EWLkKvmUX717UCxmV_VFKsFaB9LD0YI5cY1tWdfH7JyBl1ytqWEn3ppSrI8-sBXNO4x1MRI2V_nGmViCSFjqAvq_1TEX9bEwKR67CpVWhrceVJe7uDkbQnT1Wxtg_RSUJpOxupekVJL5g9vD0Pbn5XbTE0AWbGY2hCE_-MrnqMKtmK4eVz60IRjO7_g%253D%253D%26display%3Dtouch
ERROR - 200 - https://account2.hon-smarthome.com/hOnRedirect?startURL=/setup/secur/RemoteAccessAuthorizationPage.apexp?source%3DCAAAAZCcoebLMDAwMDAwMDAwMDAwMDAwAAAA-hPIMSrShOCaS_nzv1mPVc__ZIVsxf5QXEQnXosVHvlPqM5l48WnsXn0y3ZTEczc2c893sBM_EqnVOs_qjyw-gaRmembGvbDX5qykspJ0jdzLGAWTZ0FtME0iRR3LtvxS7mwuO3yIf_4aQ5VGFJS-iIWW8WmFMyiPfb87lq9XcJWfeb0ej0P9TKRjZNzrd9h9c3O_oKChN2Hzx8s8eEja5jIniUVuPMA-t9HcCvyEFD4ed5p7EOlXm-USZClqOq_ibu8ih6ZEKSHmpn72Z7WfU0rzueg6BjlRy49qFpeTAv0fFR60sIaudCnUYkNSJGfX305Tm3h-k5uePSH153yRePTHHIzVWZMPg8XtC2gTl3aFRQyPD05bMpJd6IxVFVI6NAUZRD42uOgfNcSNOA4t0QzcP--N2_40bLOU7g48KxnQkEfPI7bXsbkZU02Q61pmBSjIzT6VyZ1sYnGIITFu8MJIeX_Ay--IjxQkGA4RZ6He1FYnGG9nGGmnrrM6A0bKU4j-COTDoaMRy-A0UjSW_3s8FCmbARLGMiEnM7HcAUq8FlrnA3LzzpHQHr4T0AGA7Wn2l1EWLkKvmUX717UCxmV_VFKsFaB9LD0YI5cY1tWdfH7JyBl1ytqWEn3ppSrI8-sBXNO4x1MRI2V_nGmViCSFjqAvq_1TEX9bEwKR67CpVWhrceVJe7uDkbQnT1Wxtg_RSUJpOxupekVJL5g9vD0Pbn5XbTE0AWbGY2hCE_-MrnqMKtmK4eVz60IRjO7_g%253D%253D%26display%3Dtouch
=============== Response ===============
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
<meta HTTP-EQUIV="PRAGMA" CONTENT="NO-CACHE">
<script>
function redirectOnLoad() {
if (this.SfdcApp && this.SfdcApp.projectOneNavigator) { SfdcApp.projectOneNavigator.handleRedirect('/NewhOnLogin?display=touch%2F&ec=302&startURL=%2F%2Fsetup%2Fsecur%2FRemoteAccessAuthorizationPage.apexp%3Fsource%3DCAAAAZCcoebLMDAwMDAwMDAwMDAwMDAwAAAA-hPIMSrShOCaS_nzv1mPVc__ZIVsxf5QXEQnXosVHvlPqM5l48WnsXn0y3ZTEczc2c893sBM_EqnVOs_qjyw-gaRmembGvbDX5qykspJ0jdzLGAWTZ0FtME0iRR3LtvxS7mwuO3yIf_4aQ5VGFJS-iIWW8WmFMyiPfb87lq9XcJWfeb0ej0P9TKRjZNzrd9h9c3O_oKChN2Hzx8s8eEja5jIniUVuPMA-t9HcCvyEFD4ed5p7EOlXm-USZClqOq_ibu8ih6ZEKSHmpn72Z7WfU0rzueg6BjlRy49qFpeTAv0fFR60sIaudCnUYkNSJGfX305Tm3h-k5uePSH153yRePTHHIzVWZMPg8XtC2gTl3aFRQyPD05bMpJd6IxVFVI6NAUZRD42uOgfNcSNOA4t0QzcP--N2_40bLOU7g48KxnQkEfPI7bXsbkZU02Q61pmBSjIzT6VyZ1sYnGIITFu8MJIeX_Ay--IjxQkGA4RZ6He1FYnGG9nGGmnrrM6A0bKU4j-COTDoaMRy-A0UjSW_3s8FCmbARLGMiEnM7HcAUq8FlrnA3LzzpHQHr4T0AGA7Wn2l1EWLkKvmUX717UCxmV_VFKsFaB9LD0YI5cY1tWdfH7JyBl1ytqWEn3ppSrI8-sBXNO4x1MRI2V_nGmViCSFjqAvq_1TEX9bEwKR67CpVWhrceVJe7uDkbQnT1Wxtg_RSUJpOxupekVJL5g9vD0Pbn5XbTE0AWbGY2hCE_-MrnqMKtmK4eVz60IRjO7_g%3D%3D'); } else
if (window.location.replace){
window.location.replace('/NewhOnLogin?display=touch%2F&ec=302&startURL=%2F%2Fsetup%2Fsecur%2FRemoteAccessAuthorizationPage.apexp%3Fsource%3DCAAAAZCcoebLMDAwMDAwMDAwMDAwMDAwAAAA-hPIMSrShOCaS_nzv1mPVc__ZIVsxf5QXEQnXosVHvlPqM5l48WnsXn0y3ZTEczc2c893sBM_EqnVOs_qjyw-gaRmembGvbDX5qykspJ0jdzLGAWTZ0FtME0iRR3LtvxS7mwuO3yIf_4aQ5VGFJS-iIWW8WmFMyiPfb87lq9XcJWfeb0ej0P9TKRjZNzrd9h9c3O_oKChN2Hzx8s8eEja5jIniUVuPMA-t9HcCvyEFD4ed5p7EOlXm-USZClqOq_ibu8ih6ZEKSHmpn72Z7WfU0rzueg6BjlRy49qFpeTAv0fFR60sIaudCnUYkNSJGfX305Tm3h-k5uePSH153yRePTHHIzVWZMPg8XtC2gTl3aFRQyPD05bMpJd6IxVFVI6NAUZRD42uOgfNcSNOA4t0QzcP--N2_40bLOU7g48KxnQkEfPI7bXsbkZU02Q61pmBSjIzT6VyZ1sYnGIITFu8MJIeX_Ay--IjxQkGA4RZ6He1FYnGG9nGGmnrrM6A0bKU4j-COTDoaMRy-A0UjSW_3s8FCmbARLGMiEnM7HcAUq8FlrnA3LzzpHQHr4T0AGA7Wn2l1EWLkKvmUX717UCxmV_VFKsFaB9LD0YI5cY1tWdfH7JyBl1ytqWEn3ppSrI8-sBXNO4x1MRI2V_nGmViCSFjqAvq_1TEX9bEwKR67CpVWhrceVJe7uDkbQnT1Wxtg_RSUJpOxupekVJL5g9vD0Pbn5XbTE0AWbGY2hCE_-MrnqMKtmK4eVz60IRjO7_g%3D%3D');
} else {
window.location.href ='/NewhOnLogin?display=touch%2F&ec=302&startURL=%2F%2Fsetup%2Fsecur%2FRemoteAccessAuthorizationPage.apexp%3Fsource%3DCAAAAZCcoebLMDAwMDAwMDAwMDAwMDAwAAAA-hPIMSrShOCaS_nzv1mPVc__ZIVsxf5QXEQnXosVHvlPqM5l48WnsXn0y3ZTEczc2c893sBM_EqnVOs_qjyw-gaRmembGvbDX5qykspJ0jdzLGAWTZ0FtME0iRR3LtvxS7mwuO3yIf_4aQ5VGFJS-iIWW8WmFMyiPfb87lq9XcJWfeb0ej0P9TKRjZNzrd9h9c3O_oKChN2Hzx8s8eEja5jIniUVuPMA-t9HcCvyEFD4ed5p7EOlXm-USZClqOq_ibu8ih6ZEKSHmpn72Z7WfU0rzueg6BjlRy49qFpeTAv0fFR60sIaudCnUYkNSJGfX305Tm3h-k5uePSH153yRePTHHIzVWZMPg8XtC2gTl3aFRQyPD05bMpJd6IxVFVI6NAUZRD42uOgfNcSNOA4t0QzcP--N2_40bLOU7g48KxnQkEfPI7bXsbkZU02Q61pmBSjIzT6VyZ1sYnGIITFu8MJIeX_Ay--IjxQkGA4RZ6He1FYnGG9nGGmnrrM6A0bKU4j-COTDoaMRy-A0UjSW_3s8FCmbARLGMiEnM7HcAUq8FlrnA3LzzpHQHr4T0AGA7Wn2l1EWLkKvmUX717UCxmV_VFKsFaB9LD0YI5cY1tWdfH7JyBl1ytqWEn3ppSrI8-sBXNO4x1MRI2V_nGmViCSFjqAvq_1TEX9bEwKR67CpVWhrceVJe7uDkbQnT1Wxtg_RSUJpOxupekVJL5g9vD0Pbn5XbTE0AWbGY2hCE_-MrnqMKtmK4eVz60IRjO7_g%3D%3D';
}
}
redirectOnLoad();
</script>
</head>
</html>
========================================
2024-07-09 15:32:56.764 ERROR (MainThread) [homeassistant.config_entries] Error setting up entry ***REDACTED*** for hon
Traceback (most recent call last):
File "/usr/src/homeassistant/homeassistant/config_entries.py", line 586, in async_setup
result = await component.async_setup_entry(hass, self)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/config/custom_components/hon/__init__.py", line 34, in async_setup_entry
hon = await Hon(
^^^^^^^^^^
File "/usr/local/lib/python3.12/site-packages/pyhon/hon.py", line 77, in create
await self.setup()
File "/usr/local/lib/python3.12/site-packages/pyhon/hon.py", line 104, in setup
appliances = await self.api.load_appliances()
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/local/lib/python3.12/site-packages/pyhon/connection/api.py", line 86, in load_appliances
async with self._hon.get(f"{const.API_URL}/commands/v1/appliance") as resp:
File "/usr/local/lib/python3.12/contextlib.py", line 210, in __aenter__
return await anext(self.gen)
^^^^^^^^^^^^^^^^^^^^^
File "/usr/local/lib/python3.12/site-packages/pyhon/connection/handler/base.py", line 64, in get
async with self._intercept(*args, **kwargs) as response:
File "/usr/local/lib/python3.12/contextlib.py", line 210, in __aenter__
return await anext(self.gen)
^^^^^^^^^^^^^^^^^^^^^
File "/usr/local/lib/python3.12/site-packages/pyhon/connection/handler/hon.py", line 75, in _intercept
kwargs["headers"] = await self._check_headers(kwargs.get("headers", {}))
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/local/lib/python3.12/site-packages/pyhon/connection/handler/hon.py", line 64, in _check_headers
await self.auth.authenticate()
File "/usr/local/lib/python3.12/site-packages/pyhon/connection/auth.py", line 256, in authenticate
if not await self._load_login():
^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/local/lib/python3.12/site-packages/pyhon/connection/auth.py", line 104, in _load_login
login_url = await self._introduce()
^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/local/lib/python3.12/site-packages/pyhon/connection/auth.py", line 128, in _introduce
await self._error_logger(response)
File "/usr/local/lib/python3.12/site-packages/pyhon/connection/auth.py", line 96, in _error_logger
raise exceptions.HonAuthenticationError("Can't login")
pyhon.exceptions.HonAuthenticationError: Can't login

Data Archive For further analysis, please add your appliance data archive here (if available) Navigate to Settings -> Device & Services -> Haier hOn -> your device and press the Create Data Archive button. Then open notifications to download the data zip archive. To attach the file:

Kfrard commented 4 months ago

I think we should wait a few more days for Andre's response, but if we don't hear back, we'll have to create a fork.

At least temporarily, I recommend you use the already mentioned https://github.com/gvigroux/hon. Remembering to remove the Andre integration previously, check if the custom_integrations/hon folder was deleted and restart HA due to the error https://github.com/gvigroux/hon/issues/105.

Unfortunately, Haier, despite its "willingness to cooperate", is not playing nice with us, I personally plan to install such a module https://github.com/paveldn/haier-esphome to become independent from the cloud and Haier's inventions; I recommend you think about the same.

lindap1978 commented 4 months ago

I think we should wait a few more days for Andre's response, but if we don't hear back, we'll have to create a fork.

At least temporarily, I recommend you use the already mentioned https://github.com/gvigroux/hon. Remembering to remove the Andre integration previously, check if the custom_integrations/hon folder was deleted and restart HA due to the error gvigroux/hon#105.

Unfortunately, Haier, despite its "willingness to cooperate", is not playing nice with us, I personally plan to install such a module https://github.com/paveldn/haier-esphome to become independent from the cloud and Haier's inventions; I recommend you think about the same.

Is this only for air conditioning?

deezid commented 4 months ago

Is this only for air conditioning?

looks like it, would need it for a washer...

Kfrard commented 4 months ago

I think we should wait a few more days for Andre's response, but if we don't hear back, we'll have to create a fork. At least temporarily, I recommend you use the already mentioned https://github.com/gvigroux/hon. Remembering to remove the Andre integration previously, check if the custom_integrations/hon folder was deleted and restart HA due to the error gvigroux/hon#105. Unfortunately, Haier, despite its "willingness to cooperate", is not playing nice with us, I personally plan to install such a module https://github.com/paveldn/haier-esphome to become independent from the cloud and Haier's inventions; I recommend you think about the same.

Is this only for air conditioning?

Gvigroux integration should work with some washing machines. Paveldn project, I don't know :) but I think it has potential for other devices (check https://github.com/paveldn/haier-esphome/issues/37).

lewicki-pk commented 4 months ago

Unfortunately, Haier, despite its "willingness to cooperate", is not playing nice with us, I personally plan to install such a module https://github.com/paveldn/haier-esphome to become independent from the cloud and Haier's inventions; I recommend you think about the same.

I'm about to do the same but until I have time to do that I'll go with https://github.com/gvigroux/hon - it works.

addshore commented 4 months ago

I think we should wait a few more days for Andre's response, but if we don't hear back, we'll have to create a fork.

If something doesn't move on this repo by some time next week, I can look at making a fork of both this and pyhOn. I for one can't use most of the alternatives as my fridge isn't supported.

bart1604 commented 4 months ago

I think we should wait a few more days for Andre's response, but if we don't hear back, we'll have to create a fork.

If something doesn't move on this repo by some time next week, I can look at making a fork of both this and pyhOn. I for one can't use most of the alternatives as my fridge isn't supported.

I'll keep an eye on this then, as one over my AC's is not supported by other alternatives.. Need this one to work. Hopefully Andre picks it up again.

jfmcarreira commented 4 months ago

I just applied the path from pyhon directly to HA. But it is not a long term solution, but i was able to connect again. However since it is in push mode in the beta it does not update at all. controls the AC but does not get updates

danigio15 commented 4 months ago

any news on the update release? I'm trying everything but the only one is to update pyhon to 0.17.5. Or have you found other solutions? I also tried the other integration https://github.com/gvigroux/hon but it doesn't work I need it for a washing machine where I need to manage the programs. I have a zigbee switch with a series of programs inserted. Let's hope Andre0512 responds as soon as possible

Doktor-X commented 4 months ago

@jm314159 pyHon need to manual install after the manifest edit?

I edited the manifest locally, then uploaded all files to /config/custom_components/hon, removed /config/custom_components/hon/__pycache__, and restarted HA core.

I HAVE updated manifest file in hon folder with: "requirements": [ "pyhOn @ git+https://github.com/addshore/pyhOn.git@3f39be53f31885fb84d72f91fb4123c2e39e7156" ], But you say that you uploaded "all" files to hon folder. Can you explane this part.

jm314159 commented 4 months ago

Well, for my ease, I used to modify files on my computer. Then, I delete the whole contents of hon and upload all files by WinSCP. I always proceed that way when changing versions or settings.

I think you get the same by the edit in place. I believe though that removal of pycache matters upon core restart. You can try running your HA in a private session to confirm your browser have not cached the settings.

deezid commented 4 months ago

Now it also happened here :( Integration doesn't work anymore.

deezid commented 4 months ago

Just modified manifest.json of v0.13.0 by changing the pyhOn requirements to what @addshore updated:

  "requirements": [
    "pyhOn @ git+https://github.com/addshore/pyhOn.git@3f39be53f31885fb84d72f91fb4123c2e39e7156"
  ],

At the moment, the integration works fine for me on both old 2024.6.4 and new 2024.7.2 cores, obraz obraz

which confirms perhaps what has already been said - the issue is in pyhOn. Having that version set, I hope for automatic state updates. We'll see. I eventually accept one minute delay, but let it happen.

There is a setting "iot_class": "cloud_polling" in v13 compared to "iot_class": "cloud_push" to be found since v14. I'm pretty lame in programming such things, if you could please answer, whether it is a key setting for the updates or not only that, or even not at all.

Tried doing that. After reinitializing it still fails with: hOn Authentication Error 1 200

Do I need to remove the integration and add it again?

jfmcarreira commented 4 months ago

There is a setting "iot_class": "cloud_polling" in v13 compared to "iot_class": "cloud_push" to be found since v14.

I believe work was done to make it push instead of constant pooling. The constant pooling is what brought Haier to try and shut the integration. But to be honest I used the beta and it didn't seem to update. I am using v13 again

deezid commented 4 months ago

Also tried manually installing addshore's fork of the integration rebooted and added the integration again. No luck. Still the same error when trying to log into.

jm314159 commented 4 months ago

@jfmcarreira - could you please confirm you are able to run hOn v13?

@deezid - @dmd79 advised https://github.com/Andre0512/hon/issues/230#issuecomment-2223901577 above. I do not have any reliable recipe more...

Try to play as follows:

  1. Remove hOn integration (and delete the whole dir /config/custom_components/hon)
  2. Downgrade core to, say, 2024.6.4 - I also used it for tests
  3. Apply integration (with a proper requirements entry)
  4. If OK, then update core to the current version
Doktor-X commented 4 months ago

Or simply switch to gvigroux's version of addon temporarily or if you like it permanently (i think that ill switch back to Andre's version back of he manage to fix it)

roberglezz commented 4 months ago

@jfmcarreira - could you please confirm you are able to run hOn v13? @deezid - @dmd79 advised #230 (comment) above. I do not have any reliable recipe more... Try to play as follows:

  1. Remove hOn integration (and delete the whole dir /config/custom_components/hon)
  2. Downgrade core to, say, 2024.6.4 - I also used it for tests
  3. Apply integration (with a proper requirements entry)
  4. If OK, then update core to the current version

I have it working manually edit manifest and downgrade ha core. But now I've replaced the esp32 module I have to admit hon integration was really fine but I'm more confident with a cloud less integration No more issue for me esphome.io/components/climate/haier.html

Which version you have of the esphome, the one with USB A conector of the new one with JST Connector?, i have the new versionso I just order the female JST conector as I do not want to cut the cable. I have a esp32 ready to plug once it arrive. All working good on your side?

roberglezz commented 4 months ago

Absolutely all fine. I have the JST version, using Esp32-wroom-32 and 3.3-5V converter I have cut the wire and sold it This is the result PXL_20240714_215104354

Looks really good. Nice Job. Looking fordwar to connect mine.

By the way is there any particular reason that you use the converter? Could you not use the 5v direct from the AC to the ESP32? I am also using Esp32-wroom-32

jfmcarreira commented 4 months ago

@jfmcarreira - could you please confirm you are able to run hOn v13?

Yes but I needed to change the code for pyhon based on the https://github.com/Andre0512/pyhOn/pull/29

bliekp commented 4 months ago

Can we please keep this on topic? This is a bug report about the integration not working at the moment. I'm keen on getting a fix from the developer. Not interested in side projects.

bart1604 commented 4 months ago

Did we really just deleted a whole bunch of comments just to "stay on topic". A lot of these comments had a lot of information for me the step away from the cloud.

I'm all in for staying on topic, but these comments had a lot of usefull information to get this working again in another way. Which for some people could be a solution to the problem we are all having..

roberglezz commented 4 months ago

Hi Everyone,

I just tryied gvigroux/hon as temporary solution and it works fine. Andre one has lot more features and easy to execute programs but while we waiting for him to be back is does the job. Also it detect my new Fridge which is great.

InCrustWeTrust commented 4 months ago

@roberglezz thanks for the info - just did the same and it worked. Just installed gvigroux repo on top, did not even have to reconfigure the Haier integration.

bart1604 commented 4 months ago

So, I addshore@c5cff77 currently installed, and it all appears to be working for me now, but it did require an additional restart of HA too?

image

If you want to do this the "easy" way, you can add https://github.com/addshore/hon as a custom HACS repo, and then use the 0.14.0-beta.8-addshore release that should be available, which has the updated python dependency. Or you can go for what @dm-christian mentioned above.

Ultimately, i dont plan on maintaining this fork / release / repo, so I hope it gets released here too :)

Unfortunattly, this did not work for me.. Screenshot 2024-07-17 141438

millenniumy2k commented 4 months ago

Same problem

BartVPL commented 4 months ago

Same here tried all mentioned methods app works on mobile does not in HA

kieranlittle667 commented 4 months ago

I removed the standard integration and made sure it had removed all files, restarted ha, and added the @addshore fork to custom repos in hacs and installed it. Once I added my account I got the same error. It was working fine up until I think Monday. Does anyone know if the other integration supports time remaining / machine state? That's all I pretty much use it for; seeing how long is left without having to go into the app and I have automations set up to notify when the washer or drier have finished.

szpe commented 4 months ago

Does anyone know if the other integration supports time remaining / machine state? That's all I pretty much use it for; seeing how long is left without having to go into the app and I have automations set up to notify when the washer or drier have finished.

As mentioned before https://github.com/gvigroux/hon seems to work fot that purpose. It is available in HACS. You'll have all the sensors for the device.

dm-christian commented 4 months ago

I tried the https://github.com/gvigroux/hon

Had to edit all the automations because the features that are provided are slightly different but it works so far for the 8 indoor AC split devices i have in my house.

You can not use "programs" in the frontend. but who need that if you can automate everything right? :)

Doktor-X commented 4 months ago

Strange that Andre did not made any modification to the code to fix addon. Maybe he give up and decided to abend project, since hi did have potencial legal problems with haier itself, but i thought that thay come to agriment and let him do the addon, since haier itself dont want to make integration avalible to HA usees

skovper1337 commented 4 months ago

Strange that Andre did not made any modification to the code to fix addon. Maybe he give up and decided to abend project, since hi did have potencial legal problems with haier itself, but i thought that thay come to agriment and let him do the addon, since haier itself dont want to make integration avalible to HA usees

Andre hasn't been active on github the last 3 months...

francescob commented 4 months ago

Hi all, i was able to make addshore version working using homeassistant container, some manual steps are required because simply adding the custom repo to hacs installs the integration but in a state that is not working because it fails building a dependency for pyhon. So here are the detailed steps to make it work:

enter the docker container: docker exec -it homeassistant bash

then inside the docker container run this command to install required libraries to build all pyhon dependecies:

apk add git cmake make clang build-base llvm-static llvm-dev clang-static clang-dev

when it finished, manually install addshore pyhon fork:

pip install pyhOn@git+https://github.com/addshore/pyhOn.git@3f39be53f31885fb84d72f91fb4123c2e39e7156

now you can just continue installing addshore fork of the hon integration adding this repo to hacs:

https://github.com/addshore/hon

install the integration, enter email and password and voilà, it's working

mlewando commented 4 months ago

Hi guys, thanks for support on this :) I'm trying to follow @francescob solution, but I'm failing to install pip on HA... I'm running HA supervised OS, I have ssh on it and inside there I only can see that pip was not found :(

image

how can I install some python modules without pip? or how to get pip?

deezid commented 4 months ago

Hi all, i was able to make addshore version working using homeassistant container, some manual steps are required because simply adding the custom repo to hacs installs the integration but in a state that is not working because it fails building a dependency for pyhon. So here are the detailed steps to make it work:

enter the docker container: docker exec -it homeassistant bash

then inside the docker container run this command to install required libraries to build all pyhon dependecies:

apk add git cmake make clang build-base llvm-static llvm-dev clang-static clang-dev

when it finished, manually install addshore pyhon fork:

pip install pyhOn@git+https://github.com/addshore/pyhOn.git@3f39be53f31885fb84d72f91fb4123c2e39e7156

now you can just continue installing addshore fork of the hon integration adding this repo to hacs:

https://github.com/addshore/hon

install the integration, enter email and password and voilà, it's working

Worked perfectly for me. Will try out tomorrow and see if it actually updates though.

deezid commented 4 months ago

Just tried out the modded 0.14 beta 8 by addshore. It is basically as useless as the regular 0.14 beta 7 as it never connects to the washer over here.

I hope there is a way to also get 0.13 to work again which was flawless after adjusting the polling intervall from 1 minute to 10 seconds.

Edit: Got 0.13 working after installing on top and editing manifest.json "requirements": [ "pyhOn @ git+https://github.com/addshore/pyhOn.git@3f39be53f31885fb84d72f91fb4123c2e39e7156" ],

then reboot

Now everything is back to normal again :) Screenshot 2024-07-24 at 12 31 23 Screenshot 2024-07-24 at 12 31 52

Botap commented 4 months ago

Hi, can you please provide some more details on the steps you took to get 0.13 working again?

legalr commented 4 months ago

For me the steps Deezid describes works.

First install the 0.14 beta 8 by addshore, after this a reboot, -> Hon app does not work.

Then installal the 0.13 again and add the : "requirements": [ "pyhOn @ git+https://github.com/addshore/pyhOn.git@3f39be53f31885fb84d72f91fb4123c2e39e7156" ]

image

after this a reboot and for me these steps are working.

Michelvd91 commented 4 months ago

Still can't get it to work :( image

legalr commented 4 months ago

Still can't get it to work :( image

can you logon to the HON on your phone and try again? this step i also did to check if my credentials still work.

kieranlittle667 commented 4 months ago

This was part of the problem I was having I think, when I logged on to account.hon-smarthome.com, it forced a password reset.

On Thu, 25 Jul 2024 at 15:34, legalr @.***> wrote:

Still can't get it to work :( [image: image] https://private-user-images.githubusercontent.com/157252191/352123896-c1c2e5ed-f529-493f-a83a-2a350576f92c.png?jwt=eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJpc3MiOiJnaXRodWIuY29tIiwiYXVkIjoicmF3LmdpdGh1YnVzZXJjb250ZW50LmNvbSIsImtleSI6ImtleTUiLCJleHAiOjE3MjE5MTgyNTcsIm5iZiI6MTcyMTkxNzk1NywicGF0aCI6Ii8xNTcyNTIxOTEvMzUyMTIzODk2LWMxYzJlNWVkLWY1MjktNDkzZi1hODNhLTJhMzUwNTc2ZjkyYy5wbmc_WC1BbXotQWxnb3JpdGhtPUFXUzQtSE1BQy1TSEEyNTYmWC1BbXotQ3JlZGVudGlhbD1BS0lBVkNPRFlMU0E1M1BRSzRaQSUyRjIwMjQwNzI1JTJGdXMtZWFzdC0xJTJGczMlMkZhd3M0X3JlcXVlc3QmWC1BbXotRGF0ZT0yMDI0MDcyNVQxNDMyMzdaJlgtQW16LUV4cGlyZXM9MzAwJlgtQW16LVNpZ25hdHVyZT1hMzBlNjEwOTJkMmM3ZjU1ZDQ1MTc5MWVlMzEyNTc0ZDIxYWIyYjM5MTQ3NzkyOGY4YTNmYjI5MzQ0N2RlMDEyJlgtQW16LVNpZ25lZEhlYWRlcnM9aG9zdCZhY3Rvcl9pZD0wJmtleV9pZD0wJnJlcG9faWQ9MCJ9.x_-ns5DxeZUtZm0rPDZ3cSNBuOoMyvA_waq0T5pDJwU

can you logon to the HON on your phone and try again? this step i also did to check if my credentials still work.

— Reply to this email directly, view it on GitHub https://github.com/Andre0512/hon/issues/230#issuecomment-2250483832, or unsubscribe https://github.com/notifications/unsubscribe-auth/AKV3FSYL4SRGZ7WOMTSIINDZOEEHRAVCNFSM6AAAAABKS2LP4OVHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMZDENJQGQ4DGOBTGI . You are receiving this because you commented.Message ID: @.***>

--

Kieran Little email: @.***

Michelvd91 commented 4 months ago

@legalr I did try that and did a password reset. The very slow hOn app is working. I followed all steps and also added the requirements. Rebooted multiple times. Still nothing.

deezid commented 4 months ago

I had to follow these instructions first. https://github.com/Andre0512/hon/issues/230#issuecomment-2246125918 (without the docker part over here)

But cleaned up everything, deleted haier devices and entities. Removed any remaining Haier integration. Rebooted.

Then added the addshore repo, installed 0.14 beta 8, restarted, added the integration, logged in succesfully. After that installed version 0.13 again, modified manifest.json, rebooted. The integration was still working and I was back to version 0.13 which actually connects to my washer. :)

legalr commented 4 months ago

@legalr I did try that and did a password reset. The very slow hOn app is working. I followed all steps and also added the requirements. Rebooted multiple times. Still nothing.

Did you remove the .13 before installing the .14? If not try.

Botap commented 4 months ago

Hi, It is also still not working for me. I did clean up, installed .14, installed.13, adjust manifest.json. But still not working. I think it is due to I am not able to install the Phyton fork as mentioned above. I am on supervised version and in the terminal I can't use PIP. Any ideas anyone?

deezid commented 4 months ago

Sadly, without the pip install it didn't work over here either

SimonCtl commented 4 months ago

Same here. Looks like we all face same issue cannot doing the pip install pip install pyhOn@git+https://github.com/addshore/pyhOn.git@3f39be53f31885fb84d72f91fb4123c2e39e7156

drjakub commented 4 months ago

Something is still not right, even when i was able to install pyh0n using this:

apk add pipx
pipx install pyhOn@git+https://github.com/addshore/pyhOn.git@3f39be53f31885fb84d72f91fb4123c2e39e7156

i still get error even using addshore fork:

Rejestrator: pyhon.connection.auth Źródło: custom_components/hon/__init__.py:34 integracja: Haier hOn ([dokumentacja](https://github.com/Andre0512/hon/), [Problemy](https://github.com/Andre0512/hon/issues)) Pierwsze zdarzenie: 17:46:36 (1 zdarzenia) Ostatnio zalogowany: 17:46:36 hOn Authentication Error 1 200 - https://account2.hon-smarthome.com/hOnRedirect?startURL=/setup/secur/RemoteAccessAuthorizationPage.apexp?source%3DCAAAAZD031bMMDAwMDAwMDAwMDAwMDAwAAAA-mugIsNncLuGCG837shG0bgRhcrC3d_WqqJvRBurHfpzJ-

Doktor-X commented 4 months ago

Hi, i want to give you guys my update on things with this addon. I manage to get this working, this time around without problem. I deleted gvigroux's hon addon and reinstall Andre's addon, and before i restarted HA i edited manifest, restarted HA and started intigration setup and now it works.

deezid commented 4 months ago

it started disconnecting here today quite often. I think Haier is still fighting it.