テーマ: debugging
-
Jev 1.13 failure modes: literal reading, counting, dates, indirection and context rot
The nine failure modes TypeSafe documents for jev-1.13 (reviewed by the vendor on 2026-09-17), what each means for an agent that delegates decisions to the model, and the documented workaround for each: exact conditions in the instructions, arithmetic and date logic in code, filtered state, and no reliance on structural invariants between separate questions.
-
性能ボトルネックを見つける USE メソッド
CPU、メモリ、ディスク、ネットワーク、ロックなど、各リソースの利用率、飽和、エラーを調べる。USE メソッドは、アプリケーション層で推測を始める前に、ボトルネックを素早く見つけるチェックリストである。
-
Einen brauchbaren Fehlerbericht schreiben
Ein Fehlerbericht ist brauchbar, wenn eine fremde Person den Fehler ohne Rückfrage nachstellen kann: eine präzise Überschrift, Umgebung mit Versionen, nummerierte Schritte zum Nachstellen, erwartetes und tatsächliches Ergebnis getrennt, die wörtliche Fehlermeldung und ein möglichst kleines Beispiel. Vermutungen zur Ursache stehen in einem eigenen Abschnitt.
-
Diagnosing 'No space left on device' when df shows free space
ENOSPC has three common causes besides a full disk: exhausted inodes, space held by deleted files that a process still has open, and the reserved-blocks percentage on ext filesystems. Check df -i, lsof +L1 and the mount's reservation before deleting anything.
-
tracemalloc のスナップショットでメモリーリークを探す
PYTHONTRACEMALLOC または tracemalloc.start(nframe) で早めに追跡を開始します。ウォームアップ後と N 回の反復後にスナップショットを取り、インポートの雑音を除いて、compare_to(..., 'lineno') からサイズが N に比例して増える行を探します。呼び出し元を見るには 'traceback' 単位の集計に切り替えます。
-
MTU、フラグメンテーション、経路 MTU 探索
Ethernet は 1500 バイトの IP パケットを運び、トンネルや PPPoE ではそれより小さくなる。IPv6 ルーターはパケットを分割しない。経路 MTU 探索は ICMP Packet Too Big メッセージに依存するため、それがフィルターされると小さいパケットは通る一方、大きいパケットは無言で消える。この典型的なブラックホールは、MSS の制限やパケット化層でのプローブによって回避できる。
-
Systematische Fehlersuche in sechs Schritten
Fehler reproduzieren, präzise beobachten, eine Hypothese mit Vorhersage bilden, ein Experiment pro Änderung, ausgeschlossene Ursachen festhalten, Ursache beheben und mit einem Regressionstest absichern.
-
エージェントの再生可能な実行ログ:モデルとツールの呼び出しをすべて記録する
エージェントの実行をデバッグするには、モデルへの各要求、応答、ツール呼び出し、ツール結果を識別子とパラメーター付きで順番に記録する必要がある。OpenTelemetry GenAI のセマンティック規約がフィールド名を定め、再生可能なログがあれば新たな実行に料金を払わずに障害を再現できる。
-
Recovering lost commits and branches with the reflog
The reflog records every movement of HEAD and of each branch in the local repository, so a bad reset, rebase, amend or branch deletion can be undone by finding the earlier position and putting a new branch on it; entries expire after 90 days (30 for unreachable ones) by default, and uncommitted changes were never in it.
-
git bisect で回帰を引き起こしたコミットを見つける
git bisect は、正常だと分かっているコミットと問題があると分かっているコミットの間で、履歴を二分探索する。自動化したテストスクリプトを使えば、手作業で調べずに問題を生んだコミットを見つけられる。
-
Reducing a bug reproduction without removing the condition that causes it
Minimize a failing example while checking that the reduced case still demonstrates the original defect rather than a different, easier-to-produce error.
-
AddressSanitizer の調査:後の動作を信頼する前に最初の不正アクセスを直す
問題のない実行を証明とみなさず、AddressSanitizer のレポートを所有権や境界の最小回帰ケースに変えます。
-
バグ報告を回帰テストに変える
バグを直す前に、報告を示す失敗する自動テストとして再現します。そのテストが修正を証明し、バグの再発を防ぎます。
-
コンパイルデータベース:ヘッダーを変える前に失敗した翻訳単位を再現する
実際のコンパイルコマンドと作業ディレクトリを使い、ソースの不具合とエディター設定の誤りを区別します。
-
二分探索の落とし穴:中点のオーバーフローと境界のオフバイワンエラー
二分探索は短いものの、間違えやすいことで知られます。(low + high) / 2 は固定幅整数をオーバーフローさせ、包含・除外境界は混同しやすく、重複値があると返すインデックスも問題になります。ライブラリ、または半開区間と単調な述語を使い、端のケースをテストします。
-
Choosing the next debugging check by the hypotheses it can distinguish
Stop an investigation from repeating low-information diagnostics by choosing each next check for the competing explanations its result can separate.
-
最小限の再現可能な例を作る
最小限の再現可能な例は、問題が現れる範囲でコード、データ、環境を最も小さくしたものです。作る過程で診断の半分が済むことも多く、保守担当者やほかのエージェントが支援するためにも必要です。
-
pg_locks、pg_blocking_pids、lock_timeout による PostgreSQL のロック待ちとデッドロックの診断
停止したように見える文は、通常、別のトランザクションのロックを待っている。pg_stat_activity の wait_event_type Lock で待機側を、pg_blocking_pids() で阻害側を見つけ、状態と最後の文を調べて、取消・終了・待機を選ぶ。log_lock_waits は deadlock_timeout を超す待機を記録し、デッドロックは検出され、一方のトランザクションの中止で解決される。lock_timeout は DDL の待機時間を制限する。
-
Mit git bisect den verursachenden Commit finden
git bisect sucht binär zwischen einem bekannten guten und einem schlechten Commit; mit einem Prüfskript findet es den ersten fehlerhaften Commit ohne manuelles Ausprobieren.
-
First look at a misbehaving process with strace and tcpdump
Attach strace to see which system call a stuck process waits in and which files or sockets it touches; run tcpdump with a narrow filter and a packet count to see whether the peer answers at all. Both need privileges, both slow or fill things, so bound them in time and scope.
機械可読: JSON