dylandoamaral / trakt-integration

A Trakt integration for Home Assistant compatible with upcoming media card
MIT License
30 stars 12 forks source link

KeyError: 'title' #37

Closed dylandoamaral closed 2 years ago

dylandoamaral commented 2 years ago

I now have a new error.

This error originated from a custom integration.

Logger: custom_components.trakt_tv Source: custom_components/trakt_tv/models/media.py:115 Integration: Trakt (documentation, issues) First occurred: 17:49:34 (5 occurrences) Last logged: 17:50:53

Unexpected error fetching trakt data: 'title' Traceback (most recent call last): File "/usr/src/homeassistant/homeassistant/helpers/update_coordinator.py", line 191, in _async_refresh self.data = await self._async_update_data() File "/usr/src/homeassistant/homeassistant/helpers/update_coordinator.py", line 150, in _async_update_data return await self.update_method() File "/config/custom_components/trakt_tv/apis/trakt.py", line 145, in retrieve_data data = await gather( File "/config/custom_components/trakt_tv/apis/trakt.py", line 110, in fetch_upcomings data = await gather( File "/config/custom_components/trakt_tv/apis/trakt.py", line 103, in fetch_upcoming medias = [trakt_kind.value.model.from_trakt(media) for media in raw_medias] File "/config/custom_components/trakt_tv/apis/trakt.py", line 103, in medias = [trakt_kind.value.model.from_trakt(media) for media in raw_medias] File "/config/custom_components/trakt_tv/models/media.py", line 115, in from_trakt name=movie["title"], KeyError: 'title'

Originally posted by @TNTPro in https://github.com/dylandoamaral/trakt-integration/issues/36#issuecomment-1126977852

mimuncito commented 2 years ago

Exactly the same.

TNTPro commented 2 years ago

All seems good now thanks.