Skip to content
Skills Library
Programming · Analysis

detecting-memory-leaks

/detecting-memory-leaks

Detect potential memory leaks and analyze memory usage patterns in code. Use when troubleshooting performance issues related to memory growth or identifying leak sources. Trigger with phrases like "detect memory leaks", "analyze memory usage", or "find memory issues".

Licence
MIT
Last repository change
26.10.2026

Assessment and security

100/ 100Class: good
Format25 / 25
Frontmatter with name and description, valid name, description up to 1,024 characters, name matching the folder.
Discoverability25 / 25
Description explains when to use the skill, has a reasonable length and uses third person.
Content35 / 35
At least 150 words and at most 500 lines, headings, step lists, examples or code.
Hygiene15 / 15
No placeholders such as TODO, no Windows paths, with a licence.
Riskno signals detected in the scan
Files in this package
7
Scripts
3
HTML comments
0
URLs in SKILL.md
0
Deprecation

No signals detected. Repository changed on 26.10.2026, without references to retired models or APIs.

Licence

MIT, open: use and modify while retaining author attribution.

What to check before installing
  • 3 scripts in this package. Review them before installing, as Claude may execute them.

Scripts: scripts/analyze_memory.py, scripts/generate_report.py, scripts/setup_environment.py

What it does and when to use it

Detect potential memory leaks and analyze memory usage patterns in code. Use when troubleshooting performance issues related to memory growth or identifying leak sources. Trigger with phrases like "detect memory leaks", "analyze memory usage", or "find memory issues".

Triggers from the description

detect memory leaksanalyze memory usagefind memory issues
Original author description

Detect potential memory leaks and analyze memory usage patterns in code. Use when troubleshooting performance issues related to memory growth or identifying leak sources. Trigger with phrases like "detect memory leaks", "analyze memory usage", or "find memory issues".

How it works

  1. Overview
  2. How It Works
  3. When to Use This Skill
  4. Examples
  5. Best Practices
  6. Integration
  7. Prerequisites
  8. Instructions
  9. Output
  10. Error Handling
Original SKILL.md headings · 93 lines, 461 words
SKILL.md preview
---
name: detecting-memory-leaks
description: Detect potential memory leaks and analyze memory usage patterns in code.
  Use when troubleshooting performance issues related to memory growth or identifying
  leak sources. Trigger with phrases like "detect memory leaks", "analyze memory usage",
  or "find memory issues".
version: 1.24.0
allowed-tools: Read, Write, Edit, Grep, Glob, Bash(profiling:*), Bash(memory:*)
license: MIT
author: Jeremy Longshore <jeremy@intentsolutions.io>
tags:
- performance
- detecting-memory
compatibility: Designed for Claude Code
---
# Memory Leak Detector

Detect and diagnose memory leaks in Node.js, Python, and JVM applications by analyzing event listeners, closures, unbounded caches, and retained references.

## Overview

This skill helps you identify and resolve memory leaks in your code. By analyzing your code for common memory leak patterns, it can help you improve the performance and stability of your application.

## How It Works

1. **Initiate Analysis**: The user requests memory leak detection.
2. **Code Analysis**: The plugin analyzes the codebase for potential memory leak patterns.
3. **Report Generation**: The plugin generates a report detailing potential memory leaks and recommended fixes.

## When to Use This Skill

This skill activates when you need to:

- Detect potential memory leaks in your application.
- Analyze memory usage patterns to identify performance bottlenecks.
- Troubleshoot performance issues related to memory leaks.

## Examples

### Example 1: Identifying Event Listener Leaks

User request: "detect memory leaks in my event handling code"

The skill will:

1. Analyze the code for unremoved event listeners.
2. Generate a report highlighting potential event listener leaks and suggesting how to properly remove them.

### Example 2: Analyzing Cache Growth

User request: "analyze memory usage to find excessive cache growth"

The skill will:

1. Analyze cache implementations for unbounded growth.
2. Identify caches that are not properly managed and recommend strategies for limiting their size.

## Best Practices

- **Code Review**: Always review the reported potential leaks to ensure they are genuine issues.
- **Regular Analysis**: Incorporate memory leak detection into your regular development workflow.
- **Targeted Analysis**: Focus your analysis on specific areas of your code that are known to be memory-intensive.

## Integration

This skill can be used in conjunction with other performance analysis tools to provide a comprehensive view of application performance.

## Prerequisites

- Access to application source code in ${CLAUDE_SKILL_DIR}/
- Memory profiling tools (valgrind, heapdump, etc.)
- Understanding of application memory architecture
- Runtime environment for testing

## Instructions

1. Analyze code for common memory leak patterns
2. Identify unremoved event listeners and callbacks
3. Check for unbounded cache growth
4. Review closure usage and retained references
5. Generate report with leak locations and severity
6. Provide remediation recommendations

## Output

- Memory leak detection report with file locations
- Pattern analysis for event listeners and caches
- Memory usage trends and growth patterns
- Code snippets highlighting potential leaks
- Recommended fixes with code examples

## Error Handling

If memory leak detection fails:

- Verify code file access permissions
- Check profiling tool installation
- Validate code syntax and structure
- Ensure sufficient memory for analysis
- Review runtime environment configuration

## Resources

- Memory profiling tool documentation
- Memory leak detection best practices
- JavaScript/Node.js memory management guides
- Performance optimization resources
Files in this package (7)
  • SKILL.md 4 KB
  • assets/README.md 1 KB
  • references/README.md 1 KB
  • scripts/README.md 1 KB
  • scripts/analyze_memory.py 5 KB
  • scripts/generate_report.py 4 KB
  • scripts/setup_environment.py 3 KB

Versions

RepositoryScoreLicence
This page · jeremylongshore/tons-of-skills-marketplace100MIT
HelixDevelopment/agent100MIT

Identical content appears in 1 other GitHub folders. We show one copy with the highest score.

Database snapshot: 13.11.2026 · package version 3f48d85643af (SHA-256 digest of the entire package)

Downloads in the last 30 days: 4 · ranking

Report a problem with this skill: harmful content, incorrect descriptions or an author’s removal request.

Similar skills

  • 95memory-leak-debugging
    Diagnoses and resolves memory leaks in JavaScript/Node.js applications. Use when a user reports high memory usage, OOM errors, or wants to analyze heapsnapshots or run memory leak detection tools like memlab.
  • 100profile-memory
    Profile memory usage in sidecar using Go pprof, system tools, and heap analysis. Covers identifying memory leaks, goroutine leaks, file descriptor accumulation, and CPU profiling. Use when investigating memory issues, profiling performance, debugging memory leaks, or diagnosing unresponsive plugins.
  • 100memory-leak-debug
    Diagnose memory leaks in the Qwen Code CLI using heap snapshots and the chrome-devtools CLI. Use when investigating high memory usage, unbounded growth, or suspected object retention issues.
  • 100memory-leak-debugging
    Diagnoses and resolves memory leaks in JavaScript/Node.js applications. Use when a user reports high memory usage, OOM errors, or wants to capture, compare, or inspect heap snapshots with Chrome DevTools MCP memory tools.
  • 100memory-leaks
    Use when reviewing scripts, client components, bundles, or runtime behavior related to Prevent common memory leak patterns. Inspect both source code and the browser execution path so fixes target the real bottleneck or bug.
  • 100memory-leak-diagnosis
    Use when investigating memory growth, retain cycles, leaks in Instruments, Task cancellation issues, or ARC problems in Swift 6 apps.

Feedback and reports

Your message goes to Bartosz Sokoliński. An email address is needed only for a reply. See the privacy policy.