I had used List Folder node to list the folders in knime server location.
first I had tried the list the folder in local and it was working as expected. But when I moved the WF with list folder to the server, I am getting below error.
Path
Logs -
2021-01-14 12:11:05,544 : ERROR : main : : NodeContainerEditPart : : : The dialog pane for node 'List Folders 11:2321' has thrown a 'NullPointerException'. That is most likely an implementation error.
java.lang.NullPointerException
at org.knime.workbench.ui.wrapper.WrappedNodeDialog.open(WrappedNodeDialog.java:195)
at org.knime.workbench.editor2.editparts.NodeContainerEditPart.openNodeDialog(NodeContainerEditPart.java:925)
at org.knime.workbench.editor2.editparts.NodeContainerEditPart.openDialog(NodeContainerEditPart.java:832)
at org.knime.workbench.editor2.editparts.NodeContainerEditPart.performRequest(NodeContainerEditPart.java:396)
at org.eclipse.gef.tools.SelectEditPartTracker.performOpen(SelectEditPartTracker.java:194)
at org.eclipse.gef.tools.SelectEditPartTracker.handleDoubleClick(SelectEditPartTracker.java:137)
at org.knime.workbench.editor2.WorkflowSelectionDragEditPartsTracker.handleDoubleClick(WorkflowSelectionDragEditPartsTracker.java:126)
at org.eclipse.gef.tools.AbstractTool.mouseDoubleClick(AbstractTool.java:1069)
Path error message
The list folder node is working in local but not on the server. Please advise what need to be done.
That’s definitely a bug. It seems to work OK with the path set to knime://knime.workflow/ but not knime://knime.workflow/../ or knime://knime.workflow/../../ on the server (those paths are all fine locally). The url knime://LOCAL/ does work on the server.
The List Files node doesnt work locally with any of those paths, the File Reader node also doesnt work locally with knime://knime.workflow paths so you cant follow up there with a snippet
I’m guessing this is likely something to do with how knime:// URLs are resolved in the server environment, but I’ve no idea what. I’m going to tag @gab1one here in the hope he can throw some light on that.
The reason we completely overhauled the file handling with 4.3 is that there are a lot of issues with the old nodes, such as inconsistent behavior on AP and server like you are encountering here. I sadly can’t offer you a good solution for workflow relative resolution. You can doing mountpoint relative, like steve suggested. That does work on the server.
Thanks @gab1one - at least that means its not a bug, even if it isnt really desirable behaviour.
@mathi I guess you could use a List folders node with the path set to knime://knime.workflow/, parse the resulting absolute path in a Java Snippet, and then feed that in as a flow variable into a second List folders node. It’s ugly but seems to work.