Skip to content
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

TvHeadEnd 4.3 m3u integration error - Synology Docker #274

Open
darkeagl opened this issue Jun 15, 2020 · 7 comments
Open

TvHeadEnd 4.3 m3u integration error - Synology Docker #274

darkeagl opened this issue Jun 15, 2020 · 7 comments

Comments

@darkeagl
Copy link

telly release with the issue:
1.1.0.6

Last working telly release (if known):
never worked

Operating environment (Docker/Windows/Linux/QNAP, etc.):
Docker on a Synology 918+ with latest DSM

Description of problem:
Tvheadend is running in version 4.3~221c29b on the same Synology as Telly and the export of the m3u is working when I try it. Only telly cant work with the format. Has the format parser changed or what can I change that it can work?
I havent changed any settings in tvh as I cant see anything for the m3u export.

Contents of telly.config.toml [if you're using a version above 1.1]:

# THIS SECTION IS REQUIRED ########################################################################
[Discovery]                                    # most likely you won't need to change anything here
  Device-Auth = "telly123"                     # These settings are all related to how telly identifies
  Device-ID = 12345678                         # itself to Plex.
  Device-UUID = ""
  Device-Firmware-Name = "hdhomeruntc_atsc"
  Device-Firmware-Version = "20150826"
  Device-Friendly-Name = "telly"
  Device-Manufacturer = "Silicondust"
  Device-Model-Number = "HDTC-2US"
  SSDP = true

# Note on running multiple instances of telly
# There are three things that make up a "key" for a given Telly Virtual Tuner:
# Device-ID [required], Device-UUID [optional], and port [required]
# When you configure your additional telly instances, change:
# the Device-ID [above] AND
# the Device-UUID [above, if you're entering one] AND
# the port [below in the "Web" section]

# THIS SECTION IS REQUIRED ########################################################################
[IPTV]
  Streams = 1               # number of simultaneous streams that telly virtual tuner will provide
                            # This is often 1, but is set by your iptv provider
  Starting-Channel = 10000  # When telly assigns channel numbers it will start here
  XMLTV-Channels = true     # if true, any channel numbers specified in your M3U file will be used.
  FFMpeg = true             # if this is uncommented, streams are buffered through ffmpeg; 
                            # ffmpeg must be installed and on your $PATH
                            # if you want to use this with Docker, be sure you use the correct docker image
# if you DO NOT WANT TO USE FFMPEG leave this commented; DO NOT SET IT TO FALSE [Issue #185]
  
# THIS SECTION IS REQUIRED ########################################################################
[Log]
  Level = "info"            # Only log messages at or above the given level. [debug, info, warn, error, fatal]
  Requests = true           # Log HTTP requests made to telly

# THIS SECTION IS REQUIRED ########################################################################
[Web]
  Base-Address = "127.0.0.1:6077"   # Set this to the IP address of the machine telly runs on AS SEEN BY PLEX
                                  # telly will be telling Plex to connect to URLs at this address.
                                  # DO NOT REMOVE THE PORT
                                  # Just change the 0.0.0.0 to your IP address.
  Listen-Address = "0.0.0.0:6077" # this can stay as-is

# AT LEAST ONE SOURCE IS REQUIRED #################################################################
# COPY/PASTE THIS BLOCK TO ADD MORE SOURCES #######################################################
# THIS EXAMPLE WILL NOT WORK AS-IS ################################################################
[[Source]]
  Name = ""                 # Name is optional and is used mostly for logging purposes
  Provider = "Custom"       # DO NOT CHANGE THIS
                            # "Custom" is telly's internal identifier for this 'Provider'
                            # If you change it to "SOMETHING ELSE", telly's reaction will be
                            # "I don't recognize a provider called 'SOMETHING ELSE'."
  M3U = "http://username:[email protected]:9981/playlist/channels.m3u"  # This can be either URL or fully-qualified path.
                            # This needs to be an M3Uplus file
                            # IT CANNOT BE A STREAM ADDRESS
                            # IT CANNOT BE AN M3U THAT LINKS TO ANOTHER M3U
  EPG = ""       # This can be either URL or fully-qualified path.
  # THE FOLLOWING KEYS ARE OPTIONAL IN THEORY, REQUIRED IN PRACTICE
  Filter = "YOUR_FILTER_REGULAR_EXPRESSION"
                            # Telly is written in Go, and uses the Go regular expression system, 
                            # which is limited compared to other regular expression parsers.
  FilterKey = "group-title" # Telly applies the regular expression to the contents of this key in the M3U.
  FilterRaw = false         # FilterRaw will run your regex on the entire line instead of just specific keys.
  Sort = "group-title"      # Sort will alphabetically sort your channels by the M3U key provided
# END TELLY CONFIG  ###############################################################################

Docker run command used to run telly [if applicable]:

telly or docker log:

INFO[2020-05-29T16:08:59Z] telly is preparing to go live (version=1.1.0.6, branch=dev, revision=741108cd2100cf9f4d3a13f771d1ebe5132baae6) 
INFO[2020-05-29T16:08:59Z] Loading M3U from http://XXXXXXX:[email protected]:9981/playlist/channels.m3u 
ERRO[2020-05-29T16:08:59Z] unable to parse m3u file                      error="malformed M3U provided"
ERRO[2020-05-29T16:08:59Z] error when preparing provider                 error="malformed M3U provided"
ERRO[2020-05-29T16:08:59Z] error when processing provider                error="malformed M3U provided"
INFO[2020-05-29T16:08:59Z] telly is live and on the air!                
INFO[2020-05-29T16:08:59Z] Broadcasting from http://0.0.0.0:6077/       
INFO[2020-05-29T16:08:59Z] EPG URL: http://0.0.0.0:6077/epg.xml  

Additional information:

@chazlarson
Copy link
Contributor

Telly’s m3u parser hasn’t changed in a very long time. Can you provide a copy of the m3u?

@darkeagl
Copy link
Author

darkeagl commented Jun 15, 2020

Do you need a whole m3u or is a part enough?
channels.zip

#EXTM3U
#EXTINF:-1 logo="https://ngiss.t-online.de/iss?client=ngtv&y=48&ar=keep&src=http://programm-manager.telekom.de/media/3711d16d0e3570276ebba175620385b5f4ff18f4.png" tvg-id="1da811fa89e6bd053de68d1a5c97aadb" tvg-chno="1",Das Erste HD
http://192.168.1.2:9981/stream/channelid/2047977501?profile=pass
#EXTINF:-1 logo="https://ngiss.t-online.de/iss?client=ngtv&y=48&ar=keep&src=http://programm-manager.telekom.de/media/3711d16d0e3570276ebba175620385b5f4ff18f4.png" tvg-id="ff1b8fb817b0c70cc29d3a894ed39b43" tvg-chno="1",Das Erste SD
http://192.168.1.2:9981/stream/channelid/948902911?profile=pass
#EXTINF:-1 logo="https://ngiss.t-online.de/iss?client=ngtv&y=48&ar=keep&src=http://programm-manager.telekom.de/media/35d71e6d09f3551cb4053da8487b3028cf9339cd.png" tvg-id="bf9fc5d0601a34f31f7874acb572b075" tvg-chno="2",ZDF HD
http://192.168.1.2:9981/stream/channelid/1355128767?profile=pass
#EXTINF:-1 logo="https://ngiss.t-online.de/iss?client=ngtv&y=48&ar=keep&src=http://programm-manager.telekom.de/media/35d71e6d09f3551cb4053da8487b3028cf9339cd.png" tvg-id="8d98325827d5d74f973a904f8db28e6b" tvg-chno="2",ZDF SD
http://192.168.1.2:9981/stream/channelid/1479710861?profile=pass
#EXTINF:-1 logo="https://ngiss.t-online.de/iss?client=ngtv&y=48&ar=keep&src=http://programm-manager.telekom.de/media/677f684aabfc03b8110b90e5b4ea5b3ac3e5d578.png" tvg-id="1f37fe14ca9292ca293fd89afa3a2170" tvg-chno="3",RTL SD
http://192.168.1.2:9981/stream/channelid/352204575?profile=pass
#EXTINF:-1 logo="https://ngiss.t-online.de/iss?client=ngtv&y=48&ar=keep&src=http://programm-manager.telekom.de/media/efd5a2c8992cd87d3fcc83b5b2399d12971bf89f.png" tvg-id="be28927cf2056f1eba4e87d6d2c68f9b" tvg-chno="4",SAT.1 SD
http://192.168.1.2:9981/stream/channelid/2089953470?profile=pass
.......

@chazlarson
Copy link
Contributor

You need to define a meaningful filter or leave it out.

  # THE FOLLOWING KEYS ARE OPTIONAL IN THEORY, REQUIRED IN PRACTICE
  Filter = "YOUR_FILTER_REGULAR_EXPRESSION"
                            # Telly is written in Go, and uses the Go regular expression system, 
                            # which is limited compared to other regular expression parsers.
  FilterKey = "group-title" # Telly applies the regular expression to the contents of this key in the M3U.
  FilterRaw = false         # FilterRaw will run your regex on the entire line instead of just specific keys.
  Sort = "group-title"      # Sort will alphabetically sort your channels by the M3U key provided

That's filtering everything out of the channel list since there are no channels in your m3u where the group-title field matches "YOUR_FILTER_REGULAR_EXPRESSION".

Putting that sample m3u into a config without a filter, I see:

INFO[2020-06-15T10:12:34-05:00] Loading M3U from channels.m3u
DEBU[2020-06-15T10:12:34-05:00] These channels (45) passed the filter and successfully parsed: Das Erste HD, Das Erste SD, ZDF HD, ZDF SD, RTL SD, SAT.1 SD, ProSieben SD, VOX SD, kabel eins SD, RTLZWEI SD, KiKA HD, KiKA SD, 3sat HD, 3sat SD, n-tv SD, PHOENIX HD, PHOENIX SD, zdf_neo HD, zdf_neo SD, BR Süd HD, BR Süd SD, hr HD, hr SD, NDR SD, WDR HD, WDR SD, ARTE HD, ARTE SD, ONE HD, ONE SD, ProSieben MAXX SD, NITRO SD, RTLplus SD, SAT.1 GOLD SD, sixx SD, VOXup SD, ARD-alpha HD, ARD-alpha SD, kabel eins Doku SD, tagesschau24 HD, ZDFinfo HD, ZDFinfo SD, L-TV SD, BR Nord SD, rbb Brandenburg SD
DEBU[2020-06-15T10:12:34-05:00] These channels (0) did NOT pass the filter:
INFO[2020-06-15T10:12:34-05:00] Loaded 45 channels into the lineup from github

@chazlarson
Copy link
Contributor

@darkeagl
Copy link
Author

darkeagl commented Jun 15, 2020

I changed my config to this at the end and still the same error:

                            # IT CANNOT BE AN M3U THAT LINKS TO ANOTHER M3U
  EPG = ""       # This can be either URL or fully-qualified path.
  FilterKey = "group-title" # Telly applies the regular expression to the contents of this key in the M3U.
  FilterRaw = false         # FilterRaw will run your regex on the entire line instead of just specific keys.
  Sort = "group-title"      # Sort will alphabetically sort your channels by the M3U key provided

I left the filter out completely.

@chazlarson
Copy link
Contributor

Remove all the filter-related keys if you are not using a filter. Here's the config I used. This will include all channels in the m3u; if there are more than 420 you will receive a different error.

[[Source]]
  Name = "github"                             # Name is optional and is used mostly for logging purposes
  Provider = "Custom"                        # DO NOT CHANGE THIS
  M3U = "channels.m3u"           # This can be either URL or fully-qualified path.

@chazlarson
Copy link
Contributor

chazlarson commented Jun 15, 2020

Your second example is saying:

Filter this M3U by the tag "group-title", and sort it by "group-title".

Telly is failing to parse it at least in part because your M3u does not have a "group-title" tag to extract or sort by. It could also be due to telling it to filter and then not supplying a filter to use.

The example m3u provided is missing most of the tags that telly relies on for filtering, so it may ultimately have other problems.

https://github.com/tellytv/telly/wiki/Prerequisites%3A-IPTV-Account

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants