# воспроизведение из плагина локального файла mpegts

**URL:** <https://forums.plex.tv/t/mpegts/48894>\
**Category:** Русский - Russian\
**Created:** [December 6, 2013, 12:58pm UTC](https://forums.plex.tv/t/mpegts/48894 "2013-12-06T12:58:56Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![maxefa](https://avatars.discourse-cdn.com/v4/letter/m/c67d28/32.png) [@maxefa](https://forums.plex.tv/u/maxefa)\
**Post date:** [December 6, 2013, 12:58pm UTC](https://forums.plex.tv/t/mpegts/48894/1 "2013-12-06T12:58:56Z")

</div>

Пытаюсь из плагина воспроизвести локальный файл mpegts

```
def CreateVideoClipObject(url, title, thumb, container = False):
        vco = VideoClipObject(
                key = Callback(CreateVideoClipObject, url = url, title = title, thumb = thumb, container = True),
                rating_key = url,
                title = title,
                thumb = thumb,
                summary = "Firts test",
                items = [
                        MediaObject(
                                container = 'mpegts', # MP4, MKV, MOV, AVI
                                video_codec = VideoCodec.H264, # H264
                                audio_codec = AudioCodec.MP3, # ACC, MP3
                                audio_channels = 2, # 2, 6
                                optimized_for_streaming = True,
                                parts = [PartObject(key = Callback(PlayVideo, path='/storage/video/20131205113648.ts'))]# HTTPLiveStreamURL(Callback(PlayStream, url=url)))],
                        )
                ]
        )
        if container:
                return ObjectContainer(objects = [vco])
        else:
                return vco

def PlayVideo(path):  
return Redirect(Stream.LocalFile(path))
```

Получаю кучу ошибок&nbsp;

```
Dec 06, 2013 15:55:25 [0x7ff02ffff700] DEBUG - Request: GET /:/stream/38e2959e-6d9e-4dfc-ac8f-970f7293cc59.ts [172.16.1.5:37882] (5 live)
Dec 06, 2013 15:55:25 [0x7ff02ffff700] DEBUG - [com.plexapp.system] Sending command over HTTP (GET): /:/stream/token/38e2959e-6d9e-4dfc-ac8f-970f7293cc59.ts
Dec 06, 2013 15:55:25 [0x7ff02ffff700] DEBUG - HTTP requesting to: http://127.0.0.1:42850/:/stream/token/38e2959e-6d9e-4dfc-ac8f-970f7293cc59.ts
Dec 06, 2013 15:55:25 [0x7ff02ffff700] DEBUG - [com.plexapp.system] HTTP reply status 404, with 0 bytes of content.
Dec 06, 2013 15:55:25 [0x7ff02ffff700] ERROR - Error parsing content.
Dec 06, 2013 15:55:25 [0x7ff02ffff700] ERROR - Error parsing response from stream token request for token 38e2959e-6d9e-4dfc-ac8f-970f7293cc59.ts
Dec 06, 2013 15:55:25 [0x7ff02e7fc700] ERROR - [Transcoder] http://127.0.0.1:32400/video/acestreamclient/:/function/PlayVideo?function_args=Y2VyZWFsMQoxCmRpY3QKMQpzMzIKL3N0b3JhZ2UvdmlkZW8vMjAxMzEyMDUxMTM2NDgudHNzNApwYXRocjAK&X-Plex-Token=BkNmfiDp9gP2y3n1Ky1z: Invalid data found when processing input
Dec 06, 2013 15:55:26 [0x7ff02effd700] ERROR - Failed to start session successfully.
```

Может кто где ошибся?

---

<div class="post-metadata">

**Author:** ![system](https://global.discourse-cdn.com/plex/original/3X/2/a/2acb9765406f63293d357b4ec509ec39aa28f2ad.png) [@system](https://forums.plex.tv/u/system)\
**Post date:** [December 21, 2019, 12:36am UTC](https://forums.plex.tv/t/mpegts/48894/2 "2019-12-21T00:36:06Z")

</div>

Closed on December 21, 2019, 12:36am UTC

This topic was automatically closed 90 days after the last reply. New replies are no longer allowed.
