Tencent/WeKnora · error
resource not found
Error message
resource not found
What it means
Sentinel returned when a requested MCP resource (by URI) does not exist on the server. Note it is distinct from datasource.ErrResourceNotFound ('resource not found in source system') used by Notion and other connectors; match with errors.Is against the package you expect.
Source
Thrown at internal/mcp/errors.go:22
var (
// ErrUnsupportedTransport is returned when transport type is not supported
ErrUnsupportedTransport = errors.New("unsupported transport type")
// ErrNotConnected is returned when operation requires connection but client is not connected
ErrNotConnected = errors.New("client not connected")
// ErrAlreadyConnected is returned when trying to connect an already connected client
ErrAlreadyConnected = errors.New("client already connected")
// ErrInitializeFailed is returned when MCP initialize handshake fails
ErrInitializeFailed = errors.New("MCP initialize handshake failed")
// ErrToolNotFound is returned when requested tool is not found
ErrToolNotFound = errors.New("tool not found")
// ErrResourceNotFound is returned when requested resource is not found
ErrResourceNotFound = errors.New("resource not found")
// ErrInvalidResponse is returned when server response is invalid
ErrInvalidResponse = errors.New("invalid response from server")
// ErrTimeout is returned when operation times out
ErrTimeout = errors.New("operation timed out")
// ErrConnectionClosed is returned when connection is closed unexpectedly
ErrConnectionClosed = errors.New("connection closed")
)
View on GitHub (pinned to 988cbb0330)
Solutions
- List available resources (ListResources) and verify the URI
- Fix the resource URI in the caller; check scheme and path formatting
- Handle upstream 404 mapping in connectors (e.g. Notion returns datasource.ErrResourceNotFound instead)
- Refresh cached resource lists if the resource was deleted server-side
Defensive patterns
Strategy: validation
When it happens
Trigger: Thrown at internal/mcp/errors.go:22 when the library encounters an invalid state.
Common situations: See trigger scenarios.
AI-assisted analysis of Tencent/WeKnora@988cbb0330 (2026-09-02).
Data as JSON: /api/errors/f4b4060219486903.
Report an issue: GitHub.