Issues when using String to Path node in batch mode

I have created a simple 2 step workflow which defines a variable (a directory path) and then converts same to a Path using the String to Path node. The workflow completes successfully when using the UI but fails in batch mode. This issue occurs when the ‘File system’ setting is either: ‘Local File System’, ‘Relative to’ ‘Current workflow data area’ or ‘Current Workflow’. I understand that mountpoint paths aren’t available in batch mode but cannot find anything to suggest that there are limitations when using simple paths.

Using the ‘non-variable’ variant of the node generates the same error.

Attached is the workflow and an image of the error message being generated.

TEST.knwf (7.4 KB)

Further testing has highlighted the following error message in the logs:
ERROR : main : : FileWorkflowPersistor : TEST : 0 : Unable to load node with ID suffix 166 into workflow, skipping it: null

@Iris as per our discussion:

No, this is not the exact workflow that we are trying to execute however, in an effort to understand why it was failing in batch mode, we identified the first break-point and tried various configurations in an attempt to achieve the desired outcome. The result is this very simple, 2 node workflow which successfully runs via the UI but fails in batch mode. We do not appear to have issues with other workflows however we generally don’t execute them in batch mode - we will investigate this further as I gather you are hinting at a bigger problem?

For completeness sake, the original workflow has been ‘renovated’ to remove deprecated Nodes (ie. the original workflow WAS working without issue both in batch mode & via the UI) so it is quite frustrating that we have put in the effort to migrate to the new file handling infrastructure only to discover that there appear to be some very obvious issues present.

Regards,

Michael.

Hi @mpk

we found the problem and it is related to the “relative-to” and “mountpoint” paths. Both will fail with NPEs.

The current workaround is to use the Custom URLs in the node. Can you try if this is working for your usecase as well?

Unfortunately Iris we are still getting the same error when using Custom/KNIME URL:
ERROR : main : : FileWorkflowPersistor : TEST.StringToPath : 0 : Unable to load node with ID suffix 290 into workflow, skipping it: null
java.lang.NullPointerException

Again, the same workflow executes without a problem when run via the UI.

Hi mpk,
please see the attached workflow for a working example.
Bye
Tobias
ws.knar (87.5 KB)

1 Like

Tobias,

Thank you for your example. I suspect I must be misunderstanding something however as both examples appear to simply read a CSV file (using various file handling methods) whereas the issue I have been encountering relates to the String to Path node (which fails when executed in batch mode).

Please advise if I’m not interpreting your workflow correctly.

Regards,

Michael.

@Iris have you been able to confirm if the issue extends to the use of Custom URLs also?

Can you make a screenshot of the String to Path nodes dialog?

Iris,
As requested:

@Iris, any further information on this issue?

@Iris I’m hoping to get some clear guidance on this issue and the use of the new file handling methods.

This topic was automatically closed 182 days after the last reply. New replies are no longer allowed.