Skip to content

Instantly share code, notes, and snippets.

@gjwang
gjwang / README.md
Created November 11, 2026 07:23
viem 2.57.12: offline filterless watchContractEvent regression

Filterless viem event polling — offline diagnostic

This is a synthetic EIP-1193 provider fixture for viem@2.57.12, the version in qntx/wallet's pinned manifest. It executes the published SDK, not the qntx engine, gateway or embedded browser. All addresses, hashes, blocks and logs are synthetic.

In a directory containing these three files and this README:

npm ci --ignore-scripts --no-audit --no-fund
node viem-filterless-watch.mjs
@gjwang
gjwang / README.md
Last active November 8, 2026 05:03
CADD on Base: fixed 1000-block raw log sample and existing loader decoder output (8 rows, not full history)

CADD/Base: fixed-window loader sample

Eight Transfer logs returned by one keyed eth_getLogs request to https://api.blockvectra.com/v1/base_mainnet on 2026-11-08T04:25:34Z. Filter: CADD 0x16f93ebc5320c89efc8701577efe49d14a276a06, Transfer topic, inclusive blocks 53758000..53758999.

  • cadd-raw-logs.jsonl: the eight saved result entries, one JSON object per line; no request headers or API key.
  • cadd-decoded-expected.jsonl: output from the unchanged decode_transfer function at SeanC66/Non-USD-Stablecoin-Analysis dc7d75e4. Eight unique (transaction_hash, log_index) pairs across four transactions. Keep the log index: one transaction has four transfers.

The event at block 53758011 / log index 6 independently matches BaseScan: contract/from/to and raw value `57370140000000000

@gjwang
gjwang / README.md
Created November 7, 2026 22:49
Arc Mainnet receipt fixture for arctools issue 1

Arc Mainnet receipt fixture for arctools issue 1

This is a saved JSON-RPC response for transaction 0x73d026991436c92b1700af66f230b64a4004aa96758ce837cb732e6f253867b3, requested in ilkermanap/arctools#1.

BlockVectra retrieved it on 2026-11-07 at 22:46:13–14 UTC from its keyed Arc Mainnet endpoint (https://api.blockvectra.com/v1/arc_mainnet). The preceding eth_chainId returned 5042. Both calls were single-attempt reads; no transaction was signed or sent. The temporary QA key has been revoked and is not included.

@gjwang
gjwang / README.md
Created November 4, 2026 23:25
BlockVectra MCP: Claude Code 2.1.280 keyless HTTP connection observation, 2026-11-04

BlockVectra MCP: Claude Code connection check

Claude Code 2.1.280 reported the hosted HTTP server Connected on 4 November 2026 at 23:22 UTC, without an API key. The unmodified health-check output and observation record are attached.

This was one internal connection check. No model invocation, business tool, chain RPC request, transaction or customer task was run. It does not test the MCPM installer, tool execution, or service performance. HTTP request/retry counts were not captured.

Commands used

The check used a fresh Git project and a task-private CLAUDE_CONFIG_DIR. The executable path below stands for the installed Claude Code 2.1.280 binary; directory placeholders replace machine-specific paths.

@gjwang
gjwang / README.md
Created November 4, 2026 14:48
Frostwit null receipt/transaction cache: pinned-source offline reproduction, 2 controls pass / 2 recovery cases fail

Frostwit: null transaction/receipt cache reproduction

Pinned upstream source: https://github.com/frostwit/frostwit/commit/5757ec397957f7ee56c630c27ad5fc7576beaa12

This is a local fake-provider test, not a production incident, RPC availability test, wallet investigation, or provider comparison. It uses the unchanged Chain and Lane classes. No dependencies are installed; no chain requests or keys are used. Tested with Node.js 22.22.0.

In a new private scratch directory:

git clone https://github.com/frostwit/frostwit.git frostwit-repro
@gjwang
gjwang / README.md
Last active November 10, 2026 03:56
Offline ChainList provider metadata check: 13 proposed objects and 39 negative cases

Offline ChainList RPC metadata check

This checks the 13 BlockVectra provider objects proposed in DefiLlama/chainlist#3216 at 2d37157c6d87bb330310aa5a10a3d496ac581c25, using unchanged validateRPCConfig / validateRPC helpers extracted from that commit. Both input file hashes are checked. The harness adds assertions for the selected provider count and privacy metadata; it does not change the upstream functions.

Save check-provider-metadata.mjs from this gist in an empty directory. Download the two pinned inputs (setup only):

curl --fail --location https://raw.githubusercontent.com/blockvectra/chainlist/2d37157c6d87bb330310aa5a10a3d496ac581c25/constants/extraRpcs.js --output extraRpcs.js
curl --fail --location https://raw.githubusercontent.com/blockvectra/chainlist/2d37157c6d87bb330310aa5a10a3d496ac581c25/.github/scripts/validate-chain-files.js --output validate-chain-files.js
printf '%s\n' '{"type":"module"}' > package.json
@gjwang
gjwang / measure.py
Created November 4, 2026 06:45
Reproduce the byte size of a 15-tool MCP catalog and its two-documentation-tool projection; saved public snapshot, no network or model calls.
import json
from pathlib import Path
tools = json.loads(Path(__file__).with_name("tools.json").read_text())
selected = [tool for tool in tools if tool["name"] in {"search_docs", "read_doc"}]
encode = lambda value: json.dumps(value, ensure_ascii=False, separators=(",", ":")).encode("utf-8")
print(json.dumps({"all_tools": len(tools), "selected_tools": len(selected),
"all_compact_utf8_bytes": len(encode(tools)),
"selected_compact_utf8_bytes": len(encode(selected))}, indent=2))
@gjwang
gjwang / README.md
Last active November 4, 2026 06:08
Web3.py HTTPError: inspect the response body without swallowing the HTTP failure

Your Web3.py HTTP error response can exist and still be falsey

This is an easy diagnostic to accidentally disable:

except requests.HTTPError as exc:
    if exc.response:
        # This branch is skipped for 4xx and 5xx responses.
        ...
@gjwang
gjwang / LICENSE
Created November 3, 2026 04:03
Backboard link checker: seven offline URL-classification controls against pinned source 61364e84
MIT License
Copyright (c) 2026 Vikram Singh
Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the rights
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom the Software is
furnished to do so, subject to the following conditions:
@gjwang
gjwang / 01-chain-id.response.json
Last active November 3, 2026 06:43
Ink Aero CLFactory: saved keyless block-pinned read (BlockVectra QA, 2026-11-02)
{"jsonrpc":"2.0","id":1,"result":"0xdef1"}