Python logo

上個主題

test --- Regression tests package for Python

下個主題

稽核事件表

此頁面

  • 回報錯誤
  • 顯示原始碼

瀏覽

  • 索引
  • 模組 |
  • 下一頁 |
  • 上一頁 |
  • Python logo
  • Python »
  • 3.11.8 Documentation »
  • Python 標準函式庫 (Standard Library) »
  • 除錯與效能分析
  • |
  • |

除錯與效能分析¶

這些函式庫幫助你進行 Python 程式開發:除錯器允許你在程式碼中單步 (step) 執行、分析堆疊框 (stack frames) 以及設置中斷點 (breakpoints) 等,效能分析工具執行程式碼並提供關於執行時間的詳細分析,讓你找到程式中的瓶頸 (bottlenecks)。事件稽核 (auditing events) 提供執行時期行為的可見性,否則的話可能需要更侵入性的除錯或修補。

  • 稽核事件表
  • bdb --- Debugger framework
  • faulthandler --- Dump the Python traceback
    • Dumping the traceback
    • Fault handler state
    • Dumping the tracebacks after a timeout
    • Dumping the traceback on a user signal
    • Issue with file descriptors
    • 範例
  • pdb --- The Python Debugger
    • Debugger Commands
  • The Python Profilers
    • Introduction to the profilers
    • Instant User's Manual
    • profile and cProfile Module Reference
    • The Stats Class
    • What Is Deterministic Profiling?
    • 限制
    • 校正
    • Using a custom timer
  • timeit --- 測量小量程式片段的執行時間
    • 基礎範例
    • Python Interface
    • 命令執行列介面
    • 範例
  • trace --- Trace or track Python statement execution
    • Command-Line Usage
      • Main options
      • Modifiers
      • Filters
    • Programmatic Interface
  • tracemalloc --- Trace memory allocations
    • 範例
      • Display the top 10
      • Compute differences
      • Get the traceback of a memory block
      • Pretty top
        • Record the current and peak size of all traced memory blocks
    • API
      • 函式
      • DomainFilter
      • Filter
      • Frame
      • Snapshot
      • Statistic
      • StatisticDiff
      • Trace
      • Traceback

上個主題

test --- Regression tests package for Python

下個主題

稽核事件表

此頁面

  • 回報錯誤
  • 顯示原始碼
«

瀏覽

  • 索引
  • 模組 |
  • 下一頁 |
  • 上一頁 |
  • Python logo
  • Python »
  • 3.11.8 Documentation »
  • Python 標準函式庫 (Standard Library) »
  • 除錯與效能分析
  • |
  • |
© 版權 2001-2024, Python Software Foundation.
This page is licensed under the Python Software Foundation License Version 2.
Examples, recipes, and other code in the documentation are additionally licensed under the Zero Clause BSD License.
See History and License for more information.

The Python Software Foundation is a non-profit corporation. Please donate.

最後更新於 Apr 02, 2024 (03:07 UTC)。 Found a bug?
使用 Sphinx 7.2.6 建立。