• 1
  • 2(current)
  • 3
  • 4
  • 5
  • 8
Release IMDb Trailers Addon
#16
(2020-11-26, 09:04)Desperados Wrote:
(2020-02-28, 14:16)gujal Wrote: You can also call this addon from other addons or in STRM files as below.
plugin://plugin.video.imdb.trailers/?action=play_id&imdb=imdb_id
For e.g.,
plugin://plugin.video.imdb.trailers/?action=play_id&imdb=tt0113957
So I just read about this addon and had never heard about it before. My setup now uses the YouTube addon to play trailers but I'm curious about this one now. How exactly does this work with STRM files? Do you have to put the link as you mentioned in every movie and tv show NFO file manually? Or can it somehow be written in an xml file somewhere in the skin? Thanks Big Grin

Sorry, I do not know how to integrate with a skin, Please check with a skilled skinner like @beatmasterrs
Kodi 21 Windows 10 and 11 | 21 Xbox One X | 21 Linux Mint Virginia XFCE | CoreELEC NO 21 nightly S905X4 aarch64
Reply
#17
Hello,
I'm having troubles with the "Recently Added" section. It seems to be a transient issue in that it is broken for a period of time(weeks) then works for another period of weeks. It is the same on Linux and Android. There has been no addon update that I have noticed associated with the change from working to not working. 

If you have a bit of spare time maybe you could look at the following log segment to see what's going on:
2021-02-13 10:32:47.406 T:139898090682112   ERROR: EXCEPTION Thrown (PythonToCppException) : -->Python callback/script returned the following error<--
                                             - NOTE: IGNORING THIS CAN LEAD TO MEMORY LEAKS!
                                            Error Type: <type 'exceptions.AttributeError'>
                                            Error Contents: 'NoneType' object has no attribute 'get'
                                            Traceback (most recent call last):
                                              File "/home/my/.kodi/addons/plugin.video.imdb.trailers/default.py", line 23, in <module>
                                                imdb_trailers.Main()
                                              File "/home/my/.kodi/addons/plugin.video.imdb.trailers/resources/lib/imdb_trailers.py", line 77, in __init__
                                                self.list_contents3()
                                              File "/home/my/.kodi/addons/plugin.video.imdb.trailers/resources/lib/imdb_trailers.py", line 302, in list_contents3
                                                plot = video.get('description').get('value')
                                            AttributeError: 'NoneType' object has no attribute 'get'
                                            -->End of Python script error report<--
