Break on ParseWXR


I have had the unfortunate experience of no being able to use this tool at all. It seems that any xml file I try to use small, large, short name, long name, anything will not convert and results in a broken process.

I run this command > WPBlogML.exe wordpress.xml

It runs for a split second into the parsing WXR file stage 1 then we get
[1/3] Parsing WXR file...

Unhandled Exception: System.NullReferenceException: Object reference not set to an instance of an object.
at WPBlogML.BlogML.Blog..ctor(XElement rssChannel)
at WPBlogML.WXRParser.ParseWXR(String wxr)
at WPBlogML.MainClass.ParseWXR(String wxr)
at WPBlogML.MainClass.Main(String[] args)
Run on Windows Server 2008 x64 in cmd.exe

How do we get this to work? Thanks


danielsummers wrote Mar 9, 2013 at 3:15 AM

Let me take a look at that. Is this generated from the latest WordPress (3.5.1, I believe)?

stephenway wrote Mar 9, 2013 at 3:54 AM

Yes latest Wordpress, you might want to talk to Baldwin at SunBlogNuke, he hacked a working build for this last week for me.

danielsummers wrote Mar 9, 2013 at 4:30 AM

I found the problem (well, at least the NPE problem). I'm working a few other things; I wrote this before C# was my main language, and I can tell from looking at it! However, I was able to successfully parse an export from my personal blog. I'll see if I can get in touch with that person and see if what they found is what I found, or if there's still something I'm missing. Version 0.7, which I'll zip up and add as a new release, will support versions 1.0, 1.1, and 1.2 of WXR.

My apologies for not replying sooner; I assumed that CodePlex would notify me when new issues were put in. I'm guessing I have to enable it somewhere.

danielsummers wrote Mar 9, 2013 at 11:08 PM

Version 0.7 has been released, which handles the missing excerpt correctly.