Langsung ke konten
Skillpedia
Pemrograman umum70k Β· #3132

debugging

Fungsinya

Tool ini membantu menemukan dan memperbaiki bug pada program komputer. Caranya dengan menyelidiki perilaku program yang sebenarnya untuk menemukan penyebab masalah, bukan sekadar menebak berdasarkan kode.

Kapan dipakai

  • βœ“Ketika sebuah program tiba-tiba berhenti (crash).
  • βœ“Ketika program tidak bekerja seperti yang diharapkan tetapi tidak menampilkan error yang jelas.
  • βœ“Ketika program berjalan lambat atau tidak merespons.

Link skill

https://github.com/code-yeongyu/oh-my-openagent/blob/dev/packages/shared-skills/skills/debugging/SKILL.md

Salin lalu tempelkan ke AI Anda (Claude, ChatGPT, atau Cursor) dan minta AI mengikuti instruksinya.

Cara pakai

Cara paling mudah: salin pesan ini dan tempelkan ke AI Anda. AI akan membaca skill dan mengikuti instruksinya.

Pesan siap tempel

Gunakan skill ini untuk membantu saya: https://github.com/code-yeongyu/oh-my-openagent/blob/dev/packages/shared-skills/skills/debugging/SKILL.md Baca file SKILL.md di link tersebut dan ikuti instruksinya untuk tugas saya.
Mau AI Anda menemukan skill seperti ini sendiri?Pasang MCP Skillpedia gratis: cukup satu baris, dan AI mencari di antara 15.000+ skill sebelum tiap tugas.Pasang dalam 1 menit β†’

Contoh permintaan ke AI

β€œProgram Python saya crash saat saya mencoba menyimpan file, bisa bantu cari tahu penyebabnya?”

5 skill baru setiap minggu. 1 menit baca.

Cara kerjanya

Tool ini pertama-tama memeriksa perilaku program secara langsung untuk memahami masalahnya. Kemudian, tool ini menggunakan panduan khusus untuk bahasa pemrograman atau jenis program tertentu guna menemukan solusi yang tepat, dan memastikan bug tersebut tidak muncul lagi.

Konten teknis (SKILL.md asli)

Teks asli dari pembuat, dalam bahasa Inggris, langsung dari GitHub.

Debugging

You are a hypothesis-driven debugger. Two disciplines apply regardless of language, runtime, or whether you have source:

  1. Runtime truth beats code reading. Every claim about why the bug happens must come from observed state β€” never from a plausible story spun from reading code.
  2. Leave no trace. Debugging creates artifacts. Every artifact is journaled and removed before you call the task done.

The rest of this file is a map. The knowledge is in references/. This file cannot teach you how to debug β€” it can only tell you which reference will, for your exact situation.


🚨 READ THE REFERENCES. THIS IS NOT OPTIONAL.

This skill is intentionally small. Ninety percent of what you need to know lives in references/. If you skim this file and start working without opening the references, you will reattach a debugger the wrong way, miss a silent-failure pattern you've never seen before, waste an hour on a source-map gotcha, or invent a worse version of a tool that already solves your problem.

Every reference below is mandatory when its scenario applies. "I know this language" is not an exemption. The references exist because every runtime and every specialist tool has at least one gotcha that silently wastes hours, and you will not know which gotcha until you read the file.

The gate rule: before you run a command from a given reference's domain, you must have read that reference in this session. Re-reading across sessions is cheap. Guessing is expensive.


Runtime Setup β€” MANDATORY READING BEFORE ATTACHING

The methodology is language-agnostic. The commands to launch, attach, breakpoint, and inspect are not. Open the matching reference before Phase 0. Not during. Not after.

Your runtime is… Open this before attaching anything Non-negotiable because…
Python (CPython, pytest, asyncio, Django, FastAPI) πŸ“– references/runtimes/python.md pdb vs ipdb vs debugpy vs pytest --pdb all have different attach semantics. Async code needs special breakpoint handling. Wrappers like poetry run swallow flags.
Node.js / tsx / ts-node / Bun / Deno (running source) πŸ“– references/runtimes/node.md tsx + node inspect CLI has a silent source-map failure β€” breakpoints by line number do not fire. You will not notice unless you read this first.
Rust (cargo, tokio, panics) πŸ“– references/runtimes/rust.md Release builds strip symbols. Tokio tasks need tokio-console. The borrow checker makes dbg! the faster tool most of the time.
Go (goroutines, dlv, pprof, race) πŸ“– references/runtimes/go.md Goroutine leaks and recovered panics are silent by default. dlv has a specific port convention. go test -race is the first thing to run, not the last.
Native binary / stripped C/C++ / no source πŸ“– references/runtimes/native-binary.md The workflow (triage β†’ dynamic β†’ static β†’ scripted repro) is counterintuitive if you've never done it. strings -n 8 silently drops short interpolations like ${x} β€” read bytes directly for any extraction that matters. macOS adds SIP / Mach-O / lldb specifics that don't apply on Linux.
Bundled-app binary (Bun SEA, Node SEA, Deno compile, pkg, nexe, Electron, Tauri, PyInstaller) πŸ“– references/runtimes/bundled-js-binary.md These look like Mach-O / ELF but their high-level source is recoverable with the right per-bundler tool β€” Ghidra is overkill. Source-format reality varies: Bun/pkg/nexe/Electron-asar are usually plaintext; Node SEA with code-cache, PyInstaller .pyc, and Deno eszip need extra tooling; Tauri's Rust core still needs native-binary.md. Workflow: identify bundler β†’ locate bundle β†’ extract with the bundler-specific tool β†’ grep.

If you cannot honestly say you just opened the reference for your runtime, open it now.

🚨 Native binary vs bundled binary β€” check before committing: file ./target calls them both Mach-O / ELF. The 30-second discriminator is du -h ./target (50 MB+ suspect bundled) plus strings -n 12 ./target | rg -iE 'bun|node_modules|webpack|esbuild|deno|pkg/lib|electron|pyinstaller|nexe|NODE_SEA_FUSE|tauri'. If hits β†’ bundled-js-binary.md. If clean β†’ native-binary.md.


…

Pertanyaan umum

Apakah saya harus menjadi programmer untuk menggunakan ini?

Anda tidak perlu menjadi ahli, tetapi memiliki gambaran dasar tentang apa yang seharusnya dilakukan program akan sangat membantu dalam mengidentifikasi masalah.

Apakah tool ini bisa digunakan untuk semua jenis program?

Bisa. Tool ini memiliki panduan untuk berbagai bahasa pemrograman dan jenis program, termasuk program yang kode sumbernya tidak terlihat.

Apa yang dimaksud dengan 'references'?

Ini adalah panduan rinci yang menjelaskan cara menggunakan alat tertentu untuk setiap jenis masalah atau bahasa pemrograman. Penting untuk dibaca sebelum memulai.

Detail

Deskripsi asli dari pembuat

Runs a hypothesis-driven debugging loop across any language or binary, escalating to orthogonal oracle angles and locking the fix with a failing test. Use for crashes, silent failures, hangs, wrong responses, memory leaks, async misbehavior, or reverse engineering.

repo: code-yeongyu/oh-my-openagent

Popularitas

Bintang GitHub
70k
Peringkat
#3132
Lisensi
NOASSERTION
Diperbarui
15/10/2026

Apakah skill ini berguna?

0

Masuk untuk memberi suara.

Komentar

  • …

Skill lain dari repositori ini

Skill serupa