Flash with nrfconnect in vs code fail due to nrfutil device version

Hello, when flashing t device using nrf connect icon, it fails to flash with following message

Error: Subprocess C:\ncs\toolchains\66cdf9b75e\nrfutil\home\bin\nrfutil-device.exe failed with unexpected exit code Some(101)
FATAL ERROR: command exited with status 1: nrfutil --json device x-execute-batch --batch-path 'C:\*****\generated_nrfutil_batch.json' --serial-number 821004437

After investigation I found the generated_nrfutil_batch.json (autogenerated) use "nrfutil_device_version": "2.15.2" while the toolchain uses the 2.19.2

If I run the flash from command line editing manually the generated_nrfutil_batch.json, the flash is successfull.

I checked this ticket but it does not give a solution.

How to set the correct nrfutil_device_version in the batch file?

Thank you

Related