Repository navigation
[Bugfix] Fix fully sharded LoRA bug - #10352
Conversation
Signed-off-by: Jee Jee Li <pandaleefree@gmail.com>
|
👋 Hi! Thank you for contributing to the vLLM project. Once the PR is approved and ready to go, your PR reviewer(s) can run CI to test the changes comprehensively before merging. To run CI, PR reviewers can do one of these:
🚀 |
|
Can we add a test to avoid similar regressions? |
I've been thinking about this. |
Signed-off-by: Jee Jee Li <pandaleefree@gmail.com>
|
We can add some LoRA tests to distributed tests. |
I'll do that, but it will probably take some time. Regarding this bug, my local testing shows no issues, including cases where |
DarkLight1337
left a comment
There was a problem hiding this comment.
Alright, let's try to get this into the upcoming release first.
Signed-off-by: Jee Jee Li <pandaleefree@gmail.com>
Signed-off-by: Jee Jee Li <pandaleefree@gmail.com>
Signed-off-by: Jee Jee Li <pandaleefree@gmail.com>
Signed-off-by: Jee Jee Li <pandaleefree@gmail.com>
…oject#10352) ### What this PR does / why we need it? This PR fixes `tests/ut/attention/a2/test_sfa_v1.py` by explicitly mocking `get_ascend_config()` in `TestAscendSFAMetadataBuilder`. - https://github.com/vllm-project/vllm-ascend/actions/runs/27336219650/job/80761760016#step:13:229 Fix bug in vllm-ascend PR vllm-project#10292: That PR added a new `AscendConfig` field: ```python self.c8_enable_reshape_optim = ... ``` and introduced this access in `vllm_ascend/attention/sfa_v1.py`: ```python if get_ascend_config().c8_enable_reshape_optim: ``` However, `tests/ut/attention/a2/test_sfa_v1.py` directly constructs `AscendSFAMetadataBuilder` and calls `build()` / `build_for_graph_capture()` without initializing or mocking `AscendConfig`. As a result, the tests can fail with: ```text RuntimeError: Ascend config is not initialized. Please call init_ascend_config first. ``` This is a UT isolation issue. The SFA metadata builder tests should not depend on process-global Ascend platform initialization side effects. This PR fixes the tests by mocking: ```python vllm_ascend.attention.sfa_v1.get_ascend_config ``` and setting the fields required by the SFA path, including: ```python c8_enable_reshape_optim = False ``` This keeps the test focused on SFA metadata builder behavior and avoids relying on global `AscendConfig` state. - vLLM version: v0.21.0 - vLLM main: vllm-project@9090368 --------- Signed-off-by: MrZ20 <2609716663@qq.com>
FIX #10342 (link existing issues this PR will resolve)
The issue arose because the code did not properly handle cases where all three lora_a
in
MergedQKVParallelLinearWithShardedLoracould be None. I also handled this issue inMergedColumnParallelLinearWithShardedLoRA.BTW, fix small typo in
worker.pyping @DarkLight1337 also cc @xyang16 Thanks for catch this bug