Problem while running Download_Leave script

Here is the error log I get while executing script.
I am using Mender Client 2.3 for raspberry pi.

{“level”:“error”,“message”:“transient error: error executing leave script for update-after-store state: error running leave state script(s) for Download_Leave state: statescript: The version read from the version file in the statescript irectory does not match the versions supported by the client, please make sure the file is present and formatted correctly (supported: [2 3]; actual: 0).”,“timestamp”:“2020-09-24T16:51:13+01:00”}

I don’t understand that version thing that the log is telling. Can anyone help ?
And, basically I am having problem running any rootfs script. I am using update module to do single file update here.

Thanks in advance.

There is a file that is normally created by Yocto or mender-convert in /etc/mender/scripts/version that contains the version number of state scripts supported. You can see how it’s created with mender-convert here.

You need to ensure that file exists with whatever mechanism you use to generate your build.