XMLTV import not working (Almost fixed in build 13914) (1 Viewer)

KRA

Portal Pro
July 5, 2005
145
5
48
Home Country
Norway Norway
TV-Server Version: 13831
MediaPortal Version: 13835
MediaPortal Skin: B2 wide
Windows Version: Xp sp2
CPU Type: AMD X2 3800
HDD: yes
Memory: 1 gig
Motherboard: Asus
Motherboard Chipset: ATi m200
Motherboard Bios: dunno
Video Card: ATi X1650
Video Card Driver: 7.1
Sound Card: AC97
Sound Card AC3:
Sound Card Driver:
1. TV Card: Hauppauge HVR 4000
1. TV Card Type: sw Analog/DVB-T/DVB-S/DVB-S2
1. TV Card Driver: 2.118.24324.0
2. TV Card: Pinnacle
2. TV Card Type: DVB-S
2. TV Card Driver: 3.1.3.0
3. TV Card: Terratec Cinergy 1200
3. TV Card Type: DVB-S
3. TV Card Driver: 4.8.16
4. TV Card:
4. TV Card Type:
4. TV Card Driver:
MPEG2 Video Codec: Powerdvd7
MPEG2 Audio Codec: Powerdvd7
Satelite/CableTV Provider: Canal Digital Norway
HTPC Case: na
Cooling: air
Power Supply: Hiper 500w
Remote: MCE/Logitech 525/Hauppauge
TV: LCD 1368x768
TV - HTPC Connection: DVI/VGA

It says Invalid XML file: Input string was not in a correct format.

I get the same error with a xml file from xmltv and webepg.
It imports the channels, but not guidedata
Confirmed on two different server, norwegian grabber

tvguide.xml enclosed
 

rublopez

Portal Member
August 22, 2006
9
0
Madrid (Spain)
I can confirm the problems with importing the tvguide.xml file. This issue is produced with SVN snapshots from 04-05-2007, because with snapshot 03-28-2007 this issue work fine.

I have investigated this bug and I have discover the cause into XmlTvImport plug-in. If a program has not set the "starRating" field, the XML file is not read correctly. I have found that the bug is in the following line of XMLTVImport.cs (line 570):

Program prog = new Program(channel.IdChannel, longtodate(startDate), longtodate(stopDate), title, description, category, false, DateTime.MinValue, seriesNum, episodeNum, Convert.ToInt32(starRating), clasification);

If "starRating" variable is empty, Convert.ToInt32(starRating) produces an exception and therefore the import process is interrumped. If startRating variable is set to "0" when the file does not include the "startRating" field, the file should be imported correctly.

I hope that you fix this issue.
 

scoop

Retired Team Member
  • Premium Supporter
  • November 14, 2004
    614
    7
    Hi rublopez,

    Thanks for figuring this out. TVServer builds starting from rev#13914 will fix this issue.

    Kind regards,
    Michel
     

    D4bFz3awSRYHKjr3

    MP Donator
  • Premium Supporter
  • August 14, 2006
    253
    16
    Home Country
    Aruba Aruba
    Just tested latest build (compiled by myself), it seems to be fixed when the value is nothing(no data in tvguide.xml), but when the starrating is something like "3/4" it gives the same error.

    Grabbed with JXMLTV from www.teveblad.be, they seem to always give a rating like .../4, 1/4, 2/4, 2.5/4, 4/4.


    Just letting you guys know, theres a small bug....:)
     

    KRA

    Portal Pro
    July 5, 2005
    145
    5
    48
    Home Country
    Norway Norway
    This has been fixed in build 13914, some still have problems
     

    scoop

    Retired Team Member
  • Premium Supporter
  • November 14, 2004
    614
    7
    Correct,

    The code still expects a regular number (out of five), while the xmltv spec says its "N / M". I'll leave this open for the one who implemented this feature to deal with it correctly. At least import now works when no rating is present.

    Kind regards,
    Michel
     

    Users who are viewing this thread

    Top Bottom