Page 2 of 2

Re: Watch Folder_Wait for File Copy to complete

Posted: Thu Apr 22, 2021 6:29 am
by dklooker
Hi,

It seems to work. I adjusted the batch code a bit copy /b %1 +,, -> copy /b %1 +,, %1 because it gave an access denied error and kept on looping after file copy was finished. Now it says that an other proces is using the file. I will keep on testing this workflow and then it would be great to implement it into the folder monitor node.

Thanks for now!

Kind regards,
David

Re: Watch Folder_Wait for File Copy to complete

Posted: Thu Apr 22, 2021 11:18 am
by dklooker
Hi,

Probably a side effect of the copy /b command, but I now counted 2 times out 5 that a file I dropped in the watchfolder becomes 0 bytes in filesize. Just right after the batch files closes. FFAStrans also gives an error on the next node that no video and audio found, but this is of course a consequence the file has become 0 bytes.

Is there something I can change in the batchfile? Maybe a hold function for a few seconds?

David

Re: Watch Folder_Wait for File Copy to complete

Posted: Thu Apr 22, 2021 7:41 pm
by emcodem
Hm maybe because you added the ‰1 to the COPY /B
But it dont matter, the method is Not secure anyway. I will send a small exe that does the same as the batch but in a secure way.

Re: Watch Folder_Wait for File Copy to complete

Posted: Fri Apr 23, 2021 10:31 am
by emcodem
@dklooker
wait_for_file.au3.txt
(886 Bytes) Downloaded 438 times
OK, so here is some safe way to wait until the file is ready, it will at least not destroy any soruce file :D
Rename the downloaded file from .txt to .au3, save to FFAStrans\Processors\plugin_nodes\

Commandline processor usage like this:

Code: Select all

%comspec% /C ""%s_ffastrans_dir%\Processors\exe_manager.exe" /AutoIt3ExecuteScript "%s_ffastrans_dir%\Processors\plugin_nodes\wait_for_file.au3" "%s_source%""

Discussion about how we solve it possibly in a next version is ongoing.

Re: Watch Folder_Wait for File Copy to complete

Posted: Tue May 04, 2021 11:09 am
by dklooker
Hi,

This is working perfectly. I will implement this additional node in new workflows.

Thank you very much!
David

Re: Watch Folder_Wait for File Copy to complete

Posted: Tue Jun 20, 2023 3:24 pm
by graham728
At what stage should I introduce this commandline processor? - Just after the Monitor Node?

Re: Watch Folder_Wait for File Copy to complete

Posted: Tue Jun 20, 2023 9:01 pm
by momocampo
Hey Graham,

I think the answer should be yes. Place your wait_for_file.au3 in the FFAStrans\Processors\plugin_nodes\ folder and it should work with monitor folder then command executor node.
I think Emcodem could confirm but it sounds good.
Cheers.

Re: Watch Folder_Wait for File Copy to complete

Posted: Wed Jun 21, 2023 8:09 am
by emcodem
confirmed :D