Coder Social home page Coder Social logo

moonbase59 / azuracast_xmltv Goto Github PK

View Code? Open in Web Editor NEW
11.0 11.0 3.0 693 KB

Create rich XMLTV Tuner, EPG and RSS feeds from an AzuraCast Web Radio.

License: MIT License

Python 98.67% Makefile 1.33%
azuracast epg iptv iptv-m3u radio rss rss-feed rss-generator tv webradio xmltv xmltv-epg-data

azuracast_xmltv's People

Contributors

moonbase59 avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar

azuracast_xmltv's Issues

{playlists} returns just one playlist

In "gap_filler":

  • {playlists}* -- comma-separated list of playlist names that make up the general rotation

{playlists} returns just one playlist. "Rock und Deutsch-Rock" which is the default one. Should it not return all (public) playlists?

If two playlists have the same name, sometimes the wrong one is used

I have two playlists called Hard Rock:

Auswahl_297

The first one (weight 1) is in my General Rotation and not in any schedule, while the second (weight 3) is scheduled to play on Fridays at 18:00–20:00 hours.

Having more than one playlist with the same name is perfectly legal in AzuraCast, and can help making nice names for the EPG and RSS feed. The only culprit is that AzuraCast still doesn’t show a playlist being on schedule or not.

You would, for instance, use this if you had genre-based playlists and a general rotation made up of a weighted mixture of several playlists (I have "Classic Rock", "Folk Rock" and "Hard Rock"). If you play 24/7, and auto-generate gap filler programmes in azuracast_xmltv, you would want it to generate nice names to be used with the {playlists} variable. In my case, it would generate Classic Rock, Folk Rock & Hard Rock as a variable that I can use in the subtitle and description of a programme.

Thus the need for occasionally using duplicate playlist names. And the need for a "Scheduled" tag in the UI, please…

Anyway, if using an API key with azuracast_xmltv, I can get much more information from the API, like whether listener requests are allowed or not, and generate much nicer programme information.

The API doesn’t give me the ID of the playlist involved in a scheduled item, only its name. This "name-only lookup" occasionally leads to using the wrong playlist’s data, and, for example, not showing the "requests enabled" text.

In my case, it would occasionally find the "Hard Rock" playlist that’s in General Rotation (and doesn’t allow requests) instead of the "Hard Rock" playlist that’s on the Friday schedule (and allows requests).

TODO: Find a better way to identify and use the correct playlist for a schedule item, if more than one playlist has the same name and an API key is used (allowing me to access the playlist info, which isn’t possible without an API key).

TypeError: replace() argument 2 must be str, not None if station website empty

The replacer logic (using {variable}) produces an error when a field like Website-URL in the station is empty (JSON null) and you try to use this variable (ex: {station_website}):

TypeError: replace() argument 2 must be str, not None

It should instead return an empty string for the variable in question.

Will fix this ASAP.

Default RSS template makes Liferea 1.13.7 mess up its display

I use the default rss_feed_description template with azuracast_xmltv v0.12.2:

rss_feed_description = """<h2>{title}</h2>
<h3>{subtitle}</h3>
<p><strong>{airdate}&emsp;{airtime}</strong> ({airtime_length})&emsp;{station_name} ({category})</p>
<p>{desc}</p>"""

Now for schedule items with syndicated content (remote stream), the subtitle is empty, effectively generating a <h3></h3> in the HTML. This apparently makes the Liferea RSS feed reader (v1.13.7) choke:

Liferea_003

Interestingly enough, when I modify the template to add a blank after {subtitle}, as in

<h3>{subtitle} </h3>

everything gets displayed as it should:

Liferea_004

Other readers aren’t affected by this change, and don’t display the <h3> line even when it contains a blank. (A blank, as opposed to a non-breaking space &nbsp;, is considered whitespace and thus doesn’t get extra rendering.)

TODO: Change default RSS template to include an extra blank, just to be on the safe side.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.