> - continue as if the file was empty (optionally failing but I think it's overkill)
Almost.
There are two cases:
read access only:
----------------------
Proceed as if the file was empty with a warning.
read-write access:
-----------------------
Rename the existing file adding '~N' as we do for other backups and creates a new config file when required (mentioning it in the warning or in a new warning whatever works best).
I may be missing edge cases were this leads to surprising results for the user but hopefully the overall result will be better than: "I can't read one of your config files, find it or I'll refuse to work for you".
> - continue as if the file was empty (optionally failing but I think it's overkill)
Almost.
There are two cases:
read access only: ------- ------- -
-------
Proceed as if the file was empty with a warning.
read-write access: ------- ------- --
-------
Rename the existing file adding '~N' as we do for other backups and creates a new config file when required (mentioning it in the warning or in a new warning whatever works best).
I may be missing edge cases were this leads to surprising results for the user but hopefully the overall result will be better than: "I can't read one of your config files, find it or I'll refuse to work for you".