Skip to content

[Test] Fix UT for EPLBController - #15283

Merged
linfeng-yuan merged 1 commit into
vllm-project:mainfrom
Spicy-Stick:ut_fix
Aug 29, 2026
Merged

linfeng-yuan merged 1 commit into
vllm-project:mainfrom
Spicy-Stick:ut_fix

Conversation

@Spicy-Stick

@Spicy-Stick Spicy-Stick commented Aug 29, 2026 •

Copy link
Copy Markdown
Contributor

What this PR does / why we need it?

This PR updates the unit tests for AscendEPLBController to align with the new prepare_forward interface instead of the deprecated step method. This ensures that the unit tests correctly verify the load collection phase filtering and step recording behavior.

Does this PR introduce any user-facing change?

No.

How was this patch tested?

The patch itself consists of unit test updates. The updated unit tests in tests/ut/worker/v2/test_eplb_controller.py were executed and passed.

Signed-off-by: Spicy-Stick <873805887@qq.com>
@gemini-code-assist

Copy link
Copy Markdown
Contributor

Summary of Changes

Hello, I'm Gemini Code Assist1! I'm currently reviewing this pull request and will post my feedback shortly. In the meantime, here's a summary to help you and other reviewers quickly get up to speed!

This pull request updates the unit tests for the EPLBController to reflect recent changes in the controller's internal API. The tests now correctly validate the behavior of the prepare_forward method, ensuring that state recording and phase handling are functioning as expected under various conditions.

Highlights

  • Unit Test Refactoring: Updated unit tests for EPLBController to align with the new prepare_forward method signature and logic.
  • Test Coverage: Replaced legacy step-based tests with specific test cases for prepare_forward, covering matching phases, non-matching phases, and closed window scenarios.
New Features

🧠 You can now enable Memory (public preview) to help Gemini Code Assist learn from your team's feedback. This makes future code reviews more consistent and personalized to your project's style. Click here to enable Memory in your admin console.

Using Gemini Code Assist

The full guide for Gemini Code Assist can be found on our documentation page, here are some quick tips.

Invoking Gemini

You can request assistance from Gemini at any point by creating a comment using either /gemini <command> or @gemini-code-assist <command>. Below is a summary of the supported commands on the current page.

Feature Command Description
Code Review /gemini review Performs a code review for the current pull request in its current state.
Pull Request Summary /gemini summary Provides a summary of the current pull request in its current state.
Comment @gemini-code-assist Responds in comments when explicitly tagged, both in pull request comments and review comments.
Help /gemini help Displays a list of available commands.

Customization

To customize the Gemini Code Assist for GitHub experience, repository maintainers can create a configuration file and/or provide a custom code review style guide (such as PEP-8 for Python) by creating and adding files to a .gemini/ folder in the base of the repository. Detailed instructions can be found here.

Limitations & Feedback

Gemini Code Assist may make mistakes. Please leave feedback on any instances where its feedback is incorrect or counterproductive. You can react with 👍 and 👎 on @gemini-code-assist comments. If you're interested in giving your feedback about your experience with Gemini Code Assist for GitHub and other Google products, sign up here.

Footnotes

  1. Review the Privacy Notices, Generative AI Prohibited Use Policy, Terms of Service, and learn how to configure Gemini Code Assist in GitHub here. Gemini can make mistakes, so double check it and use code with caution. ↩

@github-actions

Copy link
Copy Markdown
Contributor

👋 Hi! Thank you for contributing to the vLLM Ascend project. The following points will speed up your PR merge:‌‌

  • A PR should do only one thing, smaller PRs enable faster reviews.
  • Every PR should include unit tests and end-to-end tests ‌to ensure it works and is not broken by other future PRs.
  • Write the commit message by fulfilling the PR description to help reviewer and future developers understand.

If CI fails, you can run linting and testing checks locally according Contributing and Testing.

@gemini-code-assist gemini-code-assist Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Code Review

This pull request updates the unit tests in tests/ut/worker/v2/test_eplb_controller.py to test the new prepare_forward interface instead of the deprecated step method. The reviewer feedback suggests updating the PR title and summary to comply with the repository's style guide format.

)

