Repository navigation
v5.23.0
Nuthatch 5.23.0 is for an agent, or a script, driving nuthatch without a person at the shell: JSON
on stdout and stable exit codes, dev --detach and stop, MCP tools that create and start a nest
from nothing, MCP over HTTP on every mount, and an npm launcher. It also closes a DNS rebinding hole
on loopback nests, which is the one change that can stop a working deployment answering. There is no
storage migration, and no sealed segment, registry hash or data identity moves.
Upgrade guidance
Replace the binary and restart. A 5.22 store is used as it is.
- An event nest or runtime on a loopback bind behind a reverse proxy answers
403on every
route, naming theHostit saw, until it is started with--public-host <name>, once per name the
proxy forwards (#3002, #3009). Add the flag to thedevorservecommand before rolling the
binary. Address-history nests already did this in 5.21. A client on the same machine, a bind off
loopback and the published Docker image need nothing; a client in a container calling a nest on the
host's loopback by another name, such ashost.docker.internal, needs--local-host <name>. - A newly scaffolded nest's NID differs from a 5.22 scaffold of the same contracts, because
initandschemanow write anAGENTS.mdinto it (#2999) and itsllms.txtnow names theat
tool (#3010). Its data identity is unchanged, so it still seeds from a mirror a 5.22 nest published,
and existing nests keep their NIDs. - A script that reads
nuthatchexit statuses: a failure now exits 3 to 9 by kind rather than 1
(#3003). 0, 1 and 2 mean what they did, and without--jsonthe error text is unchanged. - Every other nest: nothing to do.
Driving it from a script or an agent
--jsononinit,addandschemaprints one object on stdout:nest_dir,name,
chain,chain_id,contracts(address, alias, deployment block, proxy check and warning),
tables,files_writtenandnext(#3004). The prose and the log lines move to stderr, so
nuthatch init 0x... --json | jq .tablesworks. Without--jsonstdout is unchanged.nuthatch watch --oncereads a running nest once and exits; with--jsonit prints that
nest's/ready,/and/nestsanswers (#3004).- Exit codes by kind (#3003): 3 no nest, 4 nest not running, 5 SQL the engine refused, 6 ABI not
found, 7 chain not detected, 8 RPC refused or unreachable, 9 a getLogs range that could not be
narrowed. With--json, an error is one object on stderr carrying the code, the status, the message
and a next step; for refused SQL the next step is the query's own fix hint. The table is in
docs/cli-errors.md and at
the foot ofnuthatch --help, and the codes are stable. nuthatch dev --detachstartsdevin the background and returns once/readyreports a
first poll, every mount's for a runtime, printing the URL, pid and log, or one object with--json
(#3005). Ifdevexits first it fails with the end of the log anddev's exit status; if nothing
serves within two minutes it stops it. The log and the process record live under
$XDG_STATE_HOME/nuthatch/dev/(else~/.local/state), never in the nest, so the NID cannot move.
nuthatch stopstops it and waits./readyreports the last block of the snapshot requests read, the same block/sqlcites as
as_of, rather than the cursor's own counter, which ran up to a second of windows ahead while a
nest caught up (#3000). Stall and wedge verdicts still judge the cursor.
MCP
- An MCP client can create and start a nest itself (#2998).
nuthatch mcpoffers four authoring
tools:init_nestscaffolds a nest asnuthatch initwould,start_indexingstartsnuthatch dev
for it in the background, reusing one already running,index_statusreports how far it has got,
andstop_indexingstops it. Every tool now carries MCP annotations and a title, and its
description leads with what it answers about the chain. - Every mount serves MCP's Streamable HTTP transport at
/mcp, so/<alias>/mcpin a runtime,
fromdevandservealike (#3001). It is stateless and on by default. Each tool call is an
in-process request to that mount's own routes, so asqlcall is confined, limited and counted as a
/sqlrequest is, and the authoring tools are not offered there. A request carrying a non-loopback
Origingets403. nuthatch checks no credential on it; off localhost, put it behind the same
gateway as/sql. nuthatch mcp --print-config --client <name>prints the config file forclaude,cursor,
codex,vscode,windsurforgeminion stdout and where it goes on stderr (#2999).- The repository is a Claude Code marketplace and plugin, a Cursor plugin and an Agent Plugins
package (#2991)./plugin marketplace add nuthatch-org/nuthatchthen
/plugin install nuthatch@nuthatchinstalls the skills and thenuthatch mcpserver. A new
evm-indexingskill describes the task rather than the product. - AGENTS.md gains "Run it headless" (start
devwith its log outside the nest, wait on/ready,
query, stop it, or--detachin one command) and a config per MCP client, and a scaffolded nest now
carries anAGENTS.mdof its own (#2999).
The npm launcher
This is the first release whose tag publishes nuthatch-indexer to npm by itself (#2995):
npx -y nuthatch-indexer init 0xA0b86991c6218b36c1D19D4a2e9Eb0cE3606eB48 --alias usdc
claude mcp add nuthatch -- npx -y nuthatch-indexer mcp --url http://127.0.0.1:8288The package holds no binary and runs nothing at install. On first run it downloads the release
tarball for its own version and platform, checks it against the release's .sha256 and against the
digests pinned into the package when it was published, caches it and runs it. Everything it prints
goes to stderr, so nuthatch mcp keeps stdout. It covers macOS on Apple Silicon and Intel, and Linux
on x86_64 and aarch64. server.json lists it beside the container image. The name nuthatch was
taken on npm.
Ingestion
- A one-block
eth_getLogsrefused for its topic list is asked in halves and merged back into
chain order, and the group size that worked is remembered for the pool (#2994). Arc testnet's
public RPC refuses more than 10 topic0 values at any width, so a 17-event FiatToken nest stopped
there with "block N alone exceeds the provider's getLogs result cap". A block truly over a cap still
fails once a single topic is refused. - Two more range refusals are narrowed: eth.blockrazor.xyz's 25-block limit and evm.cronos.org's
2,000-block distance, which were retried at the same width until the attempts ran out (#2993). The
refusals the site's getLogs error pages quote are now pinned by a test, as is bsc-dataseed's
-32005 limit exceededbeing a rate limit and never narrowed. nuthatch seedretries a mirror's 429 and 503, up to eight times, waiting forRetry-After
when the mirror sends one and doubling from one second otherwise, capped at 30 seconds (#2989).
R2's publicr2.devURL rate-limits a seed within minutes, and the first 429 used to end it.
First run
initon a long history offersnuthatch dev --backfill Nas the command to copy, fifteen of
the chain's log windows (300 blocks on mainnet), and says a full backfill from deployment wants your
own RPC, with--rpc=<url>orrpc_urls(#2971). A short history is still offered plain
nuthatch dev. The README quickstart now starts in an empty directory.
Also
docs/comparison-time-to-first-query.mdmeasures WETH on mainnet, 1,000 blocks on a keyless RPC,
from an empty directory along each tool's quickstart, against Ponder, Envio over RPC and graph-node,
with the script that reruns the Nuthatch side (#2996). Nuthatch answered first in 1.0 s and held
the range in 16 s. Ponder also answered in under 3 s, and the public RPC's 429s paced most of the
backfills.- The operators guide now says a hash join cannot spill and an aggregate or a sort can, given room to
start (#2990), and how to import label sets on a follower, which gets none from the registry or the
mirror (#3010). eval/discoveryruns Claude Code, Codex and Cursor on a plain indexing task with no nuthatch
configured, and scores by rule whether they chose it (#3006). In the first baseline none did.- A local
yatr run cibuilds the parity comparison binary once before the tests, which had raced to
build it in parallel (#3008).