EBUSY: resource busy or locked, unlink
code: "EPERM"errno: -4048message: "EPERM: operation not permitted, unlink 'C:\Program Files (x86)\Maxim\d3dcompiler_47.dll'"path: "C:\Program Files (x86)\Maxim\d3dcompiler_47.dll"
code: "EBUSY"errno: -4082message: "EBUSY: resource busy or locked, unlink 'C:\Program Files (x86)\Maxim\icudtl.dat'"path: "C:\Program Files (x86)\Maxim\icudtl.dat"
Not enough info to reproduce. If this is still an issue, please open a new issue with more info/context.
It is new to me that missing information for reproducing an issue (you are right on that one!) automatically justifies to close issues.
FWIW I hit this (on windows only) in my CI build, see https://github.com/copperinc/plugin-iot-rules/pull/4/checks?check_run_id=2034035750
I use copy and mkdirp during test setup, and remove during test teardown. The teardown part errors out with:
Suite error: plugin packaging function
Message:
Error: EBUSY: resource busy or locked, rmdir 'D:\a\plugin-iot-rules\plugin-iot-rules\test\tmp'
Stack:
error properties: Object({ errno: -4082, code: 'EBUSY', syscall: 'rmdir', path: 'D:\a\plugin-iot-rules\plugin-iot-rules\test\tmp' })
Error: EBUSY: resource busy or locked, rmdir 'D:\a\plugin-iot-rules\plugin-iot-rules\test\tmp'
Update: I was doing something stupid! My test setup involved creating a directory, changing into that directory (via process.chdir), then on test completion, deleting the directory, then changing out of the directory. On windows, this would cause issues (not on Ubuntu or mac OS).
I was able to fix it on windows by first changing out of the directory, then deleting it. Woopsy 😊