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

fujitsu_fglair: TypeError: int() argument must be a string, a bytes-like object or a real number, not 'NoneType' #127742

Closed
fdcastel opened this issue Oct 6, 2024 · 10 comments · Fixed by #129743

Comments

@fdcastel
Copy link

fdcastel commented Oct 6, 2024

The problem

Simply adding the integration to latest Home Assistant causes the following error in log:

2024-10-06 12:43:13.379 ERROR (MainThread) [homeassistant.components.climate] Error while setting up fujitsu_fglair platform for climate
Traceback (most recent call last):
  File "/usr/src/homeassistant/homeassistant/helpers/entity_platform.py", line 369, in _async_setup_platform
    await asyncio.gather(*pending)
  File "/usr/src/homeassistant/homeassistant/helpers/entity_platform.py", line 628, in async_add_entities
    for entity in new_entities:
  File "/usr/src/homeassistant/homeassistant/components/fujitsu_fglair/climate.py", line 70, in <genexpr>
    FGLairDevice(entry.runtime_data, device)
  File "/usr/src/homeassistant/homeassistant/components/fujitsu_fglair/climate.py", line 112, in __init__
    self._set_attr()
  File "/usr/src/homeassistant/homeassistant/components/fujitsu_fglair/climate.py", line 168, in _set_attr
    self._attr_current_temperature = self.device.sensed_temp
                                     ^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/local/lib/python3.12/site-packages/ayla_iot_unofficial/fujitsu_hvac.py", line 292, in sensed_temp
    int(self.property_values[DISPLAY_TEMP])
TypeError: int() argument must be a string, a bytes-like object or a real number, not 'NoneType'

What version of Home Assistant Core has the issue?

core-2024.10.1

What was the last working version of Home Assistant Core?

No response

What type of installation are you running?

Home Assistant Container

Integration causing the issue

fujitsu_fglair

Link to integration documentation on our website

https://www.home-assistant.io/integrations/fujitsu_fglair/

Diagnostics information

home-assistant_fujitsu_fglair_2024-10-06T15-53-00.492Z.log

Example YAML snippet

No response

Anything in the logs that might be useful for us?

No response

Additional information

Maybe related: #125274

@home-assistant
Copy link

home-assistant bot commented Oct 6, 2024

Hey there @crevetor, mind taking a look at this issue as it has been labeled with an integration (fujitsu_fglair) you are listed as a code owner for? Thanks!

Code owner commands

Code owners of fujitsu_fglair can trigger bot actions by commenting:

  • @home-assistant close Closes the issue.
  • @home-assistant rename Awesome new title Renames the issue.
  • @home-assistant reopen Reopen the issue.
  • @home-assistant unassign fujitsu_fglair Removes the current integration label and assignees on the issue, add the integration domain after the command.
  • @home-assistant add-label needs-more-information Add a label (needs-more-information, problem in dependency, problem in custom component) to the issue.
  • @home-assistant remove-label needs-more-information Remove a label (needs-more-information, problem in dependency, problem in custom component) on the issue.

(message by CodeOwnersMention)


fujitsu_fglair documentation
fujitsu_fglair source
(message by IssueLinks)

@fdcastel fdcastel changed the title fujitsu_fglair: TypeError: int() argument must be a string, a bytes-like object or a real number, not 'NoneType fujitsu_fglair: TypeError: int() argument must be a string, a bytes-like object or a real number, not 'NoneType' Oct 6, 2024
@charstring1
Copy link

Same here.

Source: helpers/entity_platform.py:369
integration: Climate (documentation, issues)
First occurred: October 6, 2024 at 12:04:17 PM (2 occurrences)
Last logged: October 6, 2024 at 7:46:48 PM

Error while setting up fujitsu_fglair platform for climate
Traceback (most recent call last):
  File "/usr/src/homeassistant/homeassistant/helpers/entity_platform.py", line 369, in _async_setup_platform
    await asyncio.gather(*pending)
  File "/usr/src/homeassistant/homeassistant/helpers/entity_platform.py", line 628, in async_add_entities
    for entity in new_entities:
  File "/usr/src/homeassistant/homeassistant/components/fujitsu_fglair/climate.py", line 70, in <genexpr>
    FGLairDevice(entry.runtime_data, device)
  File "/usr/src/homeassistant/homeassistant/components/fujitsu_fglair/climate.py", line 112, in __init__
    self._set_attr()
  File "/usr/src/homeassistant/homeassistant/components/fujitsu_fglair/climate.py", line 168, in _set_attr
    self._attr_current_temperature = self.device.sensed_temp
                                     ^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/local/lib/python3.12/site-packages/ayla_iot_unofficial/fujitsu_hvac.py", line 292, in sensed_temp
    int(self.property_values[DISPLAY_TEMP])
TypeError: int() argument must be a string, a bytes-like object or a real number, not 'NoneType'

@markoweb
Copy link

Having the same issue

@fdcastel
Copy link
Author

@crevetor could you bring us some light here? 😉

@allansari
Copy link

allansari commented Nov 1, 2024

Unfortunately I have got the same problem as shown below:


Logger: homeassistant.components.climate
Source: helpers/entity_platform.py:369
integration: Climate (documentation, issues)
First occurred: 1:45:36 AM (2 occurrences)
Last logged: 2:01:48 AM

Error while setting up fujitsu_fglair platform for climate
Traceback (most recent call last):
File "/usr/src/homeassistant/homeassistant/helpers/entity_platform.py", line 369, in _async_setup_platform
await asyncio.gather(*pending)
File "/usr/src/homeassistant/homeassistant/helpers/entity_platform.py", line 628, in async_add_entities
for entity in new_entities:
File "/usr/src/homeassistant/homeassistant/components/fujitsu_fglair/climate.py", line 70, in
FGLairDevice(entry.runtime_data, device)
File "/usr/src/homeassistant/homeassistant/components/fujitsu_fglair/climate.py", line 112, in init
self._set_attr()
File "/usr/src/homeassistant/homeassistant/components/fujitsu_fglair/climate.py", line 168, in _set_attr
self._attr_current_temperature = self.device.sensed_temp
^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/local/lib/python3.12/site-packages/ayla_iot_unofficial/fujitsu_hvac.py", line 292, in sensed_temp
int(self.property_values[DISPLAY_TEMP])
TypeError: int() argument must be a string, a bytes-like object or a real number, not 'NoneType'

@crevetor
Copy link
Contributor

crevetor commented Nov 1, 2024

Sorry, I hadn't had time to look at this. I'll check it out this weekend.

@allansari
Copy link

Really appreciate it

Sorry, I hadn't had time to look at this. I'll check it out this weekend.

@allansari
Copy link

Also I got this when tried to add FGLair heat pump controller integration
FGLair heat pump controller integration

Logger: py.warnings
Source: /usr/local/lib/python3.12/warnings.py:112
First occurred: 2:25:24 AM (1 occurrences)
Last logged: 2:25:24 AM

/usr/local/lib/python3.12/json/init.py:180: RuntimeWarning: coroutine '_make_delegate_method..method' was never awaited fp.write(chunk)

@crevetor
Copy link
Contributor

crevetor commented Nov 1, 2024

This should fix it : rewardone/ayla-iot-unofficial#38

Once the PR is merged and a new package version is published I will update the HA component to use the new version.

@rewardone
Copy link

This should fix it : rewardone/ayla-iot-unofficial#38

Once the PR is merged and a new package version is published I will update the HA component to use the new version.

Thank you for your continued support. 1.4.3 published.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging a pull request may close this issue.

6 participants