Skip to main content

cli_io_with_path

Function cli_io_with_path 

Source
pub fn cli_io_with_path(e: CliError, path: &Path, hint: &str) -> CliError
Expand description

Re-wrap a pathless I/O failure with the offending PATH + a one-clause hint (UX-P4-8). Enriches BOTH shapes an export write can produce: a raw CliError::Io (a write/flush mid-write) AND a CliError::Store(StoreError::Io) (a mkdir_owner_only/open_owner_only under out_dir — e.g. a SUBPATH collision like out_dir/lots.csv already existing as a directory, which ?-converts through From<StoreError>). A CliError::Csv (a serialization error, not a path problem) and every other variant pass through unchanged.