debug-assistant
by @xueyetianya
Analyze and diagnose common programming error messages and stack traces with root causes and fix suggestions for Python, Node.js, Go, Bash, and system errors.
$ bash script.sh analyze "ECONNREFUSED 127.0.0.1:5432"π Error Analysis
βββββββββββββββββββββββββββββββββββββ
Type : System / Network Error
Code : ECONNREFUSED
Severity : HIGH
Summary : Connection actively refused by the target host
Root Cause:
The service at 127.0.0.1:5432 is not running or is not
accepting connections on that port.
Fix Suggestions:
1. Check if the service is running:
sudo systemctl status postgresql
2. Verify the port is correct and the service is bound to it:
ss -tlnp | grep 5432
3. Check firewall rules:
sudo ufw status
4. Confirm connection string in your config/env
$ bash script.sh explain ModuleNotFoundErrorπ Error Explanation
βββββββββββββββββββββββββββββββββββββ
Name : ModuleNotFoundError
Language : Python
Category : ImportError subclass
Description:
Raised when Python cannot locate the specified module.
This is a subclass of ImportError introduced in Python 3.6.
Common Causes:
β’ Package not installed in the current environment
β’ Virtual environment not activated
β’ Typo in the module name
β’ Module installed for a different Python version
clawhub install debug-assistant