Bifalgorithm post · Computer science one · Error Handling
What types of errors can occur when processing files?
What types of errors can occur when processing files? (Computer science one · Error Handling) — "When dealing with files there are many potential error conditi…
Ideas in this flowchart
- Potential errors when dealing with files
- Permission errors can prevent reading or writing files and directories.
- User-level processes typically cannot access system-level files.
- File Not Found errors occur when a program attempts to open a nonexistent file.
- When writing, a missing file may sometimes be created automatically.
- When reading, a missing file may cause a serious error.
- I/O errors can occur while processing a file after it has been found and opened.
- Formatting errors occur when a file's format is not what the application expects.
- File formats depend largely on the application that created them.
- Universal data formats include XML and JavaScript Object Notation (JSON).
- Formatting errors may be fatal, produce error codes or values, or raise catchable exceptions.