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

dependency cchardet cannot be installed on python 3.11 #507

Closed
pleblancq opened this issue Mar 1, 2023 · 6 comments
Closed

dependency cchardet cannot be installed on python 3.11 #507

pleblancq opened this issue Mar 1, 2023 · 6 comments
Labels
enhancement New feature or request

Comments

@pleblancq
Copy link

pleblancq commented Mar 1, 2023

Hi,

since HomeAssistant v2023.3.0, we can install HomeAssistant with python 3.11

Your sensors has a dependency that is not working with python 3.11 (cchardet).

see thewhiteh4t/nexfil#24 stating that cchardet seems to be abandonned.

You could easily migrate to charset_normalizer.

I changed the import cchardet in core_async.py to

from charset_normalizer import detect

and changed the detect line to:

encoding = detect(content).get("encoding")

and everyhing works fine.

Would be nice if you could add this modification so people migrating to v3.11 will be able to use your sensors.

Thanks

@kleytonn
Copy link

kleytonn commented Mar 1, 2023

Thank you @pleblancq

It has worked well with my LG AC.

Regards,

@ollo69
Copy link
Owner

ollo69 commented Mar 2, 2023

Thanks for this suggestion. I'm busy with work and far from home on this period, I will implement suggested changes as soon I will be back home.

@ollo69 ollo69 added the enhancement New feature or request label Mar 3, 2023
@tanuva
Copy link

tanuva commented Mar 13, 2023

I'm running HA on Python 3.10.10 and also got an error logged when HA tried to install cchardet as a dependency of smartthinq-sensors. OP's suggestion (and updating manifest.json) got me to the account information screen. \o/
Let's see how the rest works out. :)

@kleytonn
Copy link

kleytonn commented Mar 16, 2023 via email

@SergioRius
Copy link

SergioRius commented Mar 17, 2023

You need to change manifest.json do not try to install cchardet.

Thank you very much Kleytonn. That solved my problem.

@ollo69
Copy link
Owner

ollo69 commented Apr 7, 2023

Change implemented in last release, I close this issue. Please open a new one in case of problems.

@ollo69 ollo69 closed this as completed Apr 7, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

5 participants