[{"data":1,"prerenderedAt":-1},["ShallowReactive",2],{"skill:01M6CWY3NHNGXJGG2Z9TVK2519":3,"skill-same:01M6CWY3NHNGXJGG2Z9TVK2519":50},{"skillNo":4,"name":5,"nameZh":6,"description":7,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":6,"repositoryNo":12,"starsCount":13,"licenseSpdxId":14,"licenseFileUrl":6,"sourceHtmlUrl":15,"categories":16,"keywords":17,"publishedAt":23,"linkOnly":24,"markdownContent":25,"markdownBody":26,"frontMatter":27,"refName":30,"commitSha":31,"skillDirectory":5,"forksCount":32,"repositoryHtmlUrl":33,"repositoryHomepageUrl":6,"ownerHtmlUrl":34,"ownerBlogUrl":6,"ownerDescription":6,"updatedAt":35,"install":36,"resources":49},"01M6CWY3NHNGXJGG2Z9TVK2519","debugging",null,"Debugging techniques and tools","ffsshhttiikk\u002Fopencode-agents-skills","ffsshhttiikk","https:\u002F\u002Favatars.githubusercontent.com\u002Fu\u002F226346827?v=4","01M6CWD9RR3Y7VRQX3MXYC8FYH","01M6CWD9WVPYAZW0J82G1VKGHY",3,"MIT","https:\u002F\u002Fgithub.com\u002Fffsshhttiikk\u002Fopencode-agents-skills\u002Fblob\u002Fmain\u002Fdebugging\u002FSKILL.md",[],[5,18,19,20,21,22],"code","Tools","code-quality","quality","opencode","2026-11-10 10:12:30",false,"---\nname: debugging\ndescription: Debugging techniques and tools\nlicense: MIT\ncompatibility: opencode\nmetadata:\n  audience: developers\n  category: code-quality\n---\n## What I do\n- Debug application issues effectively\n- Use debugging tools and techniques\n- Analyze crash dumps and stack traces\n- Profile performance bottlenecks\n- Debug network issues\n- Handle production incidents\n- Use logging for debugging\n- Write debuggable code\n\n## When to use me\nWhen debugging issues or troubleshooting problems.\n\n## Debugging Techniques\n\n### Scientific Method for Debugging\n```\n1. Observe the symptom\n   - What error message?\n   - What was the input?\n   - When does it happen?\n\n2. Form a hypothesis\n   - What could cause this?\n   - What's the most likely cause?\n\n3. Test hypothesis\n   - Can I reproduce it?\n   - What changes the behavior?\n\n4. Refine hypothesis\n   - Narrow down the cause\n   - Test edge cases\n\n5. Fix the bug\n   - Make minimal change\n   - Verify the fix\n\n6. Prevent regression\n   - Add test case\n   - Document the issue\n```\n\n## Python Debugging\n```python\nimport pdb\nfrom typing import Any\n\n\n# Interactive debugging with pdb\ndef debug_with_pdb():\n    \"\"\"Start interactive debugger.\"\"\"\n    breakpoint()  # Python 3.7+\n\n\n# pdb commands\n# n (next) - execute current line\n# s (step) - step into function\n# c (continue) - run to breakpoint\n# l (list) - show source\n# p (print) - print variable\n# pp (pretty print) - pretty print\n# w (where) - show stack trace\n# u (up) - go up stack\n# d (down) - go down stack\n# q (quit) - quit debugger\n\n\n# Remote debugging with rpdb\nimport rpdb\n\n\ndef start_remote_debugger(port=4444):\n    \"\"\"Start debugger on specified port.\"\"\"\n    rpdb.set_trace(port=port)\n\n\n# Using icecream for debugging\nfrom icecream import ic\n\n\ndef debug_with_icecream():\n    \"\"\"Print variable values with expressions.\"\"\"\n    x = 10\n    y = 20\n    z = x + y\n    \n    ic(x)  # ic| x = 10\n    ic(y)  # ic| y = 20\n    ic(z)  # ic| z = 30\n    ic(x + y)  # ic| x + y = 30\n\n\n# Logging for debugging\nimport logging\n\n\nlogging.basicConfig(level=logging.DEBUG)\nlogger = logging.getLogger(__name__)\n\n\ndef debug_with_logging(data: dict) -> dict:\n    \"\"\"Debug with structured logging.\"\"\"\n    logger.debug(\"Processing data\", extra={\n        'data_keys': list(data.keys()),\n        'data_size': len(data),\n    })\n    \n    result = {k: v * 2 for k, v in data.items()}\n    \n    logger.debug(\"Processed result\", extra={\n        'result': result,\n        'result_keys': list(result.keys()),\n    })\n    \n    return result\n\n\n# Better debugging with rich\nfrom rich import print as rprint\nfrom rich.pretty import pprint\n\n\ndef debug_with_rich():\n    \"\"\"Pretty print with rich.\"\"\"\n    data = {'name': 'test', 'values': [1, 2, 3], 'nested': {'a': 1}}\n    \n    pprint(data)  # Beautiful syntax-highlighted output\n```\n\n## JavaScript Debugging\n```javascript\n\u002F\u002F Console debugging\nfunction debugWithConsole() {\n  const data = { name: 'test', value: 42 };\n  \n  \u002F\u002F Basic logging\n  console.log('Data:', data);\n  \n  \u002F\u002F Grouped logs\n  console.group('Processing');\n  console.log('Start');\n  console.log('Processing...');\n  console.log('Done');\n  console.groupEnd();\n  \n  \u002F\u002F Table\n  const users = [\n    { name: 'Alice', age: 30 },\n    { name: 'Bob', age: 25 },\n  ];\n  console.table(users);\n  \n  \u002F\u002F Stack trace\n  console.trace('Stack trace');\n  \n  \u002F\u002F Timing\n  console.time('operation');\n  \u002F\u002F ... code ...\n  console.timeEnd('operation');\n}\n\n\u002F\u002F Chrome DevTools debugging\n\u002F\u002F 1. Open DevTools (F12)\n\u002F\u002F 2. Sources panel\n\u002F\u002F 3. Set breakpoints\n\u002F\u002F 4. Use debugger statement\nfunction buggyFunction() {\n  debugger;  \u002F\u002F Breakpoint\n  \u002F\u002F Step through code\n}\n\n\u002F\u002F VS Code debugging\n\u002F\u002F .vscode\u002Flaunch.json\n{\n  \"version\": \"0.2.0\",\n  \"configurations\": [\n    {\n      \"type\": \"node\",\n      \"request\": \"launch\",\n      \"name\": \"Debug\",\n      \"program\": \"${workspaceFolder}\u002Fapp.js\",\n      \"skipFiles\": [\"\u003Cnode_internals>\u002F**\"]\n    }\n  ]\n}\n```\n\n## Performance Profiling\n```python\nimport cProfile\nimport pstats\nfrom memory_profiler import profile, memory_usage\nimport time\n\n\ndef profile_code():\n    \"\"\"Profile CPU usage.\"\"\"\n    profiler = cProfile.Profile()\n    profiler.enable()\n    \n    # Code to profile\n    result = [i * 2 for i in range(10000)]\n    \n    profiler.disable()\n    \n    # Print stats\n    stats = pstats.Stats(profiler)\n    stats.sort_stats('cumulative')\n    stats.print_stats(20)  # Top 20 functions\n\n\n@profile  # Memory profiler decorator\ndef profile_memory():\n    \"\"\"Profile memory usage.\"\"\"\n    data = [i * 2 for i in range(100000)]\n    time.sleep(0.1)\n    return data\n\n\n# Line-by-line profiling\nfrom line_profiler import LineProfiler\n\n\ndef profile_lines():\n    profiler = LineProfiler()\n    profiler.add_function(slow_function)\n    profiler.enable_by_count()\n    \n    slow_function()\n    \n    profiler.disable()\n    profiler.print_stats()\n```\n\n## Debugging Production Issues\n```python\nimport sys\nimport traceback\n\n\nclass ProductionDebugger:\n    \"\"\"Debug issues in production safely.\"\"\"\n    \n    def __init__(self, log_file: str = '\u002Fvar\u002Flog\u002Fapp\u002Fdebug.log') -> None:\n        self.log_file = log_file\n    \n    def setup_error_handling(self) -> None:\n        \"\"\"Setup comprehensive error handling.\"\"\"\n        sys.excepthook = self.handle_exception\n    \n    def handle_exception(self, exc_type, exc_value, exc_traceback) -> None:\n        \"\"\"Log exceptions with full context.\"\"\"\n        import os\n        \n        # Log to file\n        with open(self.log_file, 'a') as f:\n            f.write(f\"\\n{'='*60}\\n\")\n            f.write(f\"Exception: {exc_type.__name__}\\n\")\n            f.write(f\"Message: {exc_value}\\n\")\n            f.write(f\"Traceback:\\n\")\n            \n            tb = traceback.format_exception(exc_type, exc_value, exc_traceback)\n            f.write(''.join(tb))\n            \n            # Add context\n            f.write(f\"\\nProcess ID: {os.getpid()}\\n\")\n            f.write(f\"Working Directory: {os.getcwd()}\\n\")\n    \n    def add_context(self, key: str, value: Any) -> None:\n        \"\"\"Add context to error messages.\"\"\"\n        # Store in thread-local or async context\n        pass\n    \n    def capture_state(self) -> dict:\n        \"\"\"Capture current application state.\"\"\"\n        import gc\n        import psutil\n        import os\n        \n        process = psutil.Process(os.getpid())\n        \n        return {\n            'memory_mb': process.memory_info().rss \u002F 1024 \u002F 1024,\n            'cpu_percent': process.cpu_percent(),\n            'open_files': len(process.open_files()),\n            'threads': len(process.threads()),\n            'gc_stats': gc.get_stats(),\n        }\n\n\n# Debug endpoint for live inspection\nfrom flask import Flask, jsonify\n\n\napp = Flask(__name__)\n\n@app.route('\u002Fdebug\u002Fstate')\ndef debug_state():\n    \"\"\"Expose debug state for inspection.\"\"\"\n    debugger = ProductionDebugger()\n    return jsonify({\n        'state': debugger.capture_state(),\n        'config': {\n            'debug_mode': True,  # Only in debug\n        },\n        'environment': {\n            'python_version': sys.version,\n        },\n    })\n```\n\n## Network Debugging\n```python\nimport requests\nfrom requests.exceptions import RequestException\n\n\nclass NetworkDebugger:\n    \"\"\"Debug network requests.\"\"\"\n    \n    def __init__(self, base_url: str) -> None:\n        self.base_url = base_url\n        self.session = requests.Session()\n    \n    def debug_request(\n        self,\n        method: str,\n        url: str,\n        **kwargs\n    ) -> requests.Response:\n        \"\"\"Debug a network request.\"\"\"\n        full_url = f\"{self.base_url}{url}\"\n        \n        print(f\"\\n{'='*60}\")\n        print(f\"Request: {method.upper()} {full_url}\")\n        \n        # Log headers\n        headers = kwargs.get('headers', {})\n        print(f\"Headers: {dict(headers)}\")\n        \n        # Log body\n        if 'json' in kwargs:\n            print(f\"Body (JSON): {kwargs['json']}\")\n        elif 'data' in kwargs:\n            print(f\"Body: {kwargs['data']}\")\n        \n        try:\n            response = self.session.request(method, full_url, **kwargs)\n            \n            print(f\"\\nResponse: {response.status_code}\")\n            print(f\"Headers: {dict(response.headers)}\")\n            \n            # Log truncated response\n            content = response.text[:1000]\n            print(f\"Content (truncated): {content}\")\n            \n            return response\n            \n        except RequestException as e:\n            print(f\"Error: {e}\")\n            raise\n    \n    def check_connectivity(self, timeout: int = 5) -> dict:\n        \"\"\"Check network connectivity.\"\"\"\n        import socket\n        \n        checks = {}\n        \n        # DNS check\n        try:\n            socket.gethostbyname(self.base_url)\n            checks['dns'] = 'OK'\n        except socket.gaierror:\n            checks['dns'] = 'FAILED'\n        \n        # TCP check\n        try:\n            host = self.base_url.split(':\u002F\u002F')[1].split('\u002F')[0]\n            port = 443 if 'https' in self.base_url else 80\n            socket.create_connection((host, port), timeout)\n            checks['tcp'] = 'OK'\n        except Exception:\n            checks['tcp'] = 'FAILED'\n        \n        return checks\n```\n\n## Common Debugging Patterns\n```python\n# Binary search debugging\ndef bisect_debug():\n    \"\"\"Find the breaking change with binary search.\"\"\"\n    versions = [1, 2, 3, 4, 5, 6, 7, 8, 9, 10]\n    \n    # Test middle version\n    mid = len(versions) \u002F\u002F 2\n    print(f\"Testing version {versions[mid]}\")\n    \n    # If it works, test later versions\n    # If it fails, test earlier versions\n\n\n# Minimal reproduction\ndef minimal_reproduction():\n    \"\"\"Create minimal code to reproduce bug.\"\"\"\n    # Start with what you know:\n    # - Error message\n    # - Input that causes it\n    \n    # Strip away everything not needed\n    # until you have the smallest test case\n\n\n# Diff debugging\ndef diff_debug():\n    \"\"\"Compare working vs broken state.\"\"\"\n    import difflib\n    \n    working = \"correct behavior\"\n    broken = \"current behavior\"\n    \n    diff = difflib.unified_diff(\n        working.splitlines(),\n        broken.splitlines(),\n        lineterm='',\n    )\n    \n    for line in diff:\n        print(line)\n```\n\n## Debugging Tools Reference\n```\nPython:\n- pdb - Built-in debugger\n- ipdb - IPython-based debugger\n- rpdb - Remote debugger\n- icecream - Better print debugging\n- rich - Rich output\n- memory_profiler - Memory profiling\n- line_profiler - Line-by-line profiling\n- cProfile - CPU profiling\n- py-spy - Low-overhead sampling profiler\n\nJavaScript:\n- Chrome DevTools - Browser debugging\n- VS Code debugger - IDE debugging\n- Node.js inspector - Node debugging\n- ndb - Improved Node debugging\n\nGeneral:\n- strace - System call tracing (Linux)\n- ltrace - Library call tracing\n- dtrace - Dynamic tracing\n- wireshark - Network analysis\n- mitmproxy - HTTP proxy for debugging\n```\n","## What I do\n- Debug application issues effectively\n- Use debugging tools and techniques\n- Analyze crash dumps and stack traces\n- Profile performance bottlenecks\n- Debug network issues\n- Handle production incidents\n- Use logging for debugging\n- Write debuggable code\n\n## When to use me\nWhen debugging issues or troubleshooting problems.\n\n## Debugging Techniques\n\n### Scientific Method for Debugging\n```\n1. Observe the symptom\n   - What error message?\n   - What was the input?\n   - When does it happen?\n\n2. Form a hypothesis\n   - What could cause this?\n   - What's the most likely cause?\n\n3. Test hypothesis\n   - Can I reproduce it?\n   - What changes the behavior?\n\n4. Refine hypothesis\n   - Narrow down the cause\n   - Test edge cases\n\n5. Fix the bug\n   - Make minimal change\n   - Verify the fix\n\n6. Prevent regression\n   - Add test case\n   - Document the issue\n```\n\n## Python Debugging\n```python\nimport pdb\nfrom typing import Any\n\n\n# Interactive debugging with pdb\ndef debug_with_pdb():\n    \"\"\"Start interactive debugger.\"\"\"\n    breakpoint()  # Python 3.7+\n\n\n# pdb commands\n# n (next) - execute current line\n# s (step) - step into function\n# c (continue) - run to breakpoint\n# l (list) - show source\n# p (print) - print variable\n# pp (pretty print) - pretty print\n# w (where) - show stack trace\n# u (up) - go up stack\n# d (down) - go down stack\n# q (quit) - quit debugger\n\n\n# Remote debugging with rpdb\nimport rpdb\n\n\ndef start_remote_debugger(port=4444):\n    \"\"\"Start debugger on specified port.\"\"\"\n    rpdb.set_trace(port=port)\n\n\n# Using icecream for debugging\nfrom icecream import ic\n\n\ndef debug_with_icecream():\n    \"\"\"Print variable values with expressions.\"\"\"\n    x = 10\n    y = 20\n    z = x + y\n    \n    ic(x)  # ic| x = 10\n    ic(y)  # ic| y = 20\n    ic(z)  # ic| z = 30\n    ic(x + y)  # ic| x + y = 30\n\n\n# Logging for debugging\nimport logging\n\n\nlogging.basicConfig(level=logging.DEBUG)\nlogger = logging.getLogger(__name__)\n\n\ndef debug_with_logging(data: dict) -> dict:\n    \"\"\"Debug with structured logging.\"\"\"\n    logger.debug(\"Processing data\", extra={\n        'data_keys': list(data.keys()),\n        'data_size': len(data),\n    })\n    \n    result = {k: v * 2 for k, v in data.items()}\n    \n    logger.debug(\"Processed result\", extra={\n        'result': result,\n        'result_keys': list(result.keys()),\n    })\n    \n    return result\n\n\n# Better debugging with rich\nfrom rich import print as rprint\nfrom rich.pretty import pprint\n\n\ndef debug_with_rich():\n    \"\"\"Pretty print with rich.\"\"\"\n    data = {'name': 'test', 'values': [1, 2, 3], 'nested': {'a': 1}}\n    \n    pprint(data)  # Beautiful syntax-highlighted output\n```\n\n## JavaScript Debugging\n```javascript\n\u002F\u002F Console debugging\nfunction debugWithConsole() {\n  const data = { name: 'test', value: 42 };\n  \n  \u002F\u002F Basic logging\n  console.log('Data:', data);\n  \n  \u002F\u002F Grouped logs\n  console.group('Processing');\n  console.log('Start');\n  console.log('Processing...');\n  console.log('Done');\n  console.groupEnd();\n  \n  \u002F\u002F Table\n  const users = [\n    { name: 'Alice', age: 30 },\n    { name: 'Bob', age: 25 },\n  ];\n  console.table(users);\n  \n  \u002F\u002F Stack trace\n  console.trace('Stack trace');\n  \n  \u002F\u002F Timing\n  console.time('operation');\n  \u002F\u002F ... code ...\n  console.timeEnd('operation');\n}\n\n\u002F\u002F Chrome DevTools debugging\n\u002F\u002F 1. Open DevTools (F12)\n\u002F\u002F 2. Sources panel\n\u002F\u002F 3. Set breakpoints\n\u002F\u002F 4. Use debugger statement\nfunction buggyFunction() {\n  debugger;  \u002F\u002F Breakpoint\n  \u002F\u002F Step through code\n}\n\n\u002F\u002F VS Code debugging\n\u002F\u002F .vscode\u002Flaunch.json\n{\n  \"version\": \"0.2.0\",\n  \"configurations\": [\n    {\n      \"type\": \"node\",\n      \"request\": \"launch\",\n      \"name\": \"Debug\",\n      \"program\": \"${workspaceFolder}\u002Fapp.js\",\n      \"skipFiles\": [\"\u003Cnode_internals>\u002F**\"]\n    }\n  ]\n}\n```\n\n## Performance Profiling\n```python\nimport cProfile\nimport pstats\nfrom memory_profiler import profile, memory_usage\nimport time\n\n\ndef profile_code():\n    \"\"\"Profile CPU usage.\"\"\"\n    profiler = cProfile.Profile()\n    profiler.enable()\n    \n    # Code to profile\n    result = [i * 2 for i in range(10000)]\n    \n    profiler.disable()\n    \n    # Print stats\n    stats = pstats.Stats(profiler)\n    stats.sort_stats('cumulative')\n    stats.print_stats(20)  # Top 20 functions\n\n\n@profile  # Memory profiler decorator\ndef profile_memory():\n    \"\"\"Profile memory usage.\"\"\"\n    data = [i * 2 for i in range(100000)]\n    time.sleep(0.1)\n    return data\n\n\n# Line-by-line profiling\nfrom line_profiler import LineProfiler\n\n\ndef profile_lines():\n    profiler = LineProfiler()\n    profiler.add_function(slow_function)\n    profiler.enable_by_count()\n    \n    slow_function()\n    \n    profiler.disable()\n    profiler.print_stats()\n```\n\n## Debugging Production Issues\n```python\nimport sys\nimport traceback\n\n\nclass ProductionDebugger:\n    \"\"\"Debug issues in production safely.\"\"\"\n    \n    def __init__(self, log_file: str = '\u002Fvar\u002Flog\u002Fapp\u002Fdebug.log') -> None:\n        self.log_file = log_file\n    \n    def setup_error_handling(self) -> None:\n        \"\"\"Setup comprehensive error handling.\"\"\"\n        sys.excepthook = self.handle_exception\n    \n    def handle_exception(self, exc_type, exc_value, exc_traceback) -> None:\n        \"\"\"Log exceptions with full context.\"\"\"\n        import os\n        \n        # Log to file\n        with open(self.log_file, 'a') as f:\n            f.write(f\"\\n{'='*60}\\n\")\n            f.write(f\"Exception: {exc_type.__name__}\\n\")\n            f.write(f\"Message: {exc_value}\\n\")\n            f.write(f\"Traceback:\\n\")\n            \n            tb = traceback.format_exception(exc_type, exc_value, exc_traceback)\n            f.write(''.join(tb))\n            \n            # Add context\n            f.write(f\"\\nProcess ID: {os.getpid()}\\n\")\n            f.write(f\"Working Directory: {os.getcwd()}\\n\")\n    \n    def add_context(self, key: str, value: Any) -> None:\n        \"\"\"Add context to error messages.\"\"\"\n        # Store in thread-local or async context\n        pass\n    \n    def capture_state(self) -> dict:\n        \"\"\"Capture current application state.\"\"\"\n        import gc\n        import psutil\n        import os\n        \n        process = psutil.Process(os.getpid())\n        \n        return {\n            'memory_mb': process.memory_info().rss \u002F 1024 \u002F 1024,\n            'cpu_percent': process.cpu_percent(),\n            'open_files': len(process.open_files()),\n            'threads': len(process.threads()),\n            'gc_stats': gc.get_stats(),\n        }\n\n\n# Debug endpoint for live inspection\nfrom flask import Flask, jsonify\n\n\napp = Flask(__name__)\n\n@app.route('\u002Fdebug\u002Fstate')\ndef debug_state():\n    \"\"\"Expose debug state for inspection.\"\"\"\n    debugger = ProductionDebugger()\n    return jsonify({\n        'state': debugger.capture_state(),\n        'config': {\n            'debug_mode': True,  # Only in debug\n        },\n        'environment': {\n            'python_version': sys.version,\n        },\n    })\n```\n\n## Network Debugging\n```python\nimport requests\nfrom requests.exceptions import RequestException\n\n\nclass NetworkDebugger:\n    \"\"\"Debug network requests.\"\"\"\n    \n    def __init__(self, base_url: str) -> None:\n        self.base_url = base_url\n        self.session = requests.Session()\n    \n    def debug_request(\n        self,\n        method: str,\n        url: str,\n        **kwargs\n    ) -> requests.Response:\n        \"\"\"Debug a network request.\"\"\"\n        full_url = f\"{self.base_url}{url}\"\n        \n        print(f\"\\n{'='*60}\")\n        print(f\"Request: {method.upper()} {full_url}\")\n        \n        # Log headers\n        headers = kwargs.get('headers', {})\n        print(f\"Headers: {dict(headers)}\")\n        \n        # Log body\n        if 'json' in kwargs:\n            print(f\"Body (JSON): {kwargs['json']}\")\n        elif 'data' in kwargs:\n            print(f\"Body: {kwargs['data']}\")\n        \n        try:\n            response = self.session.request(method, full_url, **kwargs)\n            \n            print(f\"\\nResponse: {response.status_code}\")\n            print(f\"Headers: {dict(response.headers)}\")\n            \n            # Log truncated response\n            content = response.text[:1000]\n            print(f\"Content (truncated): {content}\")\n            \n            return response\n            \n        except RequestException as e:\n            print(f\"Error: {e}\")\n            raise\n    \n    def check_connectivity(self, timeout: int = 5) -> dict:\n        \"\"\"Check network connectivity.\"\"\"\n        import socket\n        \n        checks = {}\n        \n        # DNS check\n        try:\n            socket.gethostbyname(self.base_url)\n            checks['dns'] = 'OK'\n        except socket.gaierror:\n            checks['dns'] = 'FAILED'\n        \n        # TCP check\n        try:\n            host = self.base_url.split(':\u002F\u002F')[1].split('\u002F')[0]\n            port = 443 if 'https' in self.base_url else 80\n            socket.create_connection((host, port), timeout)\n            checks['tcp'] = 'OK'\n        except Exception:\n            checks['tcp'] = 'FAILED'\n        \n        return checks\n```\n\n## Common Debugging Patterns\n```python\n# Binary search debugging\ndef bisect_debug():\n    \"\"\"Find the breaking change with binary search.\"\"\"\n    versions = [1, 2, 3, 4, 5, 6, 7, 8, 9, 10]\n    \n    # Test middle version\n    mid = len(versions) \u002F\u002F 2\n    print(f\"Testing version {versions[mid]}\")\n    \n    # If it works, test later versions\n    # If it fails, test earlier versions\n\n\n# Minimal reproduction\ndef minimal_reproduction():\n    \"\"\"Create minimal code to reproduce bug.\"\"\"\n    # Start with what you know:\n    # - Error message\n    # - Input that causes it\n    \n    # Strip away everything not needed\n    # until you have the smallest test case\n\n\n# Diff debugging\ndef diff_debug():\n    \"\"\"Compare working vs broken state.\"\"\"\n    import difflib\n    \n    working = \"correct behavior\"\n    broken = \"current behavior\"\n    \n    diff = difflib.unified_diff(\n        working.splitlines(),\n        broken.splitlines(),\n        lineterm='',\n    )\n    \n    for line in diff:\n        print(line)\n```\n\n## Debugging Tools Reference\n```\nPython:\n- pdb - Built-in debugger\n- ipdb - IPython-based debugger\n- rpdb - Remote debugger\n- icecream - Better print debugging\n- rich - Rich output\n- memory_profiler - Memory profiling\n- line_profiler - Line-by-line profiling\n- cProfile - CPU profiling\n- py-spy - Low-overhead sampling profiler\n\nJavaScript:\n- Chrome DevTools - Browser debugging\n- VS Code debugger - IDE debugging\n- Node.js inspector - Node debugging\n- ndb - Improved Node debugging\n\nGeneral:\n- strace - System call tracing (Linux)\n- ltrace - Library call tracing\n- dtrace - Dynamic tracing\n- wireshark - Network analysis\n- mitmproxy - HTTP proxy for debugging\n```\n",{"name":5,"license":14,"metadata":28,"description":7,"compatibility":22},{"audience":29,"category":20},"developers","main","5f7a3e453c98261f93d19a6a7de44ad8f7b72d41",2,"https:\u002F\u002Fgithub.com\u002Fffsshhttiikk\u002Fopencode-agents-skills","https:\u002F\u002Fgithub.com\u002Fffsshhttiikk","2026-03-01 06:55:40",{"source":8,"skillName":5,"commands":37,"prompt":47,"zipAvailable":48},[38,41,44],{"tool":39,"command":40},"npx","npx skills add ffsshhttiikk\u002Fopencode-agents-skills --skill debugging",{"tool":42,"command":43},"bunx","bunx skills add ffsshhttiikk\u002Fopencode-agents-skills --skill debugging",{"tool":45,"command":46},"pnpm","pnpm dlx skills add ffsshhttiikk\u002Fopencode-agents-skills --skill debugging","安装技能，技能地址：https:\u002F\u002Fgithub.com\u002Fffsshhttiikk\u002Fopencode-agents-skills\u002Fblob\u002Fmain\u002Fdebugging\u002FSKILL.md",true,[],[51,62,72,81,91,100],{"skillNo":52,"name":53,"nameZh":6,"description":54,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":6,"repositoryNo":12,"starsCount":13,"licenseSpdxId":14,"licenseFileUrl":6,"sourceHtmlUrl":55,"categories":56,"keywords":57,"publishedAt":23},"01M6CXT9TXDF79BWJTMQAPB49G","xamarin","Xamarin cross-platform development","https:\u002F\u002Fgithub.com\u002Fffsshhttiikk\u002Fopencode-agents-skills\u002Fblob\u002Fmain\u002Fxamarin\u002FSKILL.md",[],[53,58,59,60,22,61],"platform","cross-platform","mobile","development",{"skillNo":63,"name":64,"nameZh":6,"description":65,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":6,"repositoryNo":12,"starsCount":13,"licenseSpdxId":14,"licenseFileUrl":6,"sourceHtmlUrl":66,"categories":67,"keywords":68,"publishedAt":23},"01M6CXT8AD04MFYDA32VW3FKAG","wrangling","Data wrangling fundamentals","https:\u002F\u002Fgithub.com\u002Fffsshhttiikk\u002Fopencode-agents-skills\u002Fblob\u002Fmain\u002Fwrangling\u002FSKILL.md",[],[64,69,22,70,71],"data wrangling","science","data",{"skillNo":73,"name":74,"nameZh":6,"description":75,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":6,"repositoryNo":12,"starsCount":13,"licenseSpdxId":14,"licenseFileUrl":6,"sourceHtmlUrl":76,"categories":77,"keywords":78,"publishedAt":23},"01M6CXT717GCN7SRRNPBDP4508","windows","Windows operating system administration and scripting","https:\u002F\u002Fgithub.com\u002Fffsshhttiikk\u002Fopencode-agents-skills\u002Fblob\u002Fmain\u002Fwindows\u002FSKILL.md",[],[74,79,22,80],"system","scripting",{"skillNo":82,"name":83,"nameZh":6,"description":84,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":6,"repositoryNo":12,"starsCount":13,"licenseSpdxId":14,"licenseFileUrl":6,"sourceHtmlUrl":85,"categories":86,"keywords":87,"publishedAt":23},"01M6CXT54K794NMEM3XAPZZDKT","wide-column","Wide-column data model","https:\u002F\u002Fgithub.com\u002Fffsshhttiikk\u002Fopencode-agents-skills\u002Fblob\u002Fmain\u002Fwide-column\u002FSKILL.md",[],[88,89,22,90,71],"wide column","databases","model",{"skillNo":92,"name":93,"nameZh":6,"description":94,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":6,"repositoryNo":12,"starsCount":13,"licenseSpdxId":14,"licenseFileUrl":6,"sourceHtmlUrl":95,"categories":96,"keywords":97,"publishedAt":23},"01M6CXT28FMT2P4V9GZE67WA8E","wide-column-stores","Wide-column database stores","https:\u002F\u002Fgithub.com\u002Fffsshhttiikk\u002Fopencode-agents-skills\u002Fblob\u002Fmain\u002Fwide-column-stores\u002FSKILL.md",[],[98,89,22,99],"wide column stores","database",{"skillNo":101,"name":102,"nameZh":6,"description":103,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":6,"repositoryNo":12,"starsCount":13,"licenseSpdxId":14,"licenseFileUrl":6,"sourceHtmlUrl":104,"categories":105,"keywords":106,"publishedAt":23},"01M6CXT0D0M0Q4T2N7C2RX7DSN","websockets","WebSocket implementation and best practices","https:\u002F\u002Fgithub.com\u002Fffsshhttiikk\u002Fopencode-agents-skills\u002Fblob\u002Fmain\u002Fwebsockets\u002FSKILL.md",[],[102,107,108,109,22,110,111],"websocket","real-time","time","best practices","implementation"]