Filereader error messages now include both original exception details and file path for easier debugging
This commit is contained in:
parent
34f50f37a0
commit
942ad2818f
2 changed files with 8 additions and 2 deletions
|
|
@ -1,6 +1,10 @@
|
||||||
# Changelog
|
# Changelog
|
||||||
## [Unreleased]
|
## [Unreleased]
|
||||||
|
|
||||||
|
### Fixed
|
||||||
|
|
||||||
|
- **FileReader**: Error messages now include both original exception details and file path for easier debugging
|
||||||
|
|
||||||
## [0.15.0] - 2025-11-07
|
## [0.15.0] - 2025-11-07
|
||||||
|
|
||||||
### Added
|
### Added
|
||||||
|
|
|
||||||
|
|
@ -129,5 +129,7 @@ class FileReader:
|
||||||
return text_to_docling_document(content, name=f"{path.stem}.md")
|
return text_to_docling_document(content, name=f"{path.stem}.md")
|
||||||
except ImportError:
|
except ImportError:
|
||||||
raise
|
raise
|
||||||
except Exception:
|
except Exception as e:
|
||||||
raise ValueError(f"Failed to parse file: {path}")
|
raise ValueError(
|
||||||
|
f"Failed to parse file: {path} - {type(e).__name__}: {e}"
|
||||||
|
) from e
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue