Any of you have problem with Kodi after upgrading to 0.28?
First (after upgrading) I noticed in the log that it could not login (which is strange as I did not change anything) then I added a username/password in kodi. Tested it (if have other software aso using direct communication with Kodi) and I’m sure Kodi is accessible.
Still no go.“homeassistant.components.media_player.kodi: Unable to fetch kodi data”
I migrated the kodi media player platform to do configuration checks. As far as I remember was it not a breaking change, only user is now username. Sorry, the docs were not up-to-date.
It’s wired that voluptuous didn’t catch the error. Does the platform work beside the fan art issue?
Fanart has never worked properly when using a username & password. This is because when using a username & password, the img url needs to be formatted as “http://USER:PASS@IPADDRESS/image/…”
As a quick hack/fix, I copied the kodi component to my custom_components/media_player/my_kodi.py then modified/hacked it to get it working.
Adding this @ line 78 hard coding my username & password. “MYUSER = kodi username, MYPASS = kodi password” self._img_url = url.replace("http://", "http://MYUSER:MYPASS@")
Then I modified the “_get_image_url” function, replacing self._url with self._img_url
def _get_image_url(self):
"""Helper function that parses the thumbnail URLs used by Kodi."""
url_components = urllib.parse.urlparse(self._item['thumbnail'])
if url_components.scheme == 'image':
return '{}/image/{}'.format(
self._img_url,
urllib.parse.quote_plus(self._item['thumbnail']))
This was just a quick hack to get it working until I had time to play around with a proper fix or sombody with more python knowledge than me had a chance to fix it as my python skill level is just barely novice.