{"record":{"id":"430cb132f6fbf68a","repo":"bevyengine/bevy","slug":"encountered-an-i-o-error-while-loading-asset-0","errorCode":null,"errorMessage":"Encountered an I/O error while loading asset: {0}","messagePattern":"Encountered an I/O error while loading asset: (.+?)","errorType":"exception","errorClass":"AssetReaderError","httpStatus":null,"severity":"error","filePath":"crates/bevy_asset/src/io/mod.rs","lineNumber":56,"sourceCode":"    task::{Context, Poll},\n};\nuse futures_io::{AsyncRead, AsyncSeek, AsyncWrite};\nuse futures_lite::Stream;\nuse std::{\n    io::SeekFrom,\n    path::{Path, PathBuf},\n};\nuse thiserror::Error;\n\n/// Errors that occur while loading assets.\n#[derive(Error, Debug, Clone)]\npub enum AssetReaderError {\n    /// Path not found.\n    #[error(\"Path not found: {}\", _0.display())]\n    NotFound(PathBuf),\n\n    /// Encountered an I/O error while loading an asset.\n    #[error(\"Encountered an I/O error while loading asset: {0}\")]\n    Io(Arc<std::io::Error>),\n\n    /// The HTTP request completed but returned an unhandled [HTTP response status code](https://developer.mozilla.org/en-US/docs/Web/HTTP/Status).\n    /// - If the request returns a 404 error, expect [`AssetReaderError::NotFound`].\n    /// - If the request fails before getting a status code (e.g. request timeout, interrupted connection, etc), expect [`AssetReaderError::Io`].\n    #[error(\"Encountered HTTP status {0:?} when loading asset\")]\n    HttpError(u16),\n}\n\nimpl PartialEq for AssetReaderError {\n    /// Equality comparison for `AssetReaderError::Io` is not full (only through `ErrorKind` of inner error)\n    #[inline]\n    fn eq(&self, other: &Self) -> bool {\n        match (self, other) {\n            (Self::NotFound(path), Self::NotFound(other_path)) => path == other_path,\n            (Self::Io(error), Self::Io(other_error)) => error.kind() == other_error.kind(),\n            (Self::HttpError(code), Self::HttpError(other_code)) => code == other_code,\n            _ => false,","sourceCodeStart":38,"sourceCodeEnd":74,"githubUrl":"https://github.com/bevyengine/bevy/blob/396ca727080776bd313bb892423b7d94e03b81b4/crates/bevy_asset/src/io/mod.rs#L38-L74","documentation":"AssetReaderError::Io: an underlying std::io::Error occurred while the asset reader was opening/reading the asset bytes (permissions, interrupted read, device error, etc.). The error is shared via Arc so it can surface in multiple loading futures.","triggerScenarios":"Thrown at crates/bevy_asset/src/io/mod.rs:56 when the library encounters an invalid state.","commonSituations":"See trigger scenarios.","solutions":["Inspect the wrapped io::Error kind/message for the filesystem cause","Fix file permissions or path accessibility for the asset root","Retry the load: transient io failures (especially on network/processed sources) often resolve on a subsequent attempt"],"exampleFix":null,"handlingStrategy":"retry","validationCode":null,"typeGuard":null,"tryCatchPattern":null,"preventionTips":[],"tags":[],"backgroundTag":null,"analyzedSha":"396ca727080776bd313bb892423b7d94e03b81b4","analyzedAt":"2026-08-20T16:12:39.808Z","contentChangedAt":"2026-08-20T16:12:39.808Z","schemaVersion":2},"datasetVersion":"2026-09-14T05:17:10.506Z"}