Loosing XMLTV mapping

Discussion in 'TV-Server Plugins' started by gwatkins, September 24, 2014.

  1. gwatkins

    gwatkins Portal Pro

    Joined:
    December 8, 2013
    Messages:
    81
    Likes Received:
    2
    Gender:
    Male
    Location:
    Richardson, Texas
    Ratings:
    +6 / 1
    Home Country:
    United States of America United States of America
    Show System Specs
    I would like to know when you press Save on the xmltv plugin mapping page where is the channel mapping info stored? For some reason I periodically loose some (not all) of the channel mappings and have to re-assign them. I have exported them to a file but I don't see a way to import them back. How can I back up that info and then restore it?


     
  2. Google AdSense Guest Advertisement



    to hide all adverts.
  3. mm1352000
    • Team MediaPortal

    mm1352000 Development Group

    Joined:
    September 1, 2008
    Messages:
    21,527
    Likes Received:
    4,738
    Ratings:
    +8,205 / 17
    Home Country:
    New Zealand New Zealand
    Hello

    The mapping is saved in the TV Server database.

    TV Server can't lose mappings unless some other plugin is clearing them or deleting and recreating the channels. IMHO that's very unlikely.
    I suspect that the real cause of what you're seeing is that your guide data provider is changing the channel IDs that it puts in the XMLTV file. If I'm right, there is no solution to the problem except to switch to a different data provider.

    You can't restore a mapping. I have no idea why the export function exists, but there is certainly no import/restore function. Even if there was an import/restore function it wouldn't fix the mappings if your guide data provider is changing the channel IDs as I suspect. You'd either need to switch to a different provider or continue to fix the mappings when your provider changes the channel IDs.

    mm
     
  4. gwatkins

    gwatkins Portal Pro

    Joined:
    December 8, 2013
    Messages:
    81
    Likes Received:
    2
    Gender:
    Male
    Location:
    Richardson, Texas
    Ratings:
    +6 / 1
    Home Country:
    United States of America United States of America
    Show System Specs
    The symptom that I see is that some of the channels in the guide will stop displaying shows after a certain day and time. Then when I go into the plugin and hit the Load/Refresh button those same channels show up as red, which I think means no match found. It always seems to be the same channels. I then re-assign them to the same channel map that they were before and save it and then everything is fine for a while, usually several months. I am using Microsoft as the guide provider. From what you are saying it sounds to me like the tvserver database may be getting corrupted.
     
  5. mm1352000
    • Team MediaPortal

    mm1352000 Development Group

    Joined:
    September 1, 2008
    Messages:
    21,527
    Likes Received:
    4,738
    Ratings:
    +8,205 / 17
    Home Country:
    New Zealand New Zealand
    No, that is not what I'm saying. I'll try to explain again...

    The XMLTV files that you import contain guide data for a bunch of channels. Each of those channels has a unique identifier (AKA an ID) which is used to link each of the programs for the channel. For example, your XMLTV file might contain something like this (simplified!):

    <channel id="1234">
    <display-name>NBC</display-name>
    </channel>
    <programme start="20140925063000 +1200" stop="20140925073000 +1200" channel="1234">
    <title>NBC Show 1</title>
    <desc>Description of NBC show 1.</desc>
    </programme>
    <programme start="20140925073000 +1200" stop="20140925080000 +1200" channel="1234">
    <title>NBC Show 2</title>
    <desc>Description of NBC show 2.</desc>
    </programme>
    <channel id="1235">
    <display-name>CBS</display-name>
    </channel>
    <programme start="20140925063000 +1200" stop="20140925073000 +1200" channel="1235">
    <title>CBS Show 1</title>
    <desc>Description of CBS show 1.</desc>
    </programme>
    <programme start="20140925073000 +1200" stop="20140925080000 +1200" channel="1235">
    <title>CBS Show 2</title>
    <desc>Description of CBS show 2.</desc>
    </programme>

    Do you see how the channel ID on the programme is used to indicate which channel the program is linked to?

    When you save a mapping, TV Server stores the XMLTV channel IDs against the channels in the TV Server database. So for example, we'd save 1234 with your TV Server NBC channel and 1235 with your TV Server CBS channel.

    When a new XMLTV file becomes available for import, we compare the the channel ID for each program in the file against the mapped XMLTV channel ID for each of your TV Server channels. If we find a match, then we store the program details with our guide data; if we don't find a match then the program is ignored (not imported).

    Now, what I'm saying is happening is that the channel IDs that mc2xml (???) is putting into the XMLTV files are changing. For example, maybe the NBC ID changes from 1234 to 2345. What does that do? Well, it effectively breaks the saved mapping. In other words, when TV Server tries to import that XMLTV file it looks at the saved ID for NBC (which is 1234) and sees it doesn't match any of the NBC programs in the XMLTV file (which are linked to channel 2345), and so none of those programs are imported.

    This is not a TV Server error or mistake. TV Server is not deleting or corrupting anything. It is Microsoft/mc2xml that changes their ID, and that is what is breaking the mappings. There's nothing that TV Server can do to force Microsoft to keep using the same IDs, and unfortunately we're also unable to automatically match the new IDs with the old ones. So, if you want to keep getting your data from Microsoft then you're going to have to live with this problem.

    Regards,
    mm
     
  6. gwatkins

    gwatkins Portal Pro

    Joined:
    December 8, 2013
    Messages:
    81
    Likes Received:
    2
    Gender:
    Male
    Location:
    Richardson, Texas
    Ratings:
    +6 / 1
    Home Country:
    United States of America United States of America
    Show System Specs
    I guess I understand what you are saying but it sure seems strange that Microsoft would randomly change the ID's. I used to use MCE for live tv and never had a problem with the guide and I assume it uses the Microsoft info as well. Do you have any recommendations for a better provider?
     
  7. mm1352000
    • Team MediaPortal

    mm1352000 Development Group

    Joined:
    September 1, 2008
    Messages:
    21,527
    Likes Received:
    4,738
    Ratings:
    +8,205 / 17
    Home Country:
    New Zealand New Zealand
    Sure, I understand... but I'm aware you're not the first person to report this, and MediaPortal is not the only software that is affected. For example:
    http://forums.gbpvr.com/showthread.php?55741-Changing-Channel-Mapping-Ids-Causing-Blank-Guide

    Yes, but MCE doesn't export to XMLTV before importing. In other words, this problem only affects people that use the MS data outside WMC.

    Your options:
    https://forum.team-mediaportal.com/threads/setup-help.124506/#post-1061869
     
Loading...

Users Viewing Thread (Users: 0, Guests: 0)

  1. This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
    By continuing to use this site, you are consenting to our use of cookies.
    Dismiss Notice
  • About The Project

    The vision of the MediaPortal project is to create a free open source media centre application, which supports all advanced media centre functions, and is accessible to all Windows users.

    In reaching this goal we are working every day to make sure our software is one of the best.

             

  • Support MediaPortal!

    The team works very hard to make sure the community is running the best HTPC-software. We give away MediaPortal for free but hosting and software is not for us.

    Care to support our work with a few bucks? We'd really appreciate it!