Skip to main content

Hello,
I have a situation that I cannot seem to understand.
It seems that fme.exe is locking/using a file that I try to rename in the Startup Script, although that file is not used at all in the workspace (the processing where the file gets created/saved/renamed is happening in the startup script).

The logs don’t mention this file/folder as being used at all.
i don’t have the file open in any other app, closed everything else except FME.

This is happening on windows. 

 

Logs say:

2024-05-24 11:32:20|  18.7| 18.5|INFORM|15160 fme.exe is using C:\Users\myuser\Documents\DataProject\CAFile\dtCA.xlsx

2024-05-24 11:32:20|  19.1|  0.0|ERROR |Python Exception <PermissionError>: rWinError 32] The process cannot access the file because it is being used by another process: ‘C:\Users\myuser\Documents\DataProject\CAFile\dtCA.xlsx’

 

The interesting thig is that on another machine with the exact same setup (both for python and fme) it does work without any issues. I checked the debug file for both, the output is exactly the same up to this point except the FME license key and machine details.

Later Edit:
It seems that the issue is that from inside the startup script, it cannot remove/rename the excel files. If i run this from Visual Studio or the terminal, it does work.

So now I am somehow unsure why from within FMEs Startup Scrip the rename/remove doesn’t work, and how can I fix this?

If anyone knows why I keep getting this, please advise. Thank you!

It would be helpful if you could post your script here.


Reply