2021-02-13 10:32:47.487 T:139898065504000   ERROR: GetDirectory - Error getting plugin://plugin.video.imdb.trailers/?action=list3&key=recent
2021-02-13 10:32:47.512 T:139899767729344   ERROR: CGUIMediaWindow::GetDirectory(plugin://plugin.video.imdb.trailers/?action=list3&key=recent) failed

I appreciate any assistance you can give.
Reply
#18
(2021-02-13, 19:45)gargamon Wrote: Hello,
I'm having troubles with the "Recently Added" section. It seems to be a transient issue in that it is broken for a period of time(weeks) then works for another period of weeks. It is the same on Linux and Android. There has been no addon update that I have noticed associated with the change from working to not working. 

If you have a bit of spare time maybe you could look at the following log segment to see what's going on:
2021-02-13 10:32:47.406 T:139898090682112   ERROR: EXCEPTION Thrown (PythonToCppException) : -->Python callback/script returned the following error<--
                                             - NOTE: IGNORING THIS CAN LEAD TO MEMORY LEAKS!

                                              File "/home/my/.kodi/addons/plugin.video.imdb.trailers/resources/lib/imdb_trailers.py", line 302, in list_contents3
                                                plot = video.get('description').get('value')
                                            AttributeError: 'NoneType' object has no attribute 'get'
                                            -->End of Python script error report<--

I appreciate any assistance you can give.

Yeah, the error happens when a movie/show does not have a plot defined.
replace line 302 in imdb_trailers.py with the following line, until i release a fix in the official repo
Code:
plot = video.get('description').get('value') if video.get('description') else ''
Kodi 21 Windows 10 and 11 | 21 Xbox One X | 21 Linux Mint Virginia XFCE | CoreELEC NO 21 nightly S905X4 aarch64
Reply
#19
(2021-02-14, 03:34)gujal Wrote:
(2021-02-13, 19:45)gargamon Wrote: Hello,
I'm having troubles with the "Recently Added" section. It seems to be a transient issue in that it is broken for a period of time(weeks) then works for another period of weeks. It is the same on Linux and Android. There has been no addon update that I have noticed associated with the change from working to not working. 

If you have a bit of spare time maybe you could look at the following log segment to see what's going on:
2021-02-13 10:32:47.406 T:139898090682112   ERROR: EXCEPTION Thrown (PythonToCppException) : -->Python callback/script returned the following error<--
                                             - NOTE: IGNORING THIS CAN LEAD TO MEMORY LEAKS!

                                              File "/home/my/.kodi/addons/plugin.video.imdb.trailers/resources/lib/imdb_trailers.py", line 302, in list_contents3
                                                plot = video.get('description').get('value')
                                            AttributeError: 'NoneType' object has no attribute 'get'
                                            -->End of Python script error report<--

I appreciate any assistance you can give.

Yeah, the error happens when a movie/show does not have a plot defined.
replace line 302 in imdb_trailers.py with the following line, until i release a fix in the official repo
Code:
plot = video.get('description').get('value') if video.get('description') else ''

Thanks, that works great. 

I sure do appreciate you keeping this addon working. It is so much nicer than the IMDB one...
Reply
#20
(2021-02-14, 03:34)gujal Wrote: Yeah, the error happens when a movie/show does not have a plot defined.
replace line 302 in imdb_trailers.py with the following line, until i release a fix in the official repo
Code:
plot = video.get('description').get('value') if video.get('description') else ''

Thank you for the post and for the plugin. Any plans for a release incorporating this?
Need help programming a Streamzap remote?
Reply
#21
(2021-08-12, 09:29)graysky Wrote:
(2021-02-14, 03:34)gujal Wrote: Yeah, the error happens when a movie/show does not have a plot defined.
replace line 302 in imdb_trailers.py with the following line, until i release a fix in the official repo
Code:
plot = video.get('description').get('value') if video.get('description') else ''

Thank you for the post and for the plugin. Any plans for a release incorporating this?
Will try to get it released soon, been busy at work and couldnt work on the PR
Kodi 21 Windows 10 and 11 | 21 Xbox One X | 21 Linux Mint Virginia XFCE | CoreELEC NO 21 nightly S905X4 aarch64
Reply
#22
v2.1.13 released into the Matrix Kodi repo. Leia version to follow soon
Kodi 21 Windows 10 and 11 | 21 Xbox One X | 21 Linux Mint Virginia XFCE | CoreELEC NO 21 nightly S905X4 aarch64
Reply
#23
Help please.

My IMDB trailers addon hasn't been working for a few weeks now.
Openelec on a RaspberryPI. Leia 18.9. And on my PC - installed it today to test it.

This is the log from the Raspberry -

2021-09-18 14:36:43.403 T:140489429808896   ERROR: GetDirectory - Error getting plugin://plugin.video.imdb.trailers/?action=list2&key=showing
2021-09-18 14:36:43.412 T:140492072805248   ERROR: CGUIMediaWindow::GetDirectory(plugin://plugin.video.imdb.trailers/?action=list2&key=showing) failed
2021-09-18 14:41:55.702 T:140489429808896   ERROR: EXCEPTION Thrown (PythonToCppException) : -->Python callback/script returned the following error<--
                                             - NOTE: IGNORING THIS CAN LEAD TO MEMORY LEAKS!
                                            Error Type: <type 'exceptions.TypeError'>
                                            Error Contents: expected string or buffer
                                            Traceback (most recent call last):
                                              File "/home/paul/.kodi/addons/plugin.video.imdb.trailers/default.py", line 23, in <module>
                                                imdb_trailers.Main()
                                              File "/home/paul/.kodi/addons/plugin.video.imdb.trailers/resources/lib/imdb_trailers.py", line 85, in __init__
                                                self.list_contents2()
                                              File "/home/paul/.kodi/addons/plugin.video.imdb.trailers/resources/lib/imdb_trailers.py", line 211, in list_contents2
                                                mdiv = BeautifulSoup(page_data, "html.parser", parse_only=tlink)
                                              File "/home/paul/.kodi/addons/script.module.beautifulsoup4/lib/bs4/__init__.py", line 347, in __init__
                                                markup, from_encoding, exclude_encodings=exclude_encodings)):
                                              File "/home/paul/.kodi/addons/script.module.beautifulsoup4/lib/bs4/builder/_htmlparser.py", line 363, in prepare_markup
                                                exclude_encodings=exclude_encodings)
                                              File "/home/paul/.kodi/addons/script.module.beautifulsoup4/lib/bs4/dammit.py", line 447, in __init__
                                                for encoding in self.detector.encodings:
                                              File "/home/paul/.kodi/addons/script.module.beautifulsoup4/lib/bs4/dammit.py", line 305, in encodings
                                                self.markup, self.is_html)
                                              File "/home/paul/.kodi/addons/script.module.beautifulsoup4/lib/bs4/dammit.py", line 379, in find_declared_encoding
                                                declared_encoding_match = xml_re.search(markup, endpos=xml_endpos)
                                            TypeError: expected string or buffer
                                            -->End of Python script error report<--
