Google Screwed Up?

Part of the application I spend most of my time working on is consumption and aggregation of XML feeds, and when the month of October turned, and interesting thing happened: processing a significant number of feeds suddenly started erroring.  We don't do it manually, instead using the very capable rssatom.cfc from Roger Benningfield, so the errors seemed doubly odd.

Futher investigation, however, indicated that Google News was misformatting their dates.  They seemed to be prepending a zero to months to make them two digit, without bothering to check whether the month was already two digit.  This yielded dates like this: 2006-010-03T15:40:02+00:00, which is obviously invalid.  Adding this line above like 1014 in rssatom 2.08 seems to have resolved the issue:

<cfset mydatebites.main = REReplace(mydatebites.main, "([0-9]{4}-)0([0-9]{2}-)", "\1\2", "one") />

One response to “Google Screwed Up?”

  1. jsieber

    I was shocked to see that this is still a issue with the feeds coming from blogger pages. I had to add this line to rssatom 2.08 today to be able to read in the feed. Thanks for the tip!