def test_nonmatching_phase_is_forwarded_as_dummy(self):
def test_prepare_forward_records_matching_phase(self):

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

high

According to the repository style guide, the PR title and summary should follow a specific format. Here are the suggested PR title and summary based on the style guide:

Suggested PR Title:

[Test][BugFix] Fix UT for EPLBController

Suggested PR Summary:

### What this PR does / why we need it?

This PR updates the unit tests for `AscendEPLBController` to align with the new `prepare_forward` interface instead of the deprecated `step` method. This ensures that the unit tests correctly verify the load collection phase filtering and step recording behavior.

### Does this PR introduce _any_ user-facing change?

No.

### How was this patch tested?

The patch itself consists of unit test updates. The updated unit tests in `tests/ut/worker/v2/test_eplb_controller.py` were executed and passed.
References
  1. The PR title and summary should follow the specified format in the repository style guide, including the [Branch][Module][Action] prefix for the title and the standard sections for the summary. (link)

@Angazenn Angazenn added the ready-precise run selected e2e test for pr label Aug 29, 2026
@linfeng-yuan
linfeng-yuan merged commit f1ab204 into vllm-project:main Aug 29, 2026
21 of 22 checks passed
@AuroraEmiya

Copy link
Copy Markdown
Contributor

#15278

zhao-stack pushed a commit to LQDLove/vllm-ascend that referenced this pull request Aug 29, 2026
Restore pr_test.yaml exactly to upstream/main now that the main2main compatibility failures are resolved. The EPLB baseline test fix landed through vllm-ascend PR vllm-project#15283 (commit f1ab204).

Signed-off-by: shenzhao <shenzhao9@huawei.com>
zhao-stack pushed a commit to LQDLove/vllm-ascend that referenced this pull request Aug 31, 2026
Restore pr_test.yaml exactly to upstream/main now that the main2main compatibility failures are resolved. The EPLB baseline test fix landed through vllm-ascend PR vllm-project#15283 (commit f1ab204).

Signed-off-by: shenzhao <shenzhao9@huawei.com>
zhao-stack pushed a commit to LQDLove/vllm-ascend that referenced this pull request Aug 31, 2026
Restore pr_test.yaml exactly to upstream/main now that the main2main compatibility failures are resolved. The EPLB baseline test fix landed through vllm-ascend PR vllm-project#15283 (commit f1ab204).

Signed-off-by: shenzhao <shenzhao9@huawei.com>
zhao-stack pushed a commit to LQDLove/vllm-ascend that referenced this pull request Aug 31, 2026
Restore pr_test.yaml exactly to upstream/main now that the main2main compatibility failures are resolved. The EPLB baseline test fix landed through vllm-ascend PR vllm-project#15283 (commit f1ab204).

Signed-off-by: shenzhao <shenzhao9@huawei.com>
LQDLove pushed a commit to LQDLove/vllm-ascend that referenced this pull request Aug 31, 2026
Restore pr_test.yaml exactly to upstream/main now that the main2main compatibility failures are resolved. The EPLB baseline test fix landed through vllm-ascend PR vllm-project#15283 (commit f1ab204).

Signed-off-by: shenzhao <shenzhao9@huawei.com>
zhao-stack pushed a commit to LQDLove/vllm-ascend that referenced this pull request Aug 31, 2026
Restore pr_test.yaml exactly to upstream/main now that the main2main compatibility failures are resolved. The EPLB baseline test fix landed through vllm-ascend PR vllm-project#15283 (commit f1ab204).

Signed-off-by: shenzhao <shenzhao9@huawei.com>
LQDLove pushed a commit to LQDLove/vllm-ascend that referenced this pull request Aug 31, 2026
Restore pr_test.yaml exactly to upstream/main now that the main2main compatibility failures are resolved. The EPLB baseline test fix landed through vllm-ascend PR vllm-project#15283 (commit f1ab204).

