• 1
  • 3
  • 4
  • 5(current)
  • 6
  • 7
  • 8
Release IMDb Trailers Addon
#61
(2022-12-29, 08:46)gujal Wrote:
(2022-12-28, 05:40)gargamon Wrote: Thanks for this. I applied it manually to my local copy and it works great.

It still hasn't been released in the normal channels...
I am trying to figure out how to fix the deprecation notice on setcast() in Kodi Nexus 20. Will release once i get it working
This is kind of a drive-by post, but you might want to look at jurialmunkey wrote a little conversion module script.module.infotagger https://github.com/jurialmunkey/script.m...infotagger it isn't in Kodi repo so you would have to zip it and install from zip, but might be worth checking out.

scott s.
.
Reply
#62
@host505 @scott967 
Thanks for the pointers and sample code from host505, I have now got rid of the below message in the logs
Code:
warning <general>: ListItem.setCast() is deprecated and might be removed in future Kodi versions. Please use InfoTagVideo.setCast().
Those messages were being logged for each item in the list so log was full of them.

Now I have to figure out which infolabel is logging this message and have to fix it (though it is only on message per list)
Code:
warning <general>: Setting most video properties through ListItem.setInfo() is deprecated and might be removed in future Kodi versions. Please use the respective setter in InfoTagVideo.
Is Listitem.setInfo() not advisable at all in Kodi 20?
Kodi 21 Windows 10 and 11 | 21 Xbox One X | 21 Linux Mint Virginia XFCE | CoreELEC NO 21 nightly S905X4 aarch64
Reply
#63
(2022-12-30, 03:33)gujal Wrote: @host505 @scott967 
Thanks for the pointers and sample code from host505, I have now got rid of the below message in the logs
 
Code:
warning <general>: ListItem.setCast() is deprecated and might be removed in future Kodi versions. Please use InfoTagVideo.setCast().
Those messages were being logged for each item in the list so log was full of them.

Now I have to figure out which infolabel is logging this message and have to fix it (though it is only on message per list)
 
Code:
warning <general>: Setting most video properties through ListItem.setInfo() is deprecated and might be removed in future Kodi versions. Please use the respective setter in InfoTagVideo.
Is Listitem.setInfo() not advisable at all in Kodi 20?

Here's a developer thread on this topic.  Listitem.setInfo() is still supported in Kodi 20 but the deprecation message is telling you that it may be eliminated in the future.  If you want to get rid of those deprecation messages the choice will be to write a Kodi 20+ version of the addion or determine the version number in a common version of the addon and then do either a InfoTagVideo setter approach when running under Kodi 20 or a ListItem.setInfo() when running on Kodi 19.  As you can tell from the thread I attached, I went the detect version approach. 

Here's a code snippet:

def get_installedversion():
    # retrieve current installed version
    json_query = xbmc.executeJSONRPC('{ "jsonrpc": "2.0", "method": "Application.GetProperties", "params": {"properties": ["version", "name"]}, "id": 1 }')
    json_query = json.loads(json_query)
    version_installed = []
    if 'result' in json_query and 'version' in json_query['result']:
        version_installed  = json_query['result']['version']['major']
    return str(version_installed)

installed_version = get_installedversion()
mediaClass_text = 'video'

                    if installed_version == '19':   
                        info = {
                                  'title': title,
                                    .....
                                  )
                        li.setInfo(mediaClass_text, info)

                    else:
                        vinfo = li.getVideoInfoTag()
                        vinfo.setTitle(title)
                        .........

I can help you with specific InfoTagVideo setters.


Thanks,

Jeff
Running with the Mezzmo Kodi addon.  The easier way to share your media with multiple Kodi clients.
Service.autostop , CBC Sports, Kodi Selective Cleaner and Mezzmo Kodi addon author.
Reply
#64
@gujal sorry, I thought you were already working on getVideoInfoTag() methods and got stuck on setCast.
I can make a pr with all needed changes regarding getVideoInfoTag() if you wish, the approach would be the same as @jbinkley60 's
Reply
#65
Ok here's my take on it. I didn't touch the labels' items, maybe it takes some optimisations/fallback values to them to avoid some hacks like the setRating one lol
Also I didn't do the listitems on play and play_id.
https://gist.github.com/bleak-lodge/5777...150051050e
You can check the revisions for the diff with current master.
Reply
#66
Hi. Nothing works on my side. i have the following error message : https://paste.kodi.tv/esugigodur.kodi

When checking the resources/lib/client.py file, I see the CERT_FILE variable with value 'TRANSLATEPATH('special://xbmc/system/certs/cacert.pem')'.
Problem, on Linux/Mageia 8 with Kodi 19.5 I do not have a certs/ folder inside the system/ kodi install.
Is there a solution ? Thank you.
Reply
#67
(2022-12-30, 16:29)host505 Wrote: Ok here's my take on it. I didn't touch the labels' items, maybe it takes some optimisations/fallback values to them to avoid some hacks like the setRating one lol
Also I didn't do the listitems on play and play_id.
https://gist.github.com/bleak-lodge/5777...150051050e
You can check the revisions for the diff with current master.
Thanks for that, yeah the new videoinfotag method seems unnecessarily complicated compared to the simple setting of everything in a single dict as infolabels. Setting each label individually is a lot of code. Wasn't looking forward to it. In RC1 it was only logging setcast2 deprecation notice, so I was only trying to get that working. The infolabel deprecation notice only started after I updated to RC2 yesterday and didnt spend much time on it. Thanks for the pointers will adapt and raise a PR into the repo-plugins git

