Improve error handling for missing configuration keys