debug

Diagnose NanoClaw container agent failures using logs, session databases, and mount inspection.

2|Updated Jan 14, 2026
One-click install
npx skills add https://github.com/RADHA0-max/selfhealbackend --skill debug-radha0-max
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: debug
Source: https://github.com/RADHA0-max/selfhealbackend/tree/main/nanoclaw/.claude/skills/debug
Command: npx skills add https://github.com/RADHA0-max/selfhealbackend --skill debug-radha0-max

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve? Containerized agent sessions can fail silently: messages never reach the container, replies never get delivered, or containers exit without explanation. This Skill provides a systematic debugging workflow for the NanoClaw container execution system, covering logs, session databases, mounts, and the most common failure modes. ## Core Features & Use Cases - Message Flow Tracing: Inspect inbound.db and outbound.db session databases to determine whether a message reached the container and whether the agent produced a reply. - Common Issue Playbooks: Step-by-step diagnosis for duplicate service instances causing lost deliveries, container exit and authentication failures, mount problems, and stale heartbeat detection. - Operational Commands: Ready-to-use commands for querying session DBs, restarting containers via the ncl CLI, probing the agent image with Docker, and running a quick diagnostic script. - Use Case: Your bot stops replying on Telegram. Use this Skill to discover that a duplicate NanoClaw service instance with a stale binary is racing the delivery poll and marking messages delivered without sending them, then stop the stale service. ## Quick Start Ask the agent to debug why the NanoClaw container is not replying to messages and have it check the host error log and session databases.

Frequently Asked Questions about debug

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I debug a NanoClaw container that produces no reply?

Check the session's inbound.db to confirm the message reached the container, then check outbound.db and the processing_ack table for a reply. If none exists, review logs/nanoclaw.log with LOG_LEVEL=debug for container exit codes and streamed stderr.

Why are NanoClaw messages marked delivered but never sent?

This happens when two NanoClaw service instances run simultaneously and a stale instance without channel adapters wins the delivery poll, marking messages delivered with a null platform_message_id. Stop and disable the duplicate service, then verify only one process runs.

How do I inspect NanoClaw session databases?

Use the in-tree query wrapper: pnpm exec tsx scripts/q.ts <db-path> "<SQL>" to query messages_in, messages_out, and processing_ack tables. This uses the better-sqlite3 dependency already installed, avoiding a separate sqlite3 CLI.

Why does the NanoClaw container fail with a 401 authentication error?

A 401 usually means the agent is in selective secret mode and the required secret was never assigned in the OneCLI gateway. Run onecli agents list to check secretMode, then set it to all with onecli agents set-secret-mode.

How do I restart a NanoClaw session container?

Run ncl groups restart --id <group-id> to restart all containers for an agent group. Add --rebuild to rebuild the image first, or --message to wake the container immediately with a message instead of waiting for the next user message.