help about script play http stream video
#1
hello
I want to develop a kodi scritp,This is part of my code
python:

def onClick(self, controlId: int) -> None:
container_id = self.getCurrentContainerId()
li = self.getListItem(self.getCurrentListPosition())
purl = li.getProperty("purl")
xbmc.Player().play(purl, listitem=li)

When my url is 'https://cdn-xalbum2.xiaoniangao.cn/6108cd3f0000011192dfa7af?Expires=1640966400&OSSAccessKeyId=LTAI5tB7cRkYiqHcTdkVprwb&Signature=99rWcHALTCuSiSzBl3dn%2Baxptos%3D'

there has 'CCurlFile::Exists - Failed: HTTP returned error 403' ERROR
i found it request /VIDEO_TS.IFO and /index.bdmv ....

this is log:log

someone can tell why?

and how not to send such a request,

thanks!
Reply
#2
(2021-08-06, 05:33)wykkoij1 Wrote: there has 'CCurlFile::Exists - Failed: HTTP returned error 403' ERROR

Do you know the meaning of the above error? It means you are not authorized to access that (web) page.

Here is some reading material: https://www.howtogeek.com/357785/what-is...-i-fix-it/
Reply
#3
(2021-08-06, 06:50)Klojum Wrote:
(2021-08-06, 05:33)wykkoij1 Wrote: there has 'CCurlFile::Exists - Failed: HTTP returned error 403' ERROR

Do you know the meaning of the above error? It means you are not authorized to access that (web) page.

Here is some reading material: https://www.howtogeek.com/357785/what-is...-i-fix-it/
Thank you for your reply,Forgive my poor english.

yes, i know that

my question is i request url 'https://cdn-xalbum2.xiaoniangao.cn/6108cd3f0000011192dfa7af?Expires=1640966400&OSSAccessKeyId=LTAI5tB7cRkYiqHcTdkVprwb&Signature=99rWcHALTCuSiSzBl3dn%2Baxptos%3D',it‘s  normal, http code is 200 and play is ok

but see log, kodi requested many additional URLs like 
'https://cdn-xalbum2.xiaoniangao.cn/6108cd3f0000011192dfa7af/index.bdmv?Expires=1640966400&OSSAccessKeyId=LTAI5tB7cRkYiqHcTdkVprwb&Signature=99rWcHALTCuSiSzBl3dn%2Baxptos%3D'

'https://cdn-xalbum2.xiaoniangao.cn/6108cd3f0000011192dfa7af/INDEX.BDM?Expires=1640966400&OSSAccessKeyId=LTAI5tB7cRkYiqHcTdkVprwb&Signature=99rWcHALTCuSiSzBl3dn%2Baxptos%3D'

'https://cdn-xalbum2.xiaoniangao.cn/6108cd3f0000011192dfa7af/BDMV/INDEX.BDM?Expires=1640966400&OSSAccessKeyId=LTAI5tB7cRkYiqHcTdkVprwb&Signature=99rWcHALTCuSiSzBl3dn%2Baxptos%3D'

It added to my url, '/index.bdmv'、'/INDEX.BDM'、'/BDMV/INDEX.BDM'.

i want to know:

Why does it add parameters to my URL?

How can I prevent it from requesting these URLs? only request my set correct url.
Reply
#4
(2021-08-06, 07:03)wykkoij1 Wrote: It added to my url, '/index.bdmv'、'/INDEX.BDM'、'/BDMV/INDEX.BDM'.

i want to know:

Why does it add parameters to my URL?

How can I prevent it from requesting these URLs? only request my set correct url.

It's a bug in Matrix.  This is already fixed in Nexus (v20) but the backport to v19 is still waiting to be merged.  Once it is and v19.2 is released then it will be fixed in that too.  See https://github.com/xbmc/xbmc/pull/19974 for details.

Basically at the moment, either use Nexus or wait for Matrix v19.2 to be released.
Learning Linux the hard way !!
Reply
#5
Thumbs Up 
(2021-08-06, 10:30)black_eagle Wrote:
(2021-08-06, 07:03)wykkoij1 Wrote: It added to my url, '/index.bdmv'、'/INDEX.BDM'、'/BDMV/INDEX.BDM'.

i want to know:

Why does it add parameters to my URL?

How can I prevent it from requesting these URLs? only request my set correct url.

It's a bug in Matrix.  This is already fixed in Nexus (v20) but the backport to v19 is still waiting to be merged.  Once it is and v19.2 is released then it will be fixed in that too.  See https://github.com/xbmc/xbmc/pull/19974 for details.

Basically at the moment, either use Nexus or wait for Matrix v19.2 to be released.

Wow,Your information is very useful to me and helped me a lot. thank you very much

This is the first time I have developed a script on the kodi platform. The forum solves the problem very fast. Like it!
Reply

Logout Mark Read Team Forum Stats Members Help
help about script play http stream video0