I have a workflow that runs correctly when I manually open and execute it in KNIME. However, it fails to execute properly when I run it as a scheduled task using a .bat file.
It connects successfully to the db, but it doesn’t execute the google auth node.
Why isn’t the Google Authentication node re-executing correctly in batch mode? Is there a workaround to fix this?
Could you confirm if the Google Authenticator node was reset before scheduling the workflow. If it wasn’t reset, that might explain why it’s not re-executing correctly.
Thank you for replaying.
I’ve tried every possible combination - save it executed, all node restarted…
I’ve also put the -reset command in the .bat file, to force reset before executing the workflow.
It executes the whole workflow without an error, but it doesn’t write the modified data back to the google sheet, since the google auth node (from some unknown reason) doesn’t reset when run in batch mode.
Unfortunately that doesn’t help either.
I don’t have the exclamation sign anymore on the google auth node but still it doesn’t write in the google sheet file when run from batch mode.
Just to confirm, can you share the screenshot of your google authenticator node configuration window (with sensitive information blured out)? I need to check if you are using the interactive authentication or service account authentication.
@Nika_erek you should check where your credentials are being stored. Is the path a full path or a relative path? You could try and set the path via Workflow variables in the KNIME workflow.
@mlauber71 I have no problems executing the workflow in KNIME - it works!
It is not executing correctly ONLY WHEN RUN IN BATCH MODE!
the .json file is in the workflow folder on a local disk.
I don’t see how making a variable of the .json key would make a difference since the google auth node has an option to use a .json credential file just for this exact purpose?
My question is why is not the google auth node working correctly in batch mode?
I get no errors when I execute the .bat file.
It would be great if you could test it on your rig - connect a service acc and try to update a google sheet file on google disk running Knime from batch mode.
Understood. How to do that? When I use the String Configuration node and input the file path there, it doesn’t allow me to use it as a variable in the google auth node.
I would provide the path to the JSON as workflow variable (string) convert that to path and provide that to the authenticator. Also I would wire the reset node to the rest of the workflow.
No guarantee it will work though. I will see if I can set up a test workflow myself.
@mlauber71 tried it,but to no avail. I’ve also connected the reset node to all the nodes in the google chain, still nothing.
Let me know if you have more luck, but I think the devs should have a look at this.
@Nika_erek Can you please share a screenshot of the workflow, configuration of string to path node as well as how you are using the workflow variable in your batch file?
Keerthan,
I’ve already shared everything you asked in the above posts.
I’ve tried using the string to path node and it didn’t work, next I used the json reader node and made the file path to a variable that is feed to the google auth node - again not working. (see below)
I’ve looked and googled every possible workaround and it just doesn’t work!
I feel like we are running in circles.
The node just isn’t working as intended in batch mode and should be fixed on KNIME end. Is there a way to report this to anyone on the dev team other than here?
I just wanted to chime in here and say that while we can (and will!) let the developers know about this one, batch mode is legacy functionality in KNIME AP and isn’t actively supported. It’s still included for backwards compatibility reasons, and because a certain segment of our users still make use of it.
Might I suggest that there is an easier way? With a Team Plan on the KNIME Hub, you can can schedule and execute workflows directly on the Hub. While not free, it might save some frustration.