@jbinkley60 Thanks for the pointers, I already have a conditional to check kodi version and then use videoinfotag, didn't realise that the entire infolabels method needs to be changed to videoinfotag for nexus
Code:
_kodiver = float(xbmcaddon.Addon('xbmc.addon').getAddonInfo('version')[:4])
listitem.setInfo(type='Video', infoLabels=labels)  # logs deprecation notice in Nexus
if _kodiver < 19.8:
    listitem.setCast(cast2)
else:
    vtag = listitem.getVideoInfoTag()
    cast2 = [xbmc.Actor(p['name'], '', 0, p['thumbnail']) for p in cast2]
    vtag.setCast(cast2)
Kodi 21 Windows 10 and 11 | 21 Xbox One X | 21 Linux Mint Virginia XFCE | CoreELEC NO 21 nightly S905X4 aarch64
Reply
#68
(2022-12-30, 18:34)aztorius Wrote: Hi. Nothing works on my side. i have the following error message : https://paste.kodi.tv/esugigodur.kodi

When checking the resources/lib/client.py file, I see the CERT_FILE variable with value 'TRANSLATEPATH('special://xbmc/system/certs/cacert.pem')'.
Problem, on Linux/Mageia 8 with Kodi 19.5 I do not have a certs/ folder inside the system/ kodi install.
Is there a solution ? Thank you.

I test under Ubuntu LTS based Linux Mint and there the 'TRANSLATEPATH('special://xbmc/system/certs/cacert.pem')' resolves to
Code:
/usr/share/kodi/system/certs/cacert.pem
and works correctly.
Team Kodi only releases packages for debian based distros. As you are running a redhat based system, I have no idea who compiles kodi for that or why cacert.pem is not present in the expected location
Can you run the following command and provide the output here so that we can see where the file is?
Code:
sudo find / -depth -name cacert.pem -print 2>/dev/null
Kodi 21 Windows 10 and 11 | 21 Xbox One X | 21 Linux Mint Virginia XFCE | CoreELEC NO 21 nightly S905X4 aarch64
Reply
#69
(2022-12-28, 05:40)gargamon Wrote: Thanks for this. I applied it manually to my local copy and it works great.

It still hasn't been released in the normal channels...

Okay thanks to @host505 PR has been raised for Matrix and above. Now have to wait for Team Kodi to approve and merge before I can raise a PR for Leia
 
Code:
https://github.com/xbmc/repo-plugins/pull/4197
https://github.com/xbmc/repo-plugins/pull/4198

Update: Has now been merged by Team Kodi into Leia, Matrix and Nexus branches. Please go ahead and test.
Kodi 21 Windows 10 and 11 | 21 Xbox One X | 21 Linux Mint Virginia XFCE | CoreELEC NO 21 nightly S905X4 aarch64
Reply
#70
Hello,
I Have this running on a channel in my PSEudo TV Live on Kodi, but I was wondering if there is a switch or a way to make this only show english language previews. Some of the Chinese and Indian movies do look good, but I can't understand them at all. lol.
Reply
#71
I'm utilizing this in a context addon I did (for my own use) which automatically searches for a trailer based on the current listitem and then plays the first result returned.

It works out great, haven't had a miss result yet. (Searches by title+year)

Thank you very much for your efforts.
Reply
#72
(2023-01-12, 07:03)OzDrDj Wrote: Hello,
I Have this running on a channel in my PSEudo TV Live on Kodi, but I was wondering if there is a switch or a way to make this only show english language previews. Some of the Chinese and Indian movies do look good, but I can't understand them at all. lol.
Unfortunately cant be done as the language information is not provided by IMdB for the trailers
Code:
https://www.imdb.com/trailers/
Kodi 21 Windows 10 and 11 | 21 Xbox One X | 21 Linux Mint Virginia XFCE | CoreELEC NO 21 nightly S905X4 aarch64
Reply
#73
Thanks For That,
I have worked out You Tube on PSEUDO TV now, so IMDB is gone and Rotten Toamtoes Trailers are in. Works a Champion.
Reply
#74
How to make default audio language in English?
Reply
#75
(2023-03-13, 00:29)CouchGuy Wrote: How to make default audio language in English?

There is no setting as the page that gets served by IMdB is based on your location and fronted by Amazon CloudFront. No way to filter on language
Kodi 21 Windows 10 and 11 | 21 Xbox One X | 21 Linux Mint Virginia XFCE | CoreELEC NO 21 nightly S905X4 aarch64
Reply
  • 1
  • 3
  • 4
  • 5(current)
  • 6
  • 7
  • 8

Logout Mark Read Team Forum Stats Members Help
IMDb Trailers Addon1
This forum uses Lukasz Tkacz MyBB addons.