Risk of corruption #352
-
Hi, I wonder how risky is it to save tags to an audio file. Cheers, |
Beta Was this translation helpful? Give feedback.
Replies: 2 comments 14 replies
-
Lofty has seen pretty wide adoption and over the years I've only gotten a few reports of corruption. Most cases come from storing very large items in Opus, which still doesn't seem to be entirely right. The best I can offer is to try it out and see how it works on your library, most people have no issues and all writes are at least decently tested for the most basic cases. If you do encounter any issues with file corruption, just be sure to report it here. It'll very likely be one spurious file out of your entire library 😄. |
Beta Was this translation helpful? Give feedback.
-
It is always the responsibility of the application to decide into which file metadata is written back. This could either be the original file or a temporary file. It is also the responsibility of the application to decide if and how to apply post-write validation/verification before replacing the original file. Ideally, Lofty must never leave behind a corrupt file. That's the expectation. But it would be naive to assume that this won't happen (again) in the future. Lofty is still young. Nevertheless, I consider it the best in class for Rust. TagLib also suffered from file corruption bugs in the past. |
Beta Was this translation helpful? Give feedback.
Lofty has seen pretty wide adoption and over the years I've only gotten a few reports of corruption. Most cases come from storing very large items in Opus, which still doesn't seem to be entirely right. The best I can offer is to try it out and see how it works on your library, most people have no issues and all writes are at least decently tested for the most basic cases.
If you do encounter any issues with file corruption, just be sure to report it here. It'll very likely be one spurious file out of your entire library 😄.