Deployed ce0babb4 with MkDocs version: 1.6.1

This commit is contained in:
2026-12-02 23:14:58 +00:00
parent db7b0bba39
commit 8ac4dd8396
5 changed files with 9 additions and 4 deletions
+1 -1
View File
@@ -2813,7 +2813,7 @@
</div>
<div class="admonition tip">
<p class="admonition-title">Let tool runs log themselves</p>
<p>For external-tool calls (FFmpeg, mkvmerge, <code>dovi_tool</code>, and friends), route through <code>run_step</code> / <code>run_tool</code> / <code>ffprobe</code>, which auto-emit a <code>tool_run</code> entry capturing the binary's version, return code, and duration consistently. <code>run_tool</code> also raises <code>ToolFailed</code>, whose message names the tool, the exit code and the last lines the tool wrote. Only fall back to calling <code>log_tool_run</code> manually for a direct <code>subprocess.run</code> you genuinely cannot route through those helpers. Auto-logging is the preferred path precisely because it captures those fields the same way every time.</p>
<p>For external-tool calls (FFmpeg, mkvmerge, <code>dovi_tool</code>, and friends), route through <code>run_step</code> / <code>run_tool</code> / <code>ffprobe</code>, which auto-emit a <code>tool_run</code> entry capturing the binary's version, return code, and duration consistently. <code>run_tool</code> also raises <code>ToolFailed</code>, whose message names the tool, the exit code and the last lines the tool wrote. A failure that the caller recovers from (a retry, a fallback) is named with <code>handled=</code> (exit codes or stderr text): its <code>tool_run</code> entry is <code>DEBUG</code>, not <code>ERROR</code>, and the call still raises. Only fall back to calling <code>log_tool_run</code> manually for a direct <code>subprocess.run</code> you genuinely cannot route through those helpers. Auto-logging is the preferred path precisely because it captures those fields the same way every time.</p>
</div>