AtlassianContribs / universal-wiki-converter

Universal Wiki Converter (UWC) is a Java tool used to convert various wikis into Confluence format. No need to fork it, ask for access!
19 stars 27 forks source link

Unexpected problem while converting: null #7

Open matt-the-bass opened 8 years ago

matt-the-bass commented 8 years ago

I have a moinmoin wiki that I'm trying to port to confluence. Using the gui on Windows7 I'm able to successfully test my server connection. I think I'm able to do an export via the command line as well. However, during the conversion stage, I get this error:

2016-05-12 15:50:32,679 INFO [Thread-4] - ::: total time to convert files: 128 seconds. 2016-05-12 15:50:32,679 ERROR [Thread-4] - Unexpected problem while converting: null java.lang.NullPointerException at com.atlassian.uwc.hierarchies.ContentHierarchy$VersionComparator.compare(ContentHierarchy.java:355) at java.util.TreeMap.compare(Unknown Source) at java.util.TreeMap.put(Unknown Source) at java.util.TreeSet.add(Unknown Source) at com.atlassian.uwc.hierarchies.HierarchyNode.addChild(HierarchyNode.java:62) at com.atlassian.uwc.hierarchies.ContentHierarchy.getPenultimateNode(ContentHierarchy.java:174) at com.atlassian.uwc.hierarchies.ContentHierarchy.buildHierarchy(ContentHierarchy.java:58) at com.atlassian.uwc.ui.ConverterEngine.convert(ConverterEngine.java:415) at com.atlassian.uwc.ui.ConverterEngine.convert(ConverterEngine.java:217) at com.atlassian.uwc.ui.UWCGuiModel.convert(UWCGuiModel.java:180) at com.atlassian.uwc.ui.listeners.ConvertListener$Worker.construct(ConvertListener.java:277) at com.atlassian.uwc.ui.SwingWorker$2.run(SwingWorker.java:110) at java.lang.Thread.run(Unknown Source) 2016-05-12 15:50:32,680 ERROR [Thread-4] - Conversion Status... NONE

Anyone have any ideas what to try next?

binarious commented 8 years ago

Any news?

binarious commented 8 years ago

Solved that problem by checking if getPage is null in here: https://github.com/AtlassianContribs/universal-wiki-converter/blob/92d98cd8403a52d690d9240500ab227cf7b0d95a/src/com/atlassian/uwc/hierarchies/ContentHierarchy.java#L354

if (nameCompare != 0 || n1.getPage() == null || n2.getPage() == null) return nameCompare;