+1-888-365-2779
Try Now
More in this section

Forums / General Discussions / Feeds & Notifications - DateTime parse error when importing external feed

Feeds & Notifications - DateTime parse error when importing external feed

11 posts, 0 answered
  1. Bob Evans
    Bob Evans avatar
    19 posts
    Registered:
    22 Jun 2012
    19 Jan 2011
    Link to this post
    I'm attempting to configure an external feed import into a Sitefinity 4 (4.0.1098.0) site.  I've set up a mapping from an external RSS  to be imported into a Blog as follows:

    Content to include...
    - External RSS/Atom feed
    - URL: http://www.humansecuritygateway.com/feeds/feedsByRegionId154.xml
    - Checked 'Include all published items'

    Publish as...
    - Sitefinity content
    - Import data as 'Blogs'
    - Selected a pre-existing Blog (that contains not existing Posts)
    - Checked 'Automatically publish imported data'

    After saving and choosing to 'Run' (from the Actions menu) I receive the following error:

    Error in line 8 position 48.  An error was encountered when parsing a DateTime value in the XML.

    I am able to import other RSS feeds successfully (for instance, destructoid.com and escapistmagazine.com), but this particular RSS (whose XML appears syntactically correct) fails.  Other RSS readers are able to read this URL successfully as well -- Why is Sitefinity 4 unable to read this feed?
  2. Petya
    Petya avatar
    123 posts
    Registered:
    11 Jul 2016
    20 Jan 2011
    Link to this post
    Hi Bob ,

    Thank you for reporting this issue. The problem with the external rss you are trying to import is that the date time format in the xml is <pubDate>Thu, 20 Jan 2011 1:07:00 +0000</pubDate>. The date time of the other rss feed, for example destructoid.com is <pubDate>Mon, 17 Jan 2011 14:32:22 Z</pubDate>. The difference between the two date formats is in the UTC presentation (+0000 and Z). I logged this problem as a bug with ID 105387.

    All the best,
    Petya
    the Telerik team
    Do you want to have your say when we set our development plans? Do you want to know when a feature you care about is added or when a bug fixed? Explore the Telerik Public Issue Tracking system and vote to affect the priority of the items
  3. Bob Evans
    Bob Evans avatar
    19 posts
    Registered:
    22 Jun 2012
    14 Feb 2011
    Link to this post
    Hi Petya -- I have some additional information for you concerning this issue.  The error only occurs when the date that is being parsed is missing a leading zero for the time component (for those times before 10:00am).  For instance, the following fails to be parsed for the RSS import:

    <pubDate>Sat, 12 Feb 2011 1:12:02 +0000</pubDate>

    While the following is successfully parsed:

    <pubDate>Sat, 12 Feb 2011 01:12:02 +0000</pubDate>

    The only difference being that the second example the time is 01:12:02 rather than 1:12:02 (note the leading zero in the former).

    Hope this helps.
  4. Petya
    Petya avatar
    123 posts
    Registered:
    11 Jul 2016
    16 Feb 2011
    Link to this post
    Hello Bob,

    Thank you for the information. We will have that in mind while fixing this problem.  Here is an useful link to test the rss feeds you are trying to import http://validator.w3.org/feed/

    Kind regards,
    Petya
    the Telerik team
  5. Matt
    Matt avatar
    35 posts
    Registered:
    01 Nov 2010
    16 Nov 2012
    Link to this post
    Any progress on resolving this bug?  I'd like to display weather on my web site using this feature but no luck. 

    This feed will not parse:
    http://weather.yahooapis.com/forecastrss?w=12767389

    Thanks,
    Matt
  6. Jen Peleva
    Jen Peleva avatar
    568 posts
    Registered:
    10 Sep 2016
    22 Nov 2012
    Link to this post
    Hi Matt,

    The problems you get with that particular feed come from the fact that the feed is not valid. You can see that for yourself here:
    http://validator.w3.org/feed/ 
    We're still using the .Net fed parser (System.ServiceModel.Syndication.SyndicationFeed.Load) and it doesn't parse that feed. However, we have logged a feature request for a parser, which will parse invalid feeds as well.

    All the best,
    Jen Peleva
    the Telerik team
    Do you want to have your say in the Sitefinity development roadmap? Do you want to know when a feature you requested is added or when a bug fixed? Explore the Telerik Public Issue Tracking system and vote to affect the priority of the items
  7. Marco
    Marco avatar
    11 posts
    Registered:
    19 Mar 2015
    06 Aug 2015 in reply to Jen Peleva
    Link to this post

    Hi Jen,

     

    Any progress on this? Because the bug still exists, can you please tell us so work around for this issue on Sitefinity?

     

    Thanks,

    Marco

  8. Marco
    Marco avatar
    11 posts
    Registered:
    19 Mar 2015
    06 Aug 2015
    Link to this post
    Hi Jen,

    Any progress on this? Because the bug still exists, can you please tell us so work around for this issue on Sitefinity?

    Thanks,
    Marco
  9. Svetoslav Manchev
    Svetoslav Manchev avatar
    735 posts
    Registered:
    22 Sep 2016
    10 Aug 2015
    Link to this post
    Hello Marco,

    Would you please provide us with an example of feeds not correctly parsed?

    Is that feed validated against the mentioned below validator:
    http://validator.w3.org/feed/

    Regards,
    Svetoslav Manchev
    Telerik
     
    Do you want to have your say in the Sitefinity development roadmap? Do you want to know when a feature you requested is added or when a bug fixed? Explore the Telerik Sitefinity CMS Ideas&Feedback Portal and vote to affect the priority of the items
     
  10. Marco
    Marco avatar
    11 posts
    Registered:
    19 Mar 2015
    10 Aug 2015 in reply to Svetoslav Manchev
    Link to this post

    Hi Svetoslav,

    There are some errors on the pubDate... why doesn't Sitefinity let the feed get parsed even though?

    The below issue is being generated on my project. Is there a workaround to allow this pubDate pass or ignore the pubDate error?

    http://www.sitefinity.com/developer-network/forums/general-discussions-/feeds-amp-notifications-datetime-parse-error-when-importing-external-feed

     

    Thanks,

    Marco

  11. Svetoslav Manchev
    Svetoslav Manchev avatar
    735 posts
    Registered:
    22 Sep 2016
    11 Aug 2015
    Link to this post
    Hi Marco,

    As this is a standard .Net implementation of feeds parsing only with valid format I have logged Feature request to extend this functionality in our Feedback portal where you can vote for it.
    Note that most voted Items are developed with higher priority.

    Regards,
    Svetoslav Manchev
    Telerik
     
    Do you want to have your say in the Sitefinity development roadmap? Do you want to know when a feature you requested is added or when a bug fixed? Explore the Telerik Sitefinity CMS Ideas&Feedback Portal and vote to affect the priority of the items
     
11 posts, 0 answered