Signed-off-by: shenzhao <shenzhao9@huawei.com>
LQDLove pushed a commit to LQDLove/vllm-ascend that referenced this pull request Aug 31, 2026
Restore pr_test.yaml exactly to upstream/main now that the main2main compatibility failures are resolved. The EPLB baseline test fix landed through vllm-ascend PR vllm-project#15283 (commit f1ab204).

Signed-off-by: shenzhao <shenzhao9@huawei.com>
LQDLove pushed a commit to LQDLove/vllm-ascend that referenced this pull request Sep 1, 2026
Restore pr_test.yaml exactly to upstream/main now that the main2main compatibility failures are resolved. The EPLB baseline test fix landed through vllm-ascend PR vllm-project#15283 (commit f1ab204).

Signed-off-by: shenzhao <shenzhao9@huawei.com>
LQDLove pushed a commit to LQDLove/vllm-ascend that referenced this pull request Sep 1, 2026
Restore pr_test.yaml exactly to upstream/main now that the main2main compatibility failures are resolved. The EPLB baseline test fix landed through vllm-ascend PR vllm-project#15283 (commit f1ab204).

Signed-off-by: shenzhao <shenzhao9@huawei.com>
LQDLove pushed a commit to LQDLove/vllm-ascend that referenced this pull request Sep 1, 2026
Restore pr_test.yaml exactly to upstream/main now that the main2main compatibility failures are resolved. The EPLB baseline test fix landed through vllm-ascend PR vllm-project#15283 (commit f1ab204).

Signed-off-by: shenzhao <shenzhao9@huawei.com>
LQDLove pushed a commit to LQDLove/vllm-ascend that referenced this pull request Sep 1, 2026
Restore pr_test.yaml exactly to upstream/main now that the main2main compatibility failures are resolved. The EPLB baseline test fix landed through vllm-ascend PR vllm-project#15283 (commit f1ab204).

Signed-off-by: shenzhao <shenzhao9@huawei.com>
LQDLove pushed a commit to LQDLove/vllm-ascend that referenced this pull request Sep 1, 2026
Restore pr_test.yaml exactly to upstream/main now that the main2main compatibility failures are resolved. The EPLB baseline test fix landed through vllm-ascend PR vllm-project#15283 (commit f1ab204).

Signed-off-by: shenzhao <shenzhao9@huawei.com>
LQDLove pushed a commit to LQDLove/vllm-ascend that referenced this pull request Sep 1, 2026
Restore pr_test.yaml exactly to upstream/main now that the main2main compatibility failures are resolved. The EPLB baseline test fix landed through vllm-ascend PR vllm-project#15283 (commit f1ab204).

Signed-off-by: shenzhao <shenzhao9@huawei.com>
LQDLove pushed a commit to LQDLove/vllm-ascend that referenced this pull request Sep 2, 2026
Restore pr_test.yaml exactly to upstream/main now that the main2main compatibility failures are resolved. The EPLB baseline test fix landed through vllm-ascend PR vllm-project#15283 (commit f1ab204).

Signed-off-by: shenzhao <shenzhao9@huawei.com>
zhao-stack pushed a commit to zhao-stack/vllm-ascend that referenced this pull request Sep 2, 2026
Restore pr_test.yaml exactly to upstream/main now that the main2main compatibility failures are resolved. The EPLB baseline test fix landed through vllm-ascend PR vllm-project#15283 (commit f1ab204).

Signed-off-by: shenzhao <shenzhao9@huawei.com>
zhao-stack pushed a commit to zhao-stack/vllm-ascend that referenced this pull request Sep 2, 2026
Restore pr_test.yaml exactly to upstream/main now that the main2main compatibility failures are resolved. The EPLB baseline test fix landed through vllm-ascend PR vllm-project#15283 (commit f1ab204).

Signed-off-by: shenzhao <shenzhao9@huawei.com>
LQDLove pushed a commit to LQDLove/vllm-ascend that referenced this pull request Sep 2, 2026
Restore pr_test.yaml exactly to upstream/main now that the main2main compatibility failures are resolved. The EPLB baseline test fix landed through vllm-ascend PR vllm-project#15283 (commit f1ab204).

