{"record":{"id":"f8ded804dd99df9e","repo":"sxyazi/yazi","slug":"channel-closed","errorCode":null,"errorMessage":"channel closed","messagePattern":"channel closed","errorType":"exception","errorClass":"anyhow::Error","httpStatus":null,"severity":"error","filePath":"yazi-proxy/src/tasks.rs","lineNumber":15,"sourceCode":"use anyhow::{Result, anyhow};\nuse tokio::sync::mpsc;\nuse yazi_core::tasks::TaskOpt;\nuse yazi_macro::{emit, relay};\nuse yazi_scheduler::{TaskHandle, custom::CustomOut, process::ShellOpt};\nuse yazi_shared::id::Id;\n\npub struct TasksProxy;\n\nimpl TasksProxy {\n\tpub async fn spawn(opt: TaskOpt) -> Result<TaskHandle> {\n\t\tlet (tx, mut rx) = mpsc::unbounded_channel();\n\t\temit!(Call(relay!(tasks:spawn).with_any(\"opt\", opt).with_replier(tx)));\n\n\t\trx.recv().await.ok_or_else(|| anyhow!(\"channel closed\"))??.into_any2()\n\t}\n\n\tpub fn output(id: Id, out: CustomOut) {\n\t\temit!(Call(relay!(tasks:output).with(\"id\", id).with_any(\"out\", out)));\n\t}\n\n\tpub fn process_open(opt: ShellOpt) {\n\t\temit!(Call(relay!(tasks:process_open).with_any(\"opt\", opt)));\n\t}\n\n\tpub async fn process_exec(opt: ShellOpt) {\n\t\tlet (tx, mut rx) = mpsc::unbounded_channel();\n\t\temit!(Call(relay!(tasks:process_open).with_any(\"opt\", opt).with_replier(tx)));\n\t\trx.recv().await;\n\t}\n}\n","sourceCodeStart":1,"sourceCodeEnd":32,"githubUrl":"https://github.com/sxyazi/yazi/blob/94abcfa92f4ad3f0a1aef6c1ea083cfb8aa6c8c2/yazi-proxy/src/tasks.rs#L1-L32","documentation":"Error \"channel closed\" thrown in sxyazi/yazi.","triggerScenarios":"Thrown at yazi-proxy/src/tasks.rs:15 when the library encounters an invalid state.","commonSituations":"See trigger scenarios.","solutions":[],"exampleFix":null,"handlingStrategy":null,"validationCode":null,"typeGuard":null,"tryCatchPattern":null,"preventionTips":[],"tags":[],"backgroundTag":null,"analyzedSha":"94abcfa92f4ad3f0a1aef6c1ea083cfb8aa6c8c2","analyzedAt":"2026-08-16T09:56:24.836Z","schemaVersion":2},"datasetVersion":"2026-08-16T13:17:31.715Z"}