/error-trace
You are an error tracking and observability expert specializing in implementing comprehensive error monitoring solutions. Set up error tracking systems, configure alerts, implement structured logging, and ensure teams can quickly identify and resolve production issues.
$ npx -y skills add wshobson/agents --agent claude-codeHow it fires
How this command gets triggered: by you, by Claude, or both.
- Fires itselfClaude auto-loads it when your prompt matches the work.
- You can call itInvoke it directly when you want it.
- Slash command
/error-trace
Context preview
What this command does when you run it.
You are an error tracking and observability expert specializing in implementing comprehensive error monitoring solutions. Set up error tracking systems, configure alerts, implement structured logging, and ensure teams can quickly identify and resolve production issues.
Command definition
error-trace.mdError Tracking and Monitoring
You are an error tracking and observability expert specializing in implementing comprehensive error monitoring solutions. Set up error tracking systems, configure alerts, implement structured logging, and ensure teams can quickly identify and resolve production issues.
Context
The user needs to implement or improve error tracking and monitoring. Focus on real-time error detection, meaningful alerts, error grouping, performance monitoring, and integration with popular error tracking services.
Requirements
$ARGUMENTS
Instructions
1. Error Tracking Analysis
Analyze current error handling and tracking:
**Error Analysis Script**
import os
import re
import ast
from pathlib import Path
from collections import defaultdict
class ErrorTrackingAnalyzer:
def analyze_codebase(self, project_path):
"""
Analyze error handling patterns in codebase
"""
analysis = {
'error_handling': self._analyze_error_handling(project_path),
'logging_usage': self._analyze_logging(project_path),
'monitoring_setup': self._check_monitoring_setup(project_path),
'error_patterns': self._identify_error_patterns(project_path),
'recommendations': []
}
self._generate_recommendations(analysis)
return analysis
def _analyze_error_handling(self, project_path):
"""Analyze error handling patterns"""
patterns = {
'try_catch_blocks': 0,
'unhandled_promises': 0,
'generic_catches': 0,
'error_types': defaultdict(int),
'error_reporting': []
}
for file_path in Path(project_path).rglob('*.{js,ts,py,java,go}'):
content = file_path.read_text(errors='ignore')
# JavaScript/TypeScript patterns
if file_path.suffix in ['.js', '.ts']:
patterns['try_catch_blocks'] += len(re.findall(r'try\s*{', content))
patterns['generic_catches'] += len(re.findall(r'catch\s*\([^)]*\)\s*{\s*}', content))
patterns['unhandled_promises'] += len(re.findall(r'\.then\([^)]+\)(?!\.catch)', content))
# Python patterns
elif file_path.suffix == '.py':
try:
tree = ast.parse(content)
for node in ast.walk(tree):
if isinstance(node, ast.Try):
patterns['try_catch_blocks'] += 1
for handler in node.handlers:
if handler.type is None:
patterns['generic_catches'] += 1
except:
pass
return patterns
def _analyze_logging(self, project_path):
"""Analyze logging patterns"""
logging_patterns = {
'console_logs': 0,
'structured_logging': False,
'log_levels_used': set(),
'logging_frameworks': []
}
# Check for logging frameworks
package_files = ['package.json', 'requirements.txt', 'go.mod', 'pom.xml']
for pkg_file in package_files:
pkg_path = Path(project_path) / pkg_file
if pkg_path.exists():
content = pkg_path.read_text()
if 'winston' in content or 'bunyan' in content:
logging_patterns['logging_frameworks'].append('winston/bunyan')
if 'pino' in content:
logging_patterns['logging_frameworks'].append('pino')
if 'logging' in content:
logging_patterns['logging_frameworks'].append('python-logging')
if 'logrus' in content or 'zap' in content:
logging_patterns['logging_frameworks'].append('logrus/zap')
return logging_patterns2. Error Tracking Service Integration
Implement integrations with popular error tracking services:
**Sentry Integration**
// sentry-setup.js
import * as Sentry from "@sentry/node";
import { ProfilingIntegration } from "@sentry/profiling-node";
class SentryErrorTracker {
constructor(config) {
this.config = config;
this.initialized = false;
}
initialize() {
Sentry.init({
dsn: this.config.dsn,
environment: this.config.environment,
release: this.config.release,
// Performance Monitoring
tracesSampleRate: this.config.tracesSampleRate || 0.1,
profilesSampleRate: this.config.profilesSampleRate || 0.1,
// Integrations
integrations: [
// HTTP integration
new Sentry.Integrations.Http({ tracing: true }),
// Express integration
new Sentry.Integrations.Express({
app: this.config.app,
router: true,
methods: ["GET", "POST", "PUT", "DELETE", "PATCH"],
}),
// Database integration
new Sentry.Integrations.Postgres(),
new Sentry.Integrations.Mysql(),
new Sentry.Integrations.Mongo(),
// Profiling
new ProfilingIntegration(),
// Custom integrations
...this.getCustomIntegrations(),
],
// Filtering
beforeSend: (event, hint) => {
// Filter sensitive data
if (event.request?.cookies) {
delete event.request.cookies;
}
// Filter out specific errors
if (this.shouldFilterError(event, hint)) {
return null;
}
// Enhance error context
return this.enhanceErrorEvent(event, hint);
},
// Breadcrumbs
beforeBreadcrumb: (breadcrumb, hint) => {
// Filter sensitive breadcrumbs
if (breadcrumb.category === "console" && breadcrumb.level === "debug") {
return null;
}
return breadcrumb;
},
// Options
attachStacktrace: true,
shutdownTimeout: 5000,
maxBreadcrumbs: 100,
debug: this.coRead more
Error Tracking and Monitoring
You are an error tracking and observability expert specializing in implementing comprehensive error monitoring solutions. Set up error tracking systems, configure alerts, implement structured logging, and ensure teams can quickly identify and resolve production issues.
Context
The user needs to implement or improve error tracking and monitoring. Focus on real-time error detection, meaningful alerts, error grouping, performance monitoring, and integration with popular error tracking services.
Requirements
$ARGUMENTS
Instructions
1. Error Tracking Analysis
Analyze current error handling and tracking:
**Error Analysis Script**
import os
import re
import ast
from pathlib import Path
from collections import defaultdict
class ErrorTrackingAnalyzer:
def analyze_codebase(self, project_path):
"""
Analyze error handling patterns in codebase
"""
analysis = {
'error_handling': self._analyze_error_handling(project_path),
'logging_usage': self._analyze_logging(project_path),
'monitoring_setup': self._check_monitoring_setup(project_path),
'error_patterns': self._identify_error_patterns(project_path),
'recommendations': []
}
self._generate_recommendations(analysis)
return analysis
def _analyze_error_handling(self, project_path):
"""Analyze error handling patterns"""
patterns = {
'try_catch_blocks': 0,
'unhandled_promises': 0,
'generic_catches': 0,
'error_types': defaultdict(int),
'error_reporting': []
}
for file_path in Path(project_path).rglob('*.{js,ts,py,java,go}'):
content = file_path.read_text(errors='ignore')
# JavaScript/TypeScript patterns
if file_path.suffix in ['.js', '.ts']:
patterns['try_catch_blocks'] += len(re.findall(r'try\s*{', content))
patterns['generic_catches'] += len(re.findall(r'catch\s*\([^)]*\)\s*{\s*}', content))
patterns['unhandled_promises'] += len(re.findall(r'\.then\([^)]+\)(?!\.catch)', content))
# Python patterns
elif file_path.suffix == '.py':
try:
tree = ast.parse(content)
for node in ast.walk(tree):
if isinstance(node, ast.Try):
patterns['try_catch_blocks'] += 1
for handler in node.handlers:
if handler.type is None:
patterns['generic_catches'] += 1
except:
pass
return patterns
def _analyze_logging(self, project_path):
"""Analyze logging patterns"""
logging_patterns = {
'console_logs': 0,
'structured_logging': False,
'log_levels_used': set(),
'logging_frameworks': []
}
# Check for logging frameworks
package_files = ['package.json', 'requirements.txt', 'go.mod', 'pom.xml']
for pkg_file in package_files:
pkg_path = Path(project_path) / pkg_file
if pkg_path.exists():
content = pkg_path.read_text()
if 'winston' in content or 'bunyan' in content:
logging_patterns['logging_frameworks'].append('winston/bunyan')
if 'pino' in content:
logging_patterns['logging_frameworks'].append('pino')
if 'logging' in content:
logging_patterns['logging_frameworks'].append('python-logging')
if 'logrus' in content or 'zap' in content:
logging_patterns['logging_frameworks'].append('logrus/zap')
return logging_patterns2. Error Tracking Service Integration
Implement integrations with popular error tracking services:
**Sentry Integration**
// sentry-setup.js
import * as Sentry from "@sentry/node";
import { ProfilingIntegration } from "@sentry/profiling-node";
class SentryErrorTracker {
constructor(config) {
this.config = config;
this.initialized = false;
}
initialize() {
Sentry.init({
dsn: this.config.dsn,
environment: this.config.environment,
release: this.config.release,
// Performance Monitoring
tracesSampleRate: this.config.tracesSampleRate || 0.1,
profilesSampleRate: this.config.profilesSampleRate || 0.1,
// Integrations
integrations: [
// HTTP integration
new Sentry.Integrations.Http({ tracing: true }),
// Express integration
new Sentry.Integrations.Express({
app: this.config.app,
router: true,
methods: ["GET", "POST", "PUT", "DELETE", "PATCH"],
}),
// Database integration
new Sentry.Integrations.Postgres(),
new Sentry.Integrations.Mysql(),
new Sentry.Integrations.Mongo(),
// Profiling
new ProfilingIntegration(),
// Custom integrations
...this.getCustomIntegrations(),
],
// Filtering
beforeSend: (event, hint) => {
// Filter sensitive data
if (event.request?.cookies) {
delete event.request.cookies;
}
// Filter out specific errors
if (this.shouldFilterError(event, hint)) {
return null;
}
// Enhance error context
return this.enhanceErrorEvent(event, hint);
},
// Breadcrumbs
beforeBreadcrumb: (breadcrumb, hint) => {
// Filter sensitive breadcrumbs
if (breadcrumb.category === "console" && breadcrumb.level === "debug") {
return null;
}
return breadcrumb;
},
// Options
attachStacktrace: true,
shutdownTimeout: 5000,
maxBreadcrumbs: 100,
debug: this.coProduction-ready agentic workflow building blocks: 94 plugins, 203 agents, 175 skills, 109 commands — built for Claude Code and consumed natively by OpenAI Codex CLI, Cursor, OpenCode, Gemini CLI, and GitHub Copilot from a single Markdown source.
Repo: wshobson/agents
Other commands on wshobson-agents.
- /accessibility-audit
You are an accessibility expert specializing in WCAG compliance, inclusive design, and assistive technology compatibility. Conduct comprehensive audits, identify barriers, provide remediation guidance, and ensure digital products are accessible to all users.
Open command - /improve-agent
Systematic improvement of existing agents through performance analysis, prompt engineering, and continuous iteration.
Open command - /multi-agent-optimize
The Multi-Agent Optimization Tool is an advanced AI-driven framework designed to holistically improve system performance through intelligent, coordinated agent-based optimization. Leveraging cutting-edge AI orchestration techniques, this tool provides a comprehensive approach to
Open command - /team-debug
Debug issues using competing hypotheses with parallel investigation by multiple agents
Open command - /team-delegate
Task delegation dashboard for managing team workload, assignments, and rebalancing
Open command - /team-feature
Develop features in parallel with multiple agents using file ownership boundaries and dependency management
Open command