Signed-off-by: shenzhao <shenzhao9@huawei.com>
zhao-stack pushed a commit to LQDLove/vllm-ascend that referenced this pull request Sep 2, 2026
Restore pr_test.yaml exactly to upstream/main now that the main2main compatibility failures are resolved. The EPLB baseline test fix landed through vllm-ascend PR vllm-project#15283 (commit f1ab204).

Signed-off-by: shenzhao <shenzhao9@huawei.com>
zhao-stack pushed a commit to zhao-stack/vllm-ascend that referenced this pull request Sep 2, 2026
Restore pr_test.yaml exactly to upstream/main now that the main2main compatibility failures are resolved. The EPLB baseline test fix landed through vllm-ascend PR vllm-project#15283 (commit f1ab204).

Signed-off-by: shenzhao <shenzhao9@huawei.com>
zhao-stack pushed a commit to LQDLove/vllm-ascend that referenced this pull request Sep 2, 2026
Restore pr_test.yaml exactly to upstream/main now that the main2main compatibility failures are resolved. The EPLB baseline test fix landed through vllm-ascend PR vllm-project#15283 (commit f1ab204).

Signed-off-by: shenzhao <shenzhao9@huawei.com>
zhao-stack pushed a commit to zhao-stack/vllm-ascend that referenced this pull request Sep 2, 2026
Restore pr_test.yaml exactly to upstream/main now that the main2main compatibility failures are resolved. The EPLB baseline test fix landed through vllm-ascend PR vllm-project#15283 (commit f1ab204).

Signed-off-by: shenzhao <shenzhao9@huawei.com>
zhao-stack pushed a commit to zhao-stack/vllm-ascend that referenced this pull request Sep 2, 2026
Restore pr_test.yaml exactly to upstream/main now that the main2main compatibility failures are resolved. The EPLB baseline test fix landed through vllm-ascend PR vllm-project#15283 (commit f1ab204).

Signed-off-by: shenzhao <shenzhao9@huawei.com>
zhao-stack pushed a commit to zhao-stack/vllm-ascend that referenced this pull request Sep 2, 2026
Restore pr_test.yaml exactly to upstream/main now that the main2main compatibility failures are resolved. The EPLB baseline test fix landed through vllm-ascend PR vllm-project#15283 (commit f1ab204).

Signed-off-by: shenzhao <shenzhao9@huawei.com>
zhao-stack pushed a commit to zhao-stack/vllm-ascend that referenced this pull request Sep 3, 2026
Restore pr_test.yaml exactly to upstream/main now that the main2main compatibility failures are resolved. The EPLB baseline test fix landed through vllm-ascend PR vllm-project#15283 (commit f1ab204).

Signed-off-by: shenzhao <shenzhao9@huawei.com>
zhao-stack pushed a commit to zhao-stack/vllm-ascend that referenced this pull request Sep 3, 2026
Restore pr_test.yaml exactly to upstream/main now that the main2main compatibility failures are resolved. The EPLB baseline test fix landed through vllm-ascend PR vllm-project#15283 (commit f1ab204).

Signed-off-by: shenzhao <shenzhao9@huawei.com>
zhao-stack pushed a commit to zhao-stack/vllm-ascend that referenced this pull request Sep 3, 2026
Restore pr_test.yaml exactly to upstream/main now that the main2main compatibility failures are resolved. The EPLB baseline test fix landed through vllm-ascend PR vllm-project#15283 (commit f1ab204).

Signed-off-by: shenzhao <shenzhao9@huawei.com>
zhao-stack pushed a commit to zhao-stack/vllm-ascend that referenced this pull request Sep 3, 2026
Restore pr_test.yaml exactly to upstream/main now that the main2main compatibility failures are resolved. The EPLB baseline test fix landed through vllm-ascend PR vllm-project#15283 (commit f1ab204).

Signed-off-by: shenzhao <shenzhao9@huawei.com>
LQDLove pushed a commit to LQDLove/vllm-ascend that referenced this pull request Sep 3, 2026
Restore pr_test.yaml exactly to upstream/main now that the main2main compatibility failures are resolved. The EPLB baseline test fix landed through vllm-ascend PR vllm-project#15283 (commit f1ab204).

