I think the same problem happened to me yesterday.
Even if I use iCloud on Windows, which also may be responsible for that, I didn’t have this problem in more than 3 years and thousands of files. Furthermore, the problem happened exactly in the circumstances you described (editing a file and quickly closing Obsidian after).
In addition to that, it seems the problem was mentioned in the subreddit ( 1, 2, 3, 4), possibly by people not using iCloud on Windows. Problem was also already mentioned here and here in this forum.
I could try to reproduce in the sandbox vault if desired.
I hope the problem can be fixed soon, because if confirmed it’s quite critical.