astrilchuk / sd2xmltv

A Schedules Direct to xmltv converter
MIT License
16 stars 8 forks source link

Is it possible to customize the channels that are downloaded? #16

Closed bingh0 closed 7 years ago

bingh0 commented 8 years ago

Hi, xmltv allows a custom channel lineup to reduce the download overhead. Is it possible to support this as well in sd2xmltv? One intriguing possibility is found in the MythTV wiki entry for xmltv.

https://www.mythtv.org/wiki/XMLTV#Channel_selection_shortcut_2

astrilchuk commented 8 years ago

That's an interesting approach to filtering channels. I have code in the app that does something similar but never completed it to my satisfaction. I'll take a second look. Fyi, if you are using an hdhomerun device, there is a command line option to enable channel filtering.

edit4ever commented 7 years ago

Another alternative is to take alook at how this script handles it (at least for the kodi interface)

https://github.com/primaeval/script.schedules.direct

I think combining these two scripts would make a very powerful addon!

edit4ever commented 7 years ago

Is it possible to just create a channel list file (simple text list) that could be read by your filter code instead of pulling from hdhomerun? I'm looking to build a channel filter that is accesible from within kodi, but I'll need a place to output the list and have it be read in by your filter code.

-- ignore that - I just realized that you already did this in the develop code. nice!

astrilchuk commented 7 years ago

Implemented channel filtering in commit d50c9c75.

edit4ever commented 7 years ago

Seems to be an issue with large lineups. Someone in zipcode 22124 is trying to download the verizon lineup data - they only need about 70 channels but the lineup has hundreds. It's causing a server timeout (killed message) even when using the channel filter function. Does the current setup still try to download all channels but filter at the point of adding to the database or when writing the xmltv file?

BTW - thank you for the heads up on your development plans. I'm happy to work on the kodi option implementation that I'm planning and will pr to you when complete.

astrilchuk commented 7 years ago

With regards to the server timeout - please create a new issue with all relevant details and I will try to replicate.

With regards to your possible PR - unfortunately I will likely not merge your changes. Please understand that sd2xmltv was never intended to be a Kodi plug-in. It was meant to run only as a service for tvheadend. If I incorporate your Kodi changes, then the onus is placed on me to fix bugs and support all future revisions of Kodi. This is in addition to supporting changes to tvheadend and SchedulesDirect. All for a feature I will never use.

If having a Kodi interface is important to you, then develop it on your own fork. Merge any changes I make into your fork. Point users to your fork if they want to have Kodi integration. You have my blessing to do as you wish with the code on your own fork.

I hope that make sense.

edit4ever commented 7 years ago

Thank you for your info on kodi and your sd2xmltv plans. I'm happy to keep going on my own path.

As for the server timeout - I ran some testing and confirmed that the channel filter is working as intended, so I believe there is another issue for the user. Thank you again!