{"record":{"id":"a376e437a4b26d25","repo":"astral-sh/ruff","slug":"32601","errorCode":"-32601","errorMessage":"Unknown request: {method}","messagePattern":"Unknown request: (.+?)","errorType":"error_code","errorClass":"Error","httpStatus":null,"severity":"error","filePath":"crates/ty_server/src/server/api.rs","lineNumber":156,"sourceCode":"        ),\n        requests::CallHierarchyIncomingCallsRequestHandler::METHOD => {\n            background_request_task::<requests::CallHierarchyIncomingCallsRequestHandler>(\n                req,\n                BackgroundSchedule::Worker,\n            )\n        }\n        requests::CallHierarchyOutgoingCallsRequestHandler::METHOD => {\n            background_request_task::<requests::CallHierarchyOutgoingCallsRequestHandler>(\n                req,\n                BackgroundSchedule::Worker,\n            )\n        }\n        lsp_types::ShutdownRequest::METHOD => sync_request_task::<requests::ShutdownHandler>(req),\n\n        method => {\n            tracing::warn!(\"Received request {method} which does not have a handler\");\n            let result: Result<()> = Err(Error::new(\n                anyhow!(\"Unknown request: {method}\"),\n                server::ErrorCode::MethodNotFound,\n            ));\n            return Task::immediate(id, result);\n        }\n    }\n    .unwrap_or_else(|err| {\n        tracing::error!(\"Encountered error when routing request with ID {id}: {err}\");\n\n        Task::sync(move |session, client| {\n            if matches!(err.code, ErrorCode::InternalError) {\n                client.show_error_message(format!(\n                    \"ty failed to handle a request from the editor. {}\",\n                    session.client_name().log_guidance()\n                ));\n            }\n\n            respond_silent_error(\n                id,","sourceCodeStart":138,"sourceCodeEnd":174,"githubUrl":"https://github.com/astral-sh/ruff/blob/26f38c119cac42e4d320ba08f09224fdec74af2c/crates/ty_server/src/server/api.rs#L138-L174","documentation":"Returned by the ty server's request dispatcher when an LSP request arrives whose method is not one of the registered handlers. The server answers the client with a MethodNotFound-style error instead of crashing; unknown notifications are ignored.","triggerScenarios":"Thrown at crates/ty_server/src/server/api.rs:156 when the library encounters an invalid state.","commonSituations":"See trigger scenarios.","solutions":["Send only methods advertised in the server's capabilities","Register a handler for the method before dispatching it"],"exampleFix":null,"handlingStrategy":"try-catch","validationCode":null,"typeGuard":null,"tryCatchPattern":null,"preventionTips":[],"tags":[],"backgroundTag":null,"analyzedSha":"26f38c119cac42e4d320ba08f09224fdec74af2c","analyzedAt":"2026-09-05T10:32:37.492Z","contentChangedAt":"2026-09-05T10:32:37.492Z","schemaVersion":2},"datasetVersion":"2026-09-23T08:17:48.524Z"}