-
Notifications
You must be signed in to change notification settings - Fork 64
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Methods that move/remove files on the cloud don't remove the cached version #388
Comments
Thanks for the bug report @parviste. Another workaround is to use a different caching mode that more aggressively clears the cache. I think this is a good bug, and we don't currently update the cache on any of the cloud file move/delete scenarios. It seems worth a fix here to remove files from the cache for the following methods:
|
It's probably true that the cache should be cleared after moving/removing files, but at the same time, it also doesn't feel fully correct to necessarily write the cache files using the same mode as the files written to S3. In particular, it would make sense to me to either:
I can't really see a situation where it makes sense to write the cache files using the exact mode specified for the remote file, sometimes "x" sometimes "w". |
It keeps things simpler to not have special cases for different types of writes, so I'd rather have the cache state well managed than make assumptions with the writing mode. For example, if your original example was done with We currently do the following on writing to the cloud: (1) check if file is on the remote before writing with I think the other change we want here is in |
The following code
does not work as expected. I would expect it to create a file, remove it, and then create it again. Instead, I get
This seems to happen because the file is kept in cache, even when it was removed from S3. A simple solution would probably to use the "w" mode, even when "x" was supplied.
The text was updated successfully, but these errors were encountered: