MCPcopy Create free account
hub / github.com/Accenture/mcp-bench / get_stats

Method get_stats

utils/error_handler.py:354–368  ·  view source on GitHub ↗

Get current error statistics. Returns: Dictionary with error statistics

(self)

Source from the content-addressed store, hash-verified

352 self.total_errors += 1
353
354 def get_stats(self) -> dict:
355 """Get current error statistics.
356
357 Returns:
358 Dictionary with error statistics
359 """
360 return {
361 'total_errors': self.total_errors,
362 'error_breakdown': self.error_counts.copy(),
363 'top_errors': sorted(
364 self.error_counts.items(),
365 key=lambda x: x[1],
366 reverse=True
367 )[:10]
368 }
369
370 def reset(self) -> None:
371 """Reset error statistics."""

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected