Skip to content

feat: add aztec_lookup_error tool for error diagnosis#11

Merged
critesjosh merged 1 commit intomainfrom
feat/error-lookup-tool
Mar 4, 2026
Merged

feat: add aztec_lookup_error tool for error diagnosis#11
critesjosh merged 1 commit intomainfrom
feat/error-lookup-tool

Conversation

@critesjosh
Copy link
Collaborator

Summary

  • Adds aztec_lookup_error MCP tool that diagnoses Aztec errors by message, error code, or hex signature
  • Combines a curated static catalog (circuit codes, AVM errors, contract assertions) with dynamic parsers that extract errors from cloned source files (Errors.sol, error_texts.ts, debugging.md, operator-faq.md)
  • Moves doc source paths (debugging.md, operator-faq.md) to sparsePathOverrides so they're fetched from the next branch like other versioned docs
  • Invalidates the dynamic error cache after aztec_sync_repos to prevent stale results

Test plan

  • All 179 tests pass (15 new tests for error lookup)
  • Manual test: run aztec_lookup_error with a numeric code (e.g. 2002), hex sig (e.g. 0xa5b2ba17), and error message substring
  • Manual test: run aztec_sync_repos then aztec_lookup_error to verify cache invalidation
  • Verify docs are cloned from next branch into aztec-packages-docs

🤖 Generated with Claude Code

Add a new MCP tool that diagnoses Aztec errors by message, error code,
or hex signature. Combines a curated static catalog with dynamic parsers
that extract errors from cloned source files (Errors.sol, error_texts.ts,
debugging.md, operator-faq.md).

- Static catalog covers circuit codes, AVM errors, and common contract assertions
- Dynamic parsers run at query time with session-level caching
- Cache is invalidated after repo sync to prevent stale results
- Doc sources moved to sparsePathOverrides (next branch) to match docs workflow
- Matching algorithm supports exact code, hex sig, pattern, substring, and word overlap

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
@critesjosh critesjosh merged commit 1946be7 into main Mar 4, 2026
6 checks passed
@critesjosh critesjosh deleted the feat/error-lookup-tool branch March 4, 2026 21:42
@github-actions
Copy link

github-actions bot commented Mar 4, 2026

🎉 This PR is included in version 1.13.0 🎉

The release is available on:

Your semantic-release bot 📦🚀

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant