<div dir="ltr">Hi,<div>I'm a bit new to rsync, and I recently learnt about the --info=progress2 flag to display complete transfer progress. However while transferring I encountered some unusually large transfer rates being displayed repeatedly. I used "rsync -av --info=progress2" to transfer a folder with several large files. Every time a new file was started , the initial transfer rate was unusually high (500~ MB/s instead of 30-40) and correspondingly showed an impossibly small ETA.</div>

<div><br></div><div>It appeared as if rsync was calculating the entire file as transferred in an instant (resulting in a very high rate displayed), followed by no change in transfer amount resulting in the speed decaying, reaching actual speed only when the file actually completes transferring. Although the file-wise transfer rates displayed after completion are correct, the current file's speed is always higher than what it should be.</div>

<div><br></div><div>A little bit of digging into the code showed that this was exactly what was happening. Can someone tell if this was the expected behaviour or this is a bug that can be fixed? I made a quick patch to try to reverse calculate the correct transfer rate based on the offsets (find patch attached), which seems to work correctly for my use-cases.</div>

<div><br></div><div>Regards</div><div>Anish</div></div>