Yup, and not just iCloud, but all of the popular desktop cloud storage services that use a selective file sync design.
There’s been quite a bit of interesting in the same feature for Syncthing: https://forum.syncthing.net/t/selective-sync-feature-most-important/16394/
I would certainly check, but this problem happens sometimes every two months, sometimes every half a year. Is it possible to change icloud behavior ? or maybe there is some other cloud service without this problem ?
I’m not aware of an option to disable the on-demand sync behavior in iCloud. Increasing the local cache size could be used as a workaround, but it’s not really a solution because the risk is still present.
As for using another cloud storage service, it depends on what you’re using iCloud for. Is it an off-site backup for your Syncthing folder? Storage requirements?