Signed-off-by: shenzhao <shenzhao9@huawei.com>
zhao-stack pushed a commit to zhao-stack/vllm-ascend that referenced this pull request Sep 3, 2026
Restore pr_test.yaml exactly to upstream/main now that the main2main compatibility failures are resolved. The EPLB baseline test fix landed through vllm-ascend PR vllm-project#15283 (commit f1ab204).

Signed-off-by: shenzhao <shenzhao9@huawei.com>
zhao-stack pushed a commit to zhao-stack/vllm-ascend that referenced this pull request Sep 3, 2026
Restore pr_test.yaml exactly to upstream/main now that the main2main compatibility failures are resolved. The EPLB baseline test fix landed through vllm-ascend PR vllm-project#15283 (commit f1ab204).

Signed-off-by: shenzhao <shenzhao9@huawei.com>
zhao-stack pushed a commit to zhao-stack/vllm-ascend that referenced this pull request Sep 3, 2026
Restore pr_test.yaml exactly to upstream/main now that the main2main compatibility failures are resolved. The EPLB baseline test fix landed through vllm-ascend PR vllm-project#15283 (commit f1ab204).

Signed-off-by: shenzhao <shenzhao9@huawei.com>
zhao-stack pushed a commit to zhao-stack/vllm-ascend that referenced this pull request Sep 3, 2026
Restore pr_test.yaml exactly to upstream/main now that the main2main compatibility failures are resolved. The EPLB baseline test fix landed through vllm-ascend PR vllm-project#15283 (commit f1ab204).

Signed-off-by: shenzhao <shenzhao9@huawei.com>
zhao-stack pushed a commit to zhao-stack/vllm-ascend that referenced this pull request Sep 3, 2026
Restore pr_test.yaml exactly to upstream/main now that the main2main compatibility failures are resolved. The EPLB baseline test fix landed through vllm-ascend PR vllm-project#15283 (commit f1ab204).

Signed-off-by: shenzhao <shenzhao9@huawei.com>
zhao-stack pushed a commit to zhao-stack/vllm-ascend that referenced this pull request Sep 3, 2026
Restore pr_test.yaml exactly to upstream/main now that the main2main compatibility failures are resolved. The EPLB baseline test fix landed through vllm-ascend PR vllm-project#15283 (commit f1ab204).

Signed-off-by: shenzhao <shenzhao9@huawei.com>
LQDLove pushed a commit to LQDLove/vllm-ascend that referenced this pull request Sep 3, 2026
Restore pr_test.yaml exactly to upstream/main now that the main2main compatibility failures are resolved. The EPLB baseline test fix landed through vllm-ascend PR vllm-project#15283 (commit f1ab204).

Signed-off-by: shenzhao <shenzhao9@huawei.com>
LQDLove pushed a commit to LQDLove/vllm-ascend that referenced this pull request Sep 4, 2026
Restore pr_test.yaml exactly to upstream/main now that the main2main compatibility failures are resolved. The EPLB baseline test fix landed through vllm-ascend PR vllm-project#15283 (commit f1ab204).

Signed-off-by: shenzhao <shenzhao9@huawei.com>
LQDLove pushed a commit to LQDLove/vllm-ascend that referenced this pull request Sep 4, 2026
Restore pr_test.yaml exactly to upstream/main now that the main2main compatibility failures are resolved. The EPLB baseline test fix landed through vllm-ascend PR vllm-project#15283 (commit f1ab204).

Signed-off-by: shenzhao <shenzhao9@huawei.com>
zhao-stack pushed a commit to zhao-stack/vllm-ascend that referenced this pull request Sep 4, 2026
Restore pr_test.yaml exactly to upstream/main now that the main2main compatibility failures are resolved. The EPLB baseline test fix landed through vllm-ascend PR vllm-project#15283 (commit f1ab204).

