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

Google Calendar on 2023.10.0b1 no longer loading #101085

Closed
markusg1234 opened this issue Sep 29, 2023 · 10 comments
Closed

Google Calendar on 2023.10.0b1 no longer loading #101085

markusg1234 opened this issue Sep 29, 2023 · 10 comments
Assignees

Comments

@markusg1234
Copy link

The problem

After updating to 2023.10.0b1 Google Calendar no longer loads.

What version of Home Assistant Core has the issue?

2023.10.0b1

What was the last working version of Home Assistant Core?

2023.9.3

What type of installation are you running?

Home Assistant OS

Integration causing the issue

Google Calendar

Link to integration documentation on our website

https://rc.home-assistant.io/integrations/google

Diagnostics information

No response

Example YAML snippet

No response

Anything in the logs that might be useful for us?

2023-09-29 08:51:27.807 ERROR (MainThread) [homeassistant.loader] Unexpected exception importing component homeassistant.components.google
File "/usr/src/homeassistant/homeassistant/components/google/__init__.py", line 10, in <module>
from gcal_sync.api import GoogleCalendarService
2023-09-29 08:51:27.810 ERROR (MainThread) [homeassistant.setup] Setup failed for google: Unable to import component: Exception importing homeassistant.components.google
File "/usr/src/homeassistant/homeassistant/components/google/__init__.py", line 10, in <module>
from gcal_sync.api import GoogleCalendarService
ImportError: Exception importing homeassistant.components.google

Additional information

No response

@home-assistant
Copy link

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

Code owner commands

Code owners of google 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 google Removes the current integration label and assignees on the issue, add the integration domain after the command.

(message by CodeOwnersMention)


google documentation
google source
(message by IssueLinks)

@allenporter
Copy link
Contributor

Hello, can you try b2 and determine if the issue still persists?

@markusg1234
Copy link
Author

Just updated to b2 and issue is fixed. Thanks.

@allenporter
Copy link
Contributor

Awesome, glad to hear it. I believe i saw in #beta on discord there was a pydantic issue, so glad to see that was resolved. Thanks for the report.

@konikvranik
Copy link
Contributor

Hello, I still have issue with GC in 2023.10.0 release:

