diagnostics

Retrieve LSP diagnostics and suggest project rollback for debugging static errors.

Updated Apr 20, 2026
One-click install
npx skills add https://github.com/AmirEmad11/instabot --skill diagnostics-amiremad11
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: diagnostics
Source: https://github.com/AmirEmad11/instabot/tree/main/.local/skills/diagnostics
Command: npx skills add https://github.com/AmirEmad11/instabot --skill diagnostics-amiremad11

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve? After making code changes, developers need to quickly detect syntax errors, type errors, and import issues, and sometimes need a safe way to revert changes that broke the project. This Skill provides direct access to language server diagnostics and a guided rollback suggestion flow. ## Core Features & Use Cases - LSP Diagnostics Retrieval: Check syntax errors, type errors, and import issues for a specific file or across all files with errors. - Rollback Suggestion: Surface a "View Checkpoints" prompt when the user wants to undo changes, restore a previous version, or start over. - Use Case: After refactoring a large module, call getLatestLspDiagnostics on the edited file to list every error with line numbers, fix them one by one, and if the changes are unrecoverable, suggest a rollback so the user can restore a working checkpoint. ## Quick Start Check the file I just edited for any LSP errors and list them with line numbers.

Frequently Asked Questions about diagnostics

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

FAQPage Schema
How do I check for type errors after editing a file?

Call getLatestLspDiagnostics with the filePath parameter set to the edited file. It returns a dictionary mapping file paths to error lists, each with line numbers and messages you can iterate over and fix.

How to check all project files for LSP errors at once?

Call getLatestLspDiagnostics without any arguments. It returns diagnostics for every file that currently has errors, and you can inspect the keys of the diagnostics object to see which files are affected.

When should I check LSP diagnostics versus skip it?

Check LSP after refactoring more than 100 lines, adding imports or dependencies, or when the user reports errors. Skip it for small changes under 10 lines, comment edits, or runtime bugs, which LSP cannot detect.

Does the rollback suggestion actually revert my code?

No, suggestRollback only displays a View Checkpoints button and pauses for user input. The user must click the button and choose a checkpoint to restore a previous project state.

Why are runtime errors not showing in LSP diagnostics?

LSP diagnostics only cover static analysis such as syntax, type, and import errors. Runtime exceptions and logic bugs require logs, debuggers, or test execution instead of language server checks.