vllm-project/vllm · error · ValueError
custom_ops must contain exactly one base mode: 'all' or 'non
Error message
custom_ops must contain exactly one base mode: 'all' or 'none'
What it means
Error "custom_ops must contain exactly one base mode: 'all' or 'none'" thrown in vllm-project/vllm.
Source
Thrown at vllm/config/compilation.py:1360
"doesn't exist (or wasn't imported/registered)"
if op_name not in op_registry
else "not present in model"
)
enable_str = "enabling" if op[0] == "+" else "disabling"
logger.warning_once(
"Op '%s' %s, %s with '%s' has no effect",
op_name,
missing_str,
enable_str,
op,
)
def is_custom_op_enabled(self, op: str) -> bool:
count_all = self.custom_ops.count("all")
count_none = self.custom_ops.count("none")
if count_all + count_none != 1:
raise ValueError(
"custom_ops must contain exactly one base mode: 'all' or 'none'"
)
if count_all:
return f"-{op}" not in self.custom_ops
return f"+{op}" in self.custom_ops
def resolve_cudagraph_mode_and_sizes(
self,
min_cg_support: "AttentionCGSupport",
min_cg_attn_backend: str | None,
uniform_decode_query_len: int = 1,
use_v2_model_runner: bool = False,
tensor_parallel_size: int = 1,
kv_cache_config: "KVCacheConfig | None" = None,
max_num_reqs: int | None = None,
is_profiling: bool = False,View on GitHub (pinned to c794754062)
Solutions
- Include exactly one base mode in custom_ops: 'all' or 'none'.
- Example: --compilation-config '{"custom_ops":["all","-silu_and_mul"]}'.
When it happens
Trigger: Raised at vllm/config/compilation.py:1360 when validation fails: custom_ops must contain exactly one base mode: 'all' or 'none'. Typically triggered by an incompatible or incomplete vLLM configuration, an unsupported platform/backend combination, or a runtime resource/dependency that is missing.
Common situations: Commonly encountered at vllm/config/compilation.py:1360 during vLLM startup/config validation or runtime setup when: (1) conflicting CLI flags or config fields are combined, (2) the current platform (CUDA/ROCm/CPU/XPU) or installed optional packages do not support the requested feature, or (3) a required value is absent or out of range. Resolve by correcting the configuration as described in the message, or by selecting a supported alternative.
AI-assisted analysis of vllm-project/vllm@c794754062 (2026-08-14).
Data as JSON: /api/errors/9411f959a68bd3b1.
Report an issue: GitHub.