Skip to content

[Bugfix][Core] Accept needs_kv_cache_zeroing in SinkFullAttentionManager - #59512

Draft
ivanium wants to merge 1 commit into
vllm-project:mainfrom
ivanium:fix/sink-full-attn-manager-kwargs
Draft

ivanium wants to merge 1 commit into
vllm-project:mainfrom
ivanium:fix/sink-full-attn-manager-kwargs

Conversation

@ivanium

@ivanium ivanium commented Sep 30, 2026

Copy link
Copy Markdown
Contributor

Purpose

Since #44490 the KV cache coordinator passes needs_kv_cache_zeroing to every single-type manager, but SinkFullAttentionManager still spelled out its parent's old __init__ signature. Any model using SinkFullAttentionSpec (openPangu with StaticSinkAttention) fails at KV cache manager init with TypeError: SinkFullAttentionManager.__init__() got an unexpected keyword argument 'needs_kv_cache_zeroing', whether or not zeroing is enabled.

This forwards **kwargs to the parent, matching the other manager subclasses (RSWA, SWA, chunked-local, Mamba, HiSparse), and adds a regression test that constructs the manager with needs_kv_cache_zeroing=True and checks its new blocks are recorded for zeroing.

Not a duplicate: no open PR touches this constructor (searched SinkFullAttentionManager and needs_kv_cache_zeroing; #47271 and #43374 modify nearby sink code but not this).

Test Plan

pytest tests/v1/core/test_single_type_kv_cache_manager.py tests/v1/test_kv_cache_spec_registry.py

Test Result

The new test fails on main with the TypeError above and passes with the fix; both files pass (81 passed). No model eval: the change only fixes a startup crash and does not affect outputs of models that already started.

AI assistance (Claude Code) was used; I reviewed every changed line and ran the tests above.

🤖 Generated with Claude Code

The coordinator passes needs_kv_cache_zeroing to every single-type manager
since vllm-project#44490, but SinkFullAttentionManager spelled out its parent's old
signature and raised TypeError at startup for models using
StaticSinkAttention (openPangu). Forward kwargs like the other managers.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Signed-off-by: Yifan Qiao <yifanqiao@inferact.ai>
@mergify mergify Bot added bug Something isn't working kv-cache-manager labels Sep 30, 2026
@ivanium

ivanium commented Sep 30, 2026

Copy link
Copy Markdown
Contributor Author

This is not a urgent PR and I don't have a plan to merge it soon. Just wanted to leave it here so people and agents can refer to this if see any issues with SinkFullAttentionManager

This branch has not been deployed

No deployments
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

bug Something isn't working kv-cache-manager

1 participant