EPUB 2 import fails with `EROFS: read-only file system, unlink` when the watch folder isn't writable
My import mode is copy and my EPUB 2 strategy is "convert to EPUB 3 in place", but books in a read-only watch folder never appear. The log shows WARN: Failed to classify epub during folder scan; treating as regular with This is not a valid EPUB 3 publication ... Use Epub.upgrade(path) to convert., then [SCAN:manual] Failed to open epub at ...; skipping, and finally EROFS: read-only file system, unlink '/path/to/books/<book>.epub'.
Resolution: The EPUB 2 upgrade runs against the source file before the copy happens, so "convert in place" tries to rewrite the original inside your watch folder — and because Node's cp unlinks the destination first, it fails with EROFS on a read-only source and the book is skipped entirely. The classification warning during the discovery phase is harmless on its own; the EROFS line is the actual failure. Workarounds: make the watch folder writable, or pre-convert the books to EPUB 3 before they reach the watch folder, or use an EPUB 2 strategy that does not rewrite the source. This ordering (upgrade-then-copy instead of copy-then-upgrade) is a bug, and the intended behavior is that copy mode never modifies your source files — fixes moving the EPUB 2 strategy onto individual import rules have been landing, so upgrade to a current release first.