Oct 05 09:17:15 hass.home hass[12592]: 2023-10-05 09:17:14.997 ERROR (MainThread) [homeassistant.loader] Unexpected exception importing component homeassistant.components.google
Oct 05 09:17:15 hass.home hass[12592]: Traceback (most recent call last):
Oct 05 09:17:15 hass.home hass[12592]:   File "/srv/homeassistant/lib/python3.11/site-packages/homeassistant/loader.py", line 818, in get_component
Oct 05 09:17:15 hass.home hass[12592]:     ComponentProtocol, importlib.import_module(self.pkg_path)
Oct 05 09:17:15 hass.home hass[12592]:                        ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
Oct 05 09:17:15 hass.home hass[12592]:   File "/usr/lib/python3.11/importlib/__init__.py", line 126, in import_module
Oct 05 09:17:15 hass.home hass[12592]:     return _bootstrap._gcd_import(name[level:], package, level)
Oct 05 09:17:15 hass.home hass[12592]:            ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
Oct 05 09:17:15 hass.home hass[12592]:   File "<frozen importlib._bootstrap>", line 1206, in _gcd_import
Oct 05 09:17:15 hass.home hass[12592]:   File "<frozen importlib._bootstrap>", line 1178, in _find_and_load
Oct 05 09:17:15 hass.home hass[12592]:   File "<frozen importlib._bootstrap>", line 1149, in _find_and_load_unlocked
Oct 05 09:17:15 hass.home hass[12592]:   File "<frozen importlib._bootstrap>", line 690, in _load_unlocked
Oct 05 09:17:15 hass.home hass[12592]:   File "<frozen importlib._bootstrap_external>", line 940, in exec_module
Oct 05 09:17:15 hass.home hass[12592]:   File "<frozen importlib._bootstrap>", line 241, in _call_with_frames_removed
Oct 05 09:17:15 hass.home hass[12592]:   File "/srv/homeassistant/lib/python3.11/site-packages/homeassistant/components/google/__init__.py", line 10, in <module>
Oct 05 09:17:15 hass.home hass[12592]:     from gcal_sync.api import GoogleCalendarService
Oct 05 09:17:15 hass.home hass[12592]:   File "/srv/homeassistant/lib/python3.11/site-packages/gcal_sync/api.py", line 33, in <module>
Oct 05 09:17:15 hass.home hass[12592]:     from .model import (
Oct 05 09:17:15 hass.home hass[12592]:   File "/srv/homeassistant/lib/python3.11/site-packages/gcal_sync/model.py", line 17, in <module>
Oct 05 09:17:15 hass.home hass[12592]:     from ical.component import ComponentModel
Oct 05 09:17:15 hass.home hass[12592]:   File "/srv/homeassistant/lib/python3.11/site-packages/ical/component.py", line 30, in <module>
Oct 05 09:17:15 hass.home hass[12592]:     from .types.data_types import DATA_TYPE
Oct 05 09:17:15 hass.home hass[12592]:   File "/srv/homeassistant/lib/python3.11/site-packages/ical/types/__init__.py", line 7, in <module>
Oct 05 09:17:15 hass.home hass[12592]:     from .cal_address import CalAddress
Oct 05 09:17:15 hass.home hass[12592]:   File "/srv/homeassistant/lib/python3.11/site-packages/ical/types/cal_address.py", line 54, in <module>
Oct 05 09:17:15 hass.home hass[12592]:     class CalAddress(BaseModel):
Oct 05 09:17:15 hass.home hass[12592]:   File "pydantic/main.py", line 186, in pydantic.main.ModelMetaclass.__new__
Oct 05 09:17:15 hass.home hass[12592]: TypeError: Argument 'bases' has incorrect type (expected list, got tuple)
Oct 05 09:17:15 hass.home hass[12592]: 2023-10-05 09:17:15.144 ERROR (MainThread) [homeassistant.setup] Setup failed for google: Unable to import component: Exception importing homeassistant.components.google
Oct 05 09:17:15 hass.home hass[12592]: Traceback (most recent call last):
Oct 05 09:17:15 hass.home hass[12592]:   File "/srv/homeassistant/lib/python3.11/site-packages/homeassistant/loader.py", line 818, in get_component
Oct 05 09:17:15 hass.home hass[12592]:     ComponentProtocol, importlib.import_module(self.pkg_path)
Oct 05 09:17:15 hass.home hass[12592]:                        ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
Oct 05 09:17:15 hass.home hass[12592]:   File "/usr/lib/python3.11/importlib/__init__.py", line 126, in import_module
Oct 05 09:17:15 hass.home hass[12592]:     return _bootstrap._gcd_import(name[level:], package, level)
Oct 05 09:17:15 hass.home hass[12592]:            ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
Oct 05 09:17:15 hass.home hass[12592]:   File "<frozen importlib._bootstrap>", line 1206, in _gcd_import
Oct 05 09:17:15 hass.home hass[12592]:   File "<frozen importlib._bootstrap>", line 1178, in _find_and_load
Oct 05 09:17:15 hass.home hass[12592]:   File "<frozen importlib._bootstrap>", line 1149, in _find_and_load_unlocked
Oct 05 09:17:15 hass.home hass[12592]:   File "<frozen importlib._bootstrap>", line 690, in _load_unlocked
Oct 05 09:17:15 hass.home hass[12592]:   File "<frozen importlib._bootstrap_external>", line 940, in exec_module
Oct 05 09:17:15 hass.home hass[12592]:   File "<frozen importlib._bootstrap>", line 241, in _call_with_frames_removed
Oct 05 09:17:15 hass.home hass[12592]:   File "/srv/homeassistant/lib/python3.11/site-packages/homeassistant/components/google/__init__.py", line 10, in <module>
Oct 05 09:17:15 hass.home hass[12592]:     from gcal_sync.api import GoogleCalendarService
Oct 05 09:17:15 hass.home hass[12592]:   File "/srv/homeassistant/lib/python3.11/site-packages/gcal_sync/api.py", line 33, in <module>
Oct 05 09:17:15 hass.home hass[12592]:     from .model import (
Oct 05 09:17:15 hass.home hass[12592]:   File "/srv/homeassistant/lib/python3.11/site-packages/gcal_sync/model.py", line 17, in <module>
Oct 05 09:17:15 hass.home hass[12592]:     from ical.component import ComponentModel
Oct 05 09:17:15 hass.home hass[12592]:   File "/srv/homeassistant/lib/python3.11/site-packages/ical/component.py", line 30, in <module>
Oct 05 09:17:15 hass.home hass[12592]:     from .types.data_types import DATA_TYPE
Oct 05 09:17:15 hass.home hass[12592]:   File "/srv/homeassistant/lib/python3.11/site-packages/ical/types/__init__.py", line 7, in <module>
Oct 05 09:17:15 hass.home hass[12592]:     from .cal_address import CalAddress
Oct 05 09:17:15 hass.home hass[12592]:   File "/srv/homeassistant/lib/python3.11/site-packages/ical/types/cal_address.py", line 54, in <module>
Oct 05 09:17:15 hass.home hass[12592]:     class CalAddress(BaseModel):
Oct 05 09:17:15 hass.home hass[12592]:   File "pydantic/main.py", line 186, in pydantic.main.ModelMetaclass.__new__
Oct 05 09:17:15 hass.home hass[12592]: TypeError: Argument 'bases' has incorrect type (expected list, got tuple)
Oct 05 09:17:15 hass.home hass[12592]: The above exception was the direct cause of the following exception:
Oct 05 09:17:15 hass.home hass[12592]: Traceback (most recent call last):
Oct 05 09:17:15 hass.home hass[12592]:   File "/srv/homeassistant/lib/python3.11/site-packages/homeassistant/setup.py", line 215, in _async_setup_component
Oct 05 09:17:15 hass.home hass[12592]:     component = integration.get_component()
Oct 05 09:17:15 hass.home hass[12592]:                 ^^^^^^^^^^^^^^^^^^^^^^^^^^^
Oct 05 09:17:15 hass.home hass[12592]:   File "/srv/homeassistant/lib/python3.11/site-packages/homeassistant/loader.py", line 826, in get_component
Oct 05 09:17:15 hass.home hass[12592]:     raise ImportError(f"Exception importing {self.pkg_path}") from err
Oct 05 09:17:15 hass.home hass[12592]: ImportError: Exception importing homeassistant.components.google

@bvdkerkhof
Copy link

Also having the same issue in the 2023.10.0 release as stated by konikvranik

Hello, I still have issue with GC in 2023.10.0 release:

Oct 05 09:17:15 hass.home hass[12592]: 2023-10-05 09:17:14.997 ERROR (MainThread) [homeassistant.loader] Unexpected exception importing component homeassistant.components.google
Oct 05 09:17:15 hass.home hass[12592]: Traceback (most recent call last):
Oct 05 09:17:15 hass.home hass[12592]:   File "/srv/homeassistant/lib/python3.11/site-packages/homeassistant/loader.py", line 818, in get_component
Oct 05 09:17:15 hass.home hass[12592]:     ComponentProtocol, importlib.import_module(self.pkg_path)
Oct 05 09:17:15 hass.home hass[12592]:                        ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
Oct 05 09:17:15 hass.home hass[12592]:   File "/usr/lib/python3.11/importlib/__init__.py", line 126, in import_module
Oct 05 09:17:15 hass.home hass[12592]:     return _bootstrap._gcd_import(name[level:], package, level)
Oct 05 09:17:15 hass.home hass[12592]:            ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
Oct 05 09:17:15 hass.home hass[12592]:   File "<frozen importlib._bootstrap>", line 1206, in _gcd_import
Oct 05 09:17:15 hass.home hass[12592]:   File "<frozen importlib._bootstrap>", line 1178, in _find_and_load
Oct 05 09:17:15 hass.home hass[12592]:   File "<frozen importlib._bootstrap>", line 1149, in _find_and_load_unlocked
Oct 05 09:17:15 hass.home hass[12592]:   File "<frozen importlib._bootstrap>", line 690, in _load_unlocked
Oct 05 09:17:15 hass.home hass[12592]:   File "<frozen importlib._bootstrap_external>", line 940, in exec_module
Oct 05 09:17:15 hass.home hass[12592]:   File "<frozen importlib._bootstrap>", line 241, in _call_with_frames_removed
Oct 05 09:17:15 hass.home hass[12592]:   File "/srv/homeassistant/lib/python3.11/site-packages/homeassistant/components/google/__init__.py", line 10, in <module>
Oct 05 09:17:15 hass.home hass[12592]:     from gcal_sync.api import GoogleCalendarService
Oct 05 09:17:15 hass.home hass[12592]:   File "/srv/homeassistant/lib/python3.11/site-packages/gcal_sync/api.py", line 33, in <module>
Oct 05 09:17:15 hass.home hass[12592]:     from .model import (
Oct 05 09:17:15 hass.home hass[12592]:   File "/srv/homeassistant/lib/python3.11/site-packages/gcal_sync/model.py", line 17, in <module>
Oct 05 09:17:15 hass.home hass[12592]:     from ical.component import ComponentModel
Oct 05 09:17:15 hass.home hass[12592]:   File "/srv/homeassistant/lib/python3.11/site-packages/ical/component.py", line 30, in <module>
Oct 05 09:17:15 hass.home hass[12592]:     from .types.data_types import DATA_TYPE
Oct 05 09:17:15 hass.home hass[12592]:   File "/srv/homeassistant/lib/python3.11/site-packages/ical/types/__init__.py", line 7, in <module>
Oct 05 09:17:15 hass.home hass[12592]:     from .cal_address import CalAddress
Oct 05 09:17:15 hass.home hass[12592]:   File "/srv/homeassistant/lib/python3.11/site-packages/ical/types/cal_address.py", line 54, in <module>
Oct 05 09:17:15 hass.home hass[12592]:     class CalAddress(BaseModel):
Oct 05 09:17:15 hass.home hass[12592]:   File "pydantic/main.py", line 186, in pydantic.main.ModelMetaclass.__new__
Oct 05 09:17:15 hass.home hass[12592]: TypeError: Argument 'bases' has incorrect type (expected list, got tuple)
Oct 05 09:17:15 hass.home hass[12592]: 2023-10-05 09:17:15.144 ERROR (MainThread) [homeassistant.setup] Setup failed for google: Unable to import component: Exception importing homeassistant.components.google
Oct 05 09:17:15 hass.home hass[12592]: Traceback (most recent call last):
Oct 05 09:17:15 hass.home hass[12592]:   File "/srv/homeassistant/lib/python3.11/site-packages/homeassistant/loader.py", line 818, in get_component
Oct 05 09:17:15 hass.home hass[12592]:     ComponentProtocol, importlib.import_module(self.pkg_path)
Oct 05 09:17:15 hass.home hass[12592]:                        ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
Oct 05 09:17:15 hass.home hass[12592]:   File "/usr/lib/python3.11/importlib/__init__.py", line 126, in import_module
Oct 05 09:17:15 hass.home hass[12592]:     return _bootstrap._gcd_import(name[level:], package, level)
Oct 05 09:17:15 hass.home hass[12592]:            ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
Oct 05 09:17:15 hass.home hass[12592]:   File "<frozen importlib._bootstrap>", line 1206, in _gcd_import
Oct 05 09:17:15 hass.home hass[12592]:   File "<frozen importlib._bootstrap>", line 1178, in _find_and_load
Oct 05 09:17:15 hass.home hass[12592]:   File "<frozen importlib._bootstrap>", line 1149, in _find_and_load_unlocked
Oct 05 09:17:15 hass.home hass[12592]:   File "<frozen importlib._bootstrap>", line 690, in _load_unlocked
Oct 05 09:17:15 hass.home hass[12592]:   File "<frozen importlib._bootstrap_external>", line 940, in exec_module
Oct 05 09:17:15 hass.home hass[12592]:   File "<frozen importlib._bootstrap>", line 241, in _call_with_frames_removed
Oct 05 09:17:15 hass.home hass[12592]:   File "/srv/homeassistant/lib/python3.11/site-packages/homeassistant/components/google/__init__.py", line 10, in <module>
Oct 05 09:17:15 hass.home hass[12592]:     from gcal_sync.api import GoogleCalendarService
Oct 05 09:17:15 hass.home hass[12592]:   File "/srv/homeassistant/lib/python3.11/site-packages/gcal_sync/api.py", line 33, in <module>
Oct 05 09:17:15 hass.home hass[12592]:     from .model import (
Oct 05 09:17:15 hass.home hass[12592]:   File "/srv/homeassistant/lib/python3.11/site-packages/gcal_sync/model.py", line 17, in <module>
Oct 05 09:17:15 hass.home hass[12592]:     from ical.component import ComponentModel
Oct 05 09:17:15 hass.home hass[12592]:   File "/srv/homeassistant/lib/python3.11/site-packages/ical/component.py", line 30, in <module>
Oct 05 09:17:15 hass.home hass[12592]:     from .types.data_types import DATA_TYPE
Oct 05 09:17:15 hass.home hass[12592]:   File "/srv/homeassistant/lib/python3.11/site-packages/ical/types/__init__.py", line 7, in <module>
Oct 05 09:17:15 hass.home hass[12592]:     from .cal_address import CalAddress
Oct 05 09:17:15 hass.home hass[12592]:   File "/srv/homeassistant/lib/python3.11/site-packages/ical/types/cal_address.py", line 54, in <module>
Oct 05 09:17:15 hass.home hass[12592]:     class CalAddress(BaseModel):
Oct 05 09:17:15 hass.home hass[12592]:   File "pydantic/main.py", line 186, in pydantic.main.ModelMetaclass.__new__
Oct 05 09:17:15 hass.home hass[12592]: TypeError: Argument 'bases' has incorrect type (expected list, got tuple)
Oct 05 09:17:15 hass.home hass[12592]: The above exception was the direct cause of the following exception:
Oct 05 09:17:15 hass.home hass[12592]: Traceback (most recent call last):
Oct 05 09:17:15 hass.home hass[12592]:   File "/srv/homeassistant/lib/python3.11/site-packages/homeassistant/setup.py", line 215, in _async_setup_component
Oct 05 09:17:15 hass.home hass[12592]:     component = integration.get_component()
Oct 05 09:17:15 hass.home hass[12592]:                 ^^^^^^^^^^^^^^^^^^^^^^^^^^^
Oct 05 09:17:15 hass.home hass[12592]:   File "/srv/homeassistant/lib/python3.11/site-packages/homeassistant/loader.py", line 826, in get_component
Oct 05 09:17:15 hass.home hass[12592]:     raise ImportError(f"Exception importing {self.pkg_path}") from err
Oct 05 09:17:15 hass.home hass[12592]: ImportError: Exception importing homeassistant.components.google

@allenporter
Copy link
Contributor

Hi,

If running HA Core this is because something in the environment you manag needs to be adjusted: #101443 (comment)

If running Home Assistant OS, then custom components that are breaking home assistant need to be disabled and core needs to be rebuilt: #101443 (comment)

@konikvranik
Copy link
Contributor

I recreated the venv, cleared caches and the issue persists even on 2023.9.3 now, which was working before upgrade. So it looks like the 2023.10.0 somehow broke the environment or the data.

@ALaDoffe
Copy link

ALaDoffe commented Oct 6, 2023

As Workaround, after testing several versions of pydantic, my HA running well with pydantic 1.10.10

$ pip install pydantic==1.10.10
$ python -c "import pydantic.utils; print(pydantic.utils.version_info())"
pydantic version: 1.10.10
pydantic compiled: False
install path: /srv/homeassistant/lib/python3.11/site-packages/pydantic
python version: 3.11.2 (main, Mar 13 2023, 12:18:29) [GCC 12.2.0]
platform: Linux-6.1.55-v7+-armv7l-with-glibc2.36
optional deps. installed: ['typing-extensions']

@konikvranik
Copy link
Contributor

konikvranik commented Oct 6, 2023

Hi @ALaDoffe , thank you for your hint. I tried it too and it really works. Even with 2023.10.0. Also other affected integrations like z-wave and rainbird work with it.

@github-actions github-actions bot locked and limited conversation to collaborators Nov 5, 2023
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

No branches or pull requests

5 participants