sgl-project/sglang · error · NotImplementedError
MiniMax H3 ring parallelism requires the FlashAttention back
Error message
MiniMax H3 ring parallelism requires the FlashAttention backend (matches --ring-degree's general restriction).
What it means
MiniMax H3's attention core supports ring (sequence) parallelism only via the FlashAttention backend; when ring is active and the configured backend differs it raises NotImplementedError, mirroring the global --ring-degree restriction.
Source
Thrown at python/sglang/multimodal_gen/runtime/models/dits/minimax_h3.py:597
_usp_input_all_to_all_packed_qkv,
_usp_output_all_to_all,
)
q, k, v = _usp_input_all_to_all_packed_qkv(q, k, v)
if attention._attention_impl is None:
attention._set_attention_backend(
get_attn_backend(
attention.head_dim,
q.dtype,
attention_requirements=AttentionRequirements(packed_varlen=True),
)
)
if ring_active:
ring_ws, _ = get_ring_ctx()
if attention._attention_backend_enum is not AttentionBackendEnum.FA:
raise NotImplementedError(
"MiniMax H3 ring parallelism requires the FlashAttention "
"backend (matches --ring-degree's general restriction)."
)
# max_seqlen is cu_seqlens[1] (`used`) by construction -- the real,
# non-padding row count ring needs, already a host int here.
out = _ring_attention_varlen(
q,
k,
v,
attn_impl=attention._attention_impl,
real_seq_len=max_seqlen,
ring_ws=ring_ws,
)
else:
if (
attention._attention_backend_enum
is AttentionBackendEnum.SUBBLOCK_SPARSE_ATTN
):View on GitHub (pinned to 0132848349)
Solutions
- Set the attention backend to FA when using ring parallelism (e.g. --attention-backend fa / SGLANG_ATTN_BACKEND default) and keep --ring-degree
- Drop ring parallelism (ring-degree 1 / remove the flag) if you must use the non-FA backend
- Verify with get_ring_ctx() / server args at startup that ring and backend settings are consistent before serving
Example fix
# before python -m sglang.launch_server --model minimax-h3 --ring-degree 2 --attention-backend flashinfer # after python -m sglang.launch_server --model minimax-h3 --ring-degree 2 --attention-backend fa
Defensive patterns
Strategy: validation
Validate before calling
from sglang.srt.layers.attention import AttentionBackendEnum
assert attention_backend == AttentionBackendEnum.FA or ring_degree == 1, \
'ring parallelism requires FA backend' Prevention
- Pair --ring-degree only with the FA backend
- Fail fast at startup when ring_degree > 1 and backend != fa
- Watch release notes for backend support changes
When it happens
Trigger: Launching with --ring-degree > 1 (ring_active true) while the attention backend is set to something other than FA (e.g. FlashInfer, Triton, Torch) in server args or model runner config.
Common situations: Combining sequence parallelism with a backend chosen for other models on the same deployment; backend override flags or env vars; upgrading sglang where default backend changed away from FA.
Related errors
- MiniMax-H3 ring parallelism requires the FlashAttention back
- AITer backend does not have a metadata builder.
- AITER Sage backend does not have a metadata builder.
- {type(self).__name__} does not implement packed varlen atten
- {type(self).__name__} does not implement ring KV-chunk atten
AI-assisted analysis of sgl-project/sglang@0132848349 (2026-08-28).
Data as JSON: /api/errors/efad5183209aa635.
Report an issue: GitHub.