Add file existence checks and try/catch fallbacks for read errors