Regarding writes to the media, according to spiffs docs[1], with SPIFFS_CACHE and SPIFFS_CACHE_WR enabled as in our build, writes may be cached and performed when the file is closed.
[1] https://github.com/pellepl/spiffs/wiki/Using-spiffs#do-i-need-to-check-result-after-spiffs_close