codecov-bash icon indicating copy to clipboard operation
codecov-bash copied to clipboard

"FIND: Parameter format not correct" with bash script

Open jfboismenu opened this issue 5 years ago • 3 comments

It seems like there something wrong with the find command when running codecov.sh on Azure Pipelines. I'm getting: FIND: Parameter format not correct.

As you can see from my Azure CI build, I'm getting this error.

I've validated that my tests do produce coverage

As you can see, I'm not doing anything special when it comes to uploading the coverage.

This isn't an issue on macOS or Linux.

jfboismenu avatar Jan 28 '20 18:01 jfboismenu

This affects my project as well, and means we currently don't have any coverage on Windows. Is uploading coverage from Windows intended to be supported?

njsmith avatar Feb 05 '20 21:02 njsmith

It looks like that error message comes from the Windows built-in C:\Windows\System32\find.exe tool, which is completely different from the Unix find utility. Some more details:

https://superuser.com/questions/1219129/unix-find-command-on-cmder-exe-in-windows

So possibly the problem is that azure pipelines changed their Windows configuration somehow and broke find?

njsmith avatar Feb 13 '20 07:02 njsmith

In our case, we had a custom runner on GitHub (using codecov-action) and as part of the setup we have cygwin installed with cygwin variables coming in last in the $PATH. Moving them to the beginning and restarting the service made it so that the unix style findexecutable is used.

Ideally, the script would auto detect the right binary to use and fail if it couldn't use it.

jromero avatar Oct 26 '20 20:10 jromero