Signed-off-by: shenzhao <shenzhao9@huawei.com>
LQDLove pushed a commit to LQDLove/vllm-ascend that referenced this pull request Sep 4, 2026
Restore pr_test.yaml exactly to upstream/main now that the main2main compatibility failures are resolved. The EPLB baseline test fix landed through vllm-ascend PR vllm-project#15283 (commit f1ab204).

Signed-off-by: shenzhao <shenzhao9@huawei.com>
LQDLove pushed a commit to LQDLove/vllm-ascend that referenced this pull request Sep 4, 2026
Restore pr_test.yaml exactly to upstream/main now that the main2main compatibility failures are resolved. The EPLB baseline test fix landed through vllm-ascend PR vllm-project#15283 (commit f1ab204).

Signed-off-by: shenzhao <shenzhao9@huawei.com>
Lethobenthos20 pushed a commit to Lethobenthos20/vllm-ascend that referenced this pull request Sep 4, 2026
### What this PR does / why we need it?

This PR updates the unit tests for `AscendEPLBController` to align with
the new `prepare_forward` interface instead of the deprecated `step`
method. This ensures that the unit tests correctly verify the load
collection phase filtering and step recording behavior.

### Does this PR introduce _any_ user-facing change?

No.

### How was this patch tested?

The patch itself consists of unit test updates. The updated unit tests
in `tests/ut/worker/v2/test_eplb_controller.py` were executed and
passed.

- vLLM main:
vllm-project/vllm@ba07e4a

Signed-off-by: Spicy-Stick <873805887@qq.com>
LQDLove pushed a commit to LQDLove/vllm-ascend that referenced this pull request Sep 4, 2026
Restore pr_test.yaml exactly to upstream/main now that the main2main compatibility failures are resolved. The EPLB baseline test fix landed through vllm-ascend PR vllm-project#15283 (commit f1ab204).

Signed-off-by: shenzhao <shenzhao9@huawei.com>
LQDLove pushed a commit to LQDLove/vllm-ascend that referenced this pull request Sep 4, 2026
Restore pr_test.yaml exactly to upstream/main now that the main2main compatibility failures are resolved. The EPLB baseline test fix landed through vllm-ascend PR vllm-project#15283 (commit f1ab204).

Signed-off-by: shenzhao <shenzhao9@huawei.com>
LQDLove pushed a commit to LQDLove/vllm-ascend that referenced this pull request Sep 5, 2026
Restore pr_test.yaml exactly to upstream/main now that the main2main compatibility failures are resolved. The EPLB baseline test fix landed through vllm-ascend PR vllm-project#15283 (commit f1ab204).

Signed-off-by: shenzhao <shenzhao9@huawei.com>
LQDLove pushed a commit to LQDLove/vllm-ascend that referenced this pull request Sep 5, 2026
Restore pr_test.yaml exactly to upstream/main now that the main2main compatibility failures are resolved. The EPLB baseline test fix landed through vllm-ascend PR vllm-project#15283 (commit f1ab204).

Signed-off-by: shenzhao <shenzhao9@huawei.com>
LQDLove pushed a commit to LQDLove/vllm-ascend that referenced this pull request Sep 5, 2026
Restore pr_test.yaml exactly to upstream/main now that the main2main compatibility failures are resolved. The EPLB baseline test fix landed through vllm-ascend PR vllm-project#15283 (commit f1ab204).

Signed-off-by: shenzhao <shenzhao9@huawei.com>
LQDLove pushed a commit to LQDLove/vllm-ascend that referenced this pull request Sep 6, 2026
Restore pr_test.yaml exactly to upstream/main now that the main2main compatibility failures are resolved. The EPLB baseline test fix landed through vllm-ascend PR vllm-project#15283 (commit f1ab204).

Signed-off-by: shenzhao <shenzhao9@huawei.com>
LQDLove pushed a commit to LQDLove/vllm-ascend that referenced this pull request Sep 7, 2026
Restore pr_test.yaml exactly to upstream/main now that the main2main compatibility failures are resolved. The EPLB baseline test fix landed through vllm-ascend PR vllm-project#15283 (commit f1ab204).

Signed-off-by: shenzhao <shenzhao9@huawei.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

module:tests ready-precise run selected e2e test for pr

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants