stacktrace-mcp logo

stacktrace-mcp

by antonybudianto

stacktrace-mcp is a simple JS Stacktrace MCP designed for non-sourcemap users. It helps get the nearest error location from a JavaScript bundle URL and lets an LLM check if it matches anything in the current codebase.

View on GitHub

Last updated: N/A

What is stacktrace-mcp?

stacktrace-mcp is a Message Completion Provider (MCP) server that helps developers find the location of errors in JavaScript bundles, even without sourcemaps. It works by analyzing the stack trace and using an LLM to correlate it with the codebase.

How to use stacktrace-mcp?

  1. Clone the repo. 2. Run pnpm i to install dependencies. 3. Run pnpm build to build the server. 4. Add the local mcp server file path to your MCP-supported app (e.g., VSCode Copilot) in the settings.json. 5. Enable the MCP tool. 6. Copy your error stack trace to the prompt chat.

Key features of stacktrace-mcp

  • Finds error location without sourcemaps

  • Integrates with LLMs for codebase matching

  • Supports MCP-supported applications

  • Simple setup and usage

Use cases of stacktrace-mcp

  • Debugging JavaScript applications without sourcemaps

  • Quickly identifying the source of errors in production code

  • Improving the accuracy of error reporting in LLM-powered development tools

FAQ from stacktrace-mcp

What is an MCP?

MCP stands for Message Completion Provider. It's a protocol that allows tools like VSCode Copilot to interact with external servers to provide context-aware suggestions and completions.

Do I need sourcemaps to use this?

No, this tool is specifically designed for use cases where sourcemaps are not available.

What LLMs are supported?

The tool is designed to work with any LLM that can analyze code and match patterns.

What applications support MCP?

Applications like VSCode Copilot support the MCP protocol. Check your application's documentation for specific instructions on configuring MCP servers.

Is this tool production-ready?

While the tool provides a helpful debugging aid, consider its limitations and test thoroughly before relying on it in production environments.