2021-09-18 14:41:55.750 T:140492039206656   ERROR: GetDirectory - Error getting plugin://plugin.video.imdb.trailers/?action=list2&key=showing
2021-09-18 14:41:55.756 T:140492072805248   ERROR: CGUIMediaWindow::GetDirectory(plugin://plugin.video.imdb.trailers/?action=list2&key=showing) failed
Reply
#24
(2021-09-18, 14:46)paulbloggs Wrote: Help please.

My IMDB trailers addon hasn't been working for a few weeks now.
Openelec on a RaspberryPI. Leia 18.9. And on my PC - installed it today to test it.

This is the log from the Raspberry -

2021-09-18 14:36:43.403 T:140489429808896   ERROR: GetDirectory - Error getting plugin://plugin.video.imdb.trailers/?action=list2&key=showing
2021-09-18 14:36:43.412 T:140492072805248   ERROR: CGUIMediaWindow::GetDirectory(plugin://plugin.video.imdb.trailers/?action=list2&key=showing) failed
2021-09-18 14:41:55.702 T:140489429808896   ERROR: EXCEPTION Thrown (PythonToCppException) : -->Python callback/script returned the following error<--
                                             - NOTE: IGNORING THIS CAN LEAD TO MEMORY LEAKS!
                                            Error Type: <type 'exceptions.TypeError'>
                                            Error Contents: expected string or buffer
                                            Traceback (most recent call last):
                                              File "/home/paul/.kodi/addons/plugin.video.imdb.trailers/default.py", line 23, in <module>
                                                imdb_trailers.Main()
                                              File "/home/paul/.kodi/addons/plugin.video.imdb.trailers/resources/lib/imdb_trailers.py", line 85, in __init__
                                                self.list_contents2()
                                              File "/home/paul/.kodi/addons/plugin.video.imdb.trailers/resources/lib/imdb_trailers.py", line 211, in list_contents2
                                                mdiv = BeautifulSoup(page_data, "html.parser", parse_only=tlink)
                                              File "/home/paul/.kodi/addons/script.module.beautifulsoup4/lib/bs4/__init__.py", line 347, in __init__
                                                markup, from_encoding, exclude_encodings=exclude_encodings)):
                                              File "/home/paul/.kodi/addons/script.module.beautifulsoup4/lib/bs4/builder/_htmlparser.py", line 363, in prepare_markup
                                                exclude_encodings=exclude_encodings)
                                              File "/home/paul/.kodi/addons/script.module.beautifulsoup4/lib/bs4/dammit.py", line 447, in __init__
                                                for encoding in self.detector.encodings:
                                              File "/home/paul/.kodi/addons/script.module.beautifulsoup4/lib/bs4/dammit.py", line 305, in encodings
                                                self.markup, self.is_html)
                                              File "/home/paul/.kodi/addons/script.module.beautifulsoup4/lib/bs4/dammit.py", line 379, in find_declared_encoding
                                                declared_encoding_match = xml_re.search(markup, endpos=xml_endpos)
                                            TypeError: expected string or buffer
                                            -->End of Python script error report<--
