Obtaining an image (a clone) is ok from any release. However, it is very important that the clone being restored is from the same release as you are using to restore the clone. If you used JetPack 4.2.3 to flash a clone from a different release, then this may be why it fails. Root filesystems are not entirely independent from the setup software in the other partitions.
“mksparse” cannot work on an image which is already sparse. Understand that when you clone and name a file, that two files are generated. If you name the file “backup.img”, then this plus “backup.img.raw” will be created. The “.img” is already sparse, and only the “backup.img.raw” can be used with mksparse.
However, if mksparse fails on the raw image, then something is probably wrong. One possibility is that the filesystem was somehow corrupt, e.g., it was shut down uncleanly before starting the clone. mksparse depends on the ext4 filesystem integrity. If the journal is needed to replay to correct for some previous bad shutdown, then mksparse needs this to be completed prior to conversion from raw to sparse.
We do know that the division by 1024 worked exactly, and so you know the image is not truncated. This does not say whether or not the ext4 on the image is valid.
Note that mksparse is simply what I would call “the poor man’s run length compression”. If the filesystem is nearly full, then sparse and raw approach as being the same size. I’ve never tried, but I suppose that if the filesystem is full, then this might be a problem for mksparse (though I doubt this would really be a problem).
Do realize that you can flash using the raw image so long as it is named “system.img”. In the past there was no sparse file and the flash software worked only with raw images, but the flash time was long and the sparse image began use to reduce flash time.
Also, if you can loopback mount the raw image, then you know the image is good (and you may find some indication of needing filesystem check). For example:
sudo mount -o loop ./backup.img.raw /mnt
ls /mnt
sudo umount /mnt