vllm-project/vllm · error · ValueError
chrome_trace output requires proton_data='trace'
Error message
chrome_trace output requires proton_data='trace'
What it means
ProfilerConfig enforces consistency between proton_output_format and proton_data when profiler='proton'. chrome_trace output requires the 'trace' data mode, because a Chrome trace can only be produced from trace-style records, not from the hierarchical tree data.
Source
Thrown at vllm/config/profiler.py:224
options = ", ".join(non_default_proton_options)
raise ValueError(
f"{options} only applicable when profiler is set to 'proton'"
)
if self.profiler == "proton" and not proton_profiler_dir:
raise ValueError(
"proton_profiler_dir must be set when profiler is 'proton'"
)
if proton_profiler_dir:
if _is_uri_path(proton_profiler_dir):
raise ValueError("proton_profiler_dir must be a local directory")
self.proton_profiler_dir = os.path.abspath(
os.path.expanduser(proton_profiler_dir)
)
if self.profiler == "proton":
output_format = self.proton_output_format
if output_format == "chrome_trace" and self.proton_data != "trace":
raise ValueError("chrome_trace output requires proton_data='trace'")
if (
output_format in ("hatchet", "hatchet_msgpack")
and self.proton_data != "tree"
):
raise ValueError(f"{output_format} output requires proton_data='tree'")
if self.capture_torch_profiler and self.profiler != "torch":
raise ValueError(
"capture_torch_profiler is only applicable when profiler is "
"set to 'torch'"
)
return self
View on GitHub (pinned to c794754062)
Solutions
- Set proton_data='trace' together with proton_output_format='chrome_trace'.
- Or keep proton_data='tree' and use a hatchet output format instead.
Example fix
# before ProfilerConfig(profiler='proton', proton_profiler_dir='/tmp/p', proton_output_format='chrome_trace') # after ProfilerConfig(profiler='proton', proton_profiler_dir='/tmp/p', proton_data='trace', proton_output_format='chrome_trace')
Defensive patterns
Strategy: validation
Validate before calling
def validate_proton_output(data: str, fmt: str | None) -> None:
if fmt == "chrome_trace" and data != "trace":
raise SystemExit("proton_output_format='chrome_trace' requires proton_data='trace'") Prevention
- Pair (data, format) explicitly: ('trace','chrome_trace') or ('tree','hatchet'|'hatchet_msgpack').
When it happens
Trigger: Passing --profiler-config profiler=proton,proton_output_format=chrome_trace with proton_data left at its default 'tree' (or explicitly 'tree').
Common situations: Users wanting Chrome-trace output without realizing the data mode must change to 'trace'; copying output-format options from a profiling script that assumed trace data.
Related errors
- {options} only applicable when profiler is set to 'proton'
- proton_profiler_dir must be set when profiler is 'proton'
- proton_profiler_dir must be a local directory
- {output_format} output requires proton_data='tree'
- Unable to use nsight profiling unless workers run with Ray.
AI-assisted analysis of vllm-project/vllm@c794754062 (2026-08-14).
Data as JSON: /api/errors/6a78626076a1c126.
Report an issue: GitHub.