-
-
Notifications
You must be signed in to change notification settings - Fork 31.8k
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
Fix for errors on missing preview on LG webos TV #6755
Conversation
@masarliev, thanks for your PR! By analyzing the history of the files in this pull request, we identified @TheRealLink, @trisk and @fabaff to be potential reviewers. |
@masarliev Could you explain the issue with |
OK, I see details in the linked issue. |
I don't remember exact value but is something like http://ip-address:port/path/to/icon.png |
Maybe it depends on webos version |
I looked in the paths in the issue. so it looks like it depends in the webos version. the issue specify webos v1.4 while in my webos v2 both icon and largeIcon are urls. 'icon': 'http://192.168.31.64:3000/resources/09216e4e921f2209fe0749fbbf99952236fd032e/icon.png', bummer. I guess we need to use icon (or use largeIcon if it's url and fallback to icon if not) |
@@ -240,7 +240,7 @@ def media_content_type(self): | |||
def media_image_url(self): | |||
"""Image url of current playing media.""" | |||
if self._current_source_id in self._app_list: | |||
return self._app_list[self._current_source_id]['largeIcon'] | |||
return self._app_list[self._current_source_id]['icon'] |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
in webos v2 largeIcon is a url and looks better so I suggest maybe check if largeIcon is not a url fallback to icon?
e.g.
if self._current_source_id in self._app_list:
icon = self._app_list[self._current_source_id]['largeIcon']
if not icon.startswith('http'):
icon = self._app_list[self._current_source_id]['icon']
return icon
return None
any thoughts?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM. I will change like this
LGTM. the 2 commits could be squashed into 1 in my opinion. |
I have a squash and merge button @roidayan 👍 |
Description:
largeIcon property on my TV and I guess other versions is file path. That's why it can not be requested as HTTP URI. I changed it to icon property that is the icon of current playing source.
Related issue (if applicable): fixes #5113