2021-09-18 14:41:55.750 T:140492039206656   ERROR: GetDirectory - Error getting plugin://plugin.video.imdb.trailers/?action=list2&key=showing
2021-09-18 14:41:55.756 T:140492072805248   ERROR: CGUIMediaWindow::GetDirectory(plugin://plugin.video.imdb.trailers/?action=list2&key=showing) failed
Ooops - sorry - log from the PC!!
Reply
#25
(2021-09-18, 14:48)paulbloggs Wrote: Ooops - sorry - log from the PC!!

Yeah looks like it is broken in kodi Leia on the last release. Works fine on Matrix. Will check why it is broken on Leia
Kodi 21 Windows 10 and 11 | 21 Xbox One X | 21 Linux Mint Virginia XFCE | CoreELEC NO 21 nightly S905X4 aarch64
Reply
#26
thanks for this!
are you still planning to support Leia?
Reply
#27
haven't managed to figure out why it stopped working on Leia, will get to it eventually
Kodi 21 Windows 10 and 11 | 21 Xbox One X | 21 Linux Mint Virginia XFCE | CoreELEC NO 21 nightly S905X4 aarch64
Reply
#28
@shmizan @paulbloggs v2.1.14 with the fix for Leia submitted to XBMC git for Approval.
Kodi 21 Windows 10 and 11 | 21 Xbox One X | 21 Linux Mint Virginia XFCE | CoreELEC NO 21 nightly S905X4 aarch64
Reply
#29
Hey Gujal, maybe you can help? So I had an IMDB Trailers player working with The Movie Database Helper. Its a really useful player. It stopped working in the last couple days. The IMDB Trailers addon still works and so does the search. Maybe somebody can help get this player working again. Thanks, heres the imdbtrailers.json player code: { "name": "Watch Trailer Now", "plugin": "plugin.video.imdb.trailers", "priority": 1, "play_movie": [ "plugin://plugin.video.imdb.trailers/?action=search", { "keyboard": "{title}" }, { "title": "{title}" } ], "is_resolvable": "false" }
Reply
#30
(2021-10-18, 01:16)jdig4240 Wrote: Hey Gujal, maybe you can help? So I had an IMDB Trailers player working with The Movie Database Helper. Its a really useful player. It stopped working in the last couple days. The IMDB Trailers addon still works and so does the search. Maybe somebody can help get this player working again. Thanks, heres the imdbtrailers.json player code: { "name": "Watch Trailer Now", "plugin": "plugin.video.imdb.trailers", "priority": 1, "play_movie": [ "plugin://plugin.video.imdb.trailers/?action=search", { "keyboard": "{title}" }, { "title": "{title}" } ], "is_resolvable": "false" }
The search endpoint is now for displaying the keyboard and getting an input. It then calls another action search_word with parameter keyword
For your use case now please try with
plugin://plugin.video.imdb.trailers/?action=search_word&keyword=title
Kodi 21 Windows 10 and 11 | 21 Xbox One X | 21 Linux Mint Virginia XFCE | CoreELEC NO 21 nightly S905X4 aarch64
Reply
  • 1
  • 2(current)
  • 3
  • 4
  • 5
  • 8

Logout Mark Read Team Forum Stats Members Help
IMDb Trailers Addon1