Skip to content

Conversation

@plusNew001
Copy link
Collaborator

Motivation

💡 If this PR is a Cherry Pick, the PR title needs to follow the format by adding the [Cherry-Pick] label at the very beginning and appending the original PR ID at the end. For example, [Cherry-Pick][CI] Add check trigger and logic(#5191)

💡 如若此PR是Cherry Pick,PR标题需遵循格式,在最开始加上[Cherry-Pick]标签,以及最后面加上原PR ID,例如[Cherry-Pick][CI] Add check trigger and logic(#5191)

Modifications

Usage or Command

Accuracy Tests

Checklist

  • Add at least a tag in the PR title.
    • Tag list: [[FDConfig],[APIServer],[Engine], [Scheduler], [PD Disaggregation], [Executor], [Graph Optimization], [Speculative Decoding], [RL], [Models], [Quantization], [Loader], [OP], [KVCache], [DataProcessor], [BugFix], [Docs], [CI], [Optimization], [Feature], [Benchmark], [Others], [XPU], [HPU], [GCU], [DCU], [Iluvatar], [Metax]]
    • You can add new tags based on the PR content, but the semantics must be clear.
  • Format your code, run pre-commit before commit.
  • Add unit tests. Please write the reason in this PR if no unit tests.
  • Provide accuracy results.
  • If the current PR is submitting to the release branch, make sure the PR has been submitted to the develop branch, then cherry-pick it to the release branch with the [Cherry-Pick] PR tag.

Copilot AI review requested due to automatic review settings January 7, 2026 12:00
@paddle-bot
Copy link

paddle-bot bot commented Jan 7, 2026

Thanks for your contribution!

@paddle-bot paddle-bot bot added the contributor External developers label Jan 7, 2026
Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull request overview

本PR对XPU CI测试框架进行了重大重构,主要变更包括:

目的: 重构XPU CI流程,将原有的单一工作流拆分为模块化的可复用工作流,并新增大量测试用例。

主要改动:

  • 将CI工作流拆分为clone、build、4卡测试和8卡测试四个独立的可复用工作流
  • 新增pytest测试框架,包含4卡和8卡两套完整的测试用例
  • 添加conftest.py提供通用的测试辅助函数
  • 新增多种场景的测试用例:PD分离、EP并行、MTP模式、VL模型、logprobs等

Reviewed changes

Copilot reviewed 5 out of 18 changed files in this pull request and generated 7 comments.

Show a summary per file
File Description
.github/workflows/ci_xpu.yml 重构主工作流,改为编排调用子工作流,实现模块化CI流程
.github/workflows/_build_xpu.yml 新增XPU构建工作流,负责编译和上传wheel包
.github/workflows/_xpu_4cards_case_test.yml 新增4卡测试工作流,在XPU-P800-4Cards runner上执行测试
.github/workflows/_xpu_8cards_case_test.yml 新增8卡测试工作流,在XPU-P800-8Cards runner上执行测试
tests/xpu_ci/4cards_cases/conftest.py 新增4卡测试通用配置,提供进程管理、健康检查等辅助函数
tests/xpu_ci/8cards_cases/conftest.py 新增8卡测试通用配置,与4卡版本基本相同
tests/xpu_ci/4cards_cases/test_*.py 新增10个4卡测试用例,覆盖V1模式、W4A8量化、VL模型、MTP、EP并行、PD分离、logprobs等场景
tests/xpu_ci/8cards_cases/test_*.py 新增2个8卡测试用例,测试PD分离的TP4EP4和TP1EP4配置

'
- name: Package Upload
id: set_output
env:
Copy link

Copilot AI Jan 7, 2026

Choose a reason for hiding this comment

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

语法错误:YAML文件中 env: 关键字后缺少值。第166行只有 env: 而没有定义任何环境变量,这会导致YAML解析错误。如果不需要环境变量,应该删除这一行;如果需要,应该添加相应的变量定义。

Suggested change
env:

Copilot uses AI. Check for mistakes.
Comment on lines 158 to 163
bash custom_ops/xpu_ops/download_dependencies.sh develop
export CLANG_PATH=$(pwd)/custom_ops/xpu_ops/third_party/xtdk
export XVLLM_PATH=$(pwd)/custom_ops/xpu_ops/third_party/xvllm
bash build.sh
ls ./dist/*.whl
'
Copy link

Copilot AI Jan 7, 2026

Choose a reason for hiding this comment

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

代码块结束位置缺少右引号。第159行之后的bash脚本应该有对应的闭合引号 ',但是直接跳到了第163行。这会导致shell脚本执行错误。

Copilot uses AI. Check for mistakes.
@@ -1,86 +1,43 @@
name: CI_XPU

name: CI-XPU
Copy link

Copilot AI Jan 7, 2026

Choose a reason for hiding this comment

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

PR描述信息不完整。根据项目规范,PR描述至少应该解释为什么要进行这些修改以及解决了什么问题。建议补充以下内容:

  1. 重构的背景和动机
  2. 主要改进点(例如:将单个工作流拆分为多个可复用的工作流、增加了测试用例等)
  3. 对CI流程的影响
  4. 测试验证情况

Copilot generated this review using guidance from repository custom instructions.
python ${push_file} fastdeploy*.whl ${target_path}
target_path_stripped="${target_path#paddle-github-action/}"
WHEEL_PATH=https://paddle-github-action.bj.bcebos.com/${target_path_stripped}/${fd_wheel_name}
echo "wheel_path=${WHEEL_PATH}" >> $GITHUB_OUTPUT No newline at end of file
Copy link

Copilot AI Jan 7, 2026

Choose a reason for hiding this comment

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

缺少环境变量 GITHUB_OUTPUT 的存在性检查。如果在本地或非GitHub Actions环境中运行此脚本,$GITHUB_OUTPUT 可能未定义,导致脚本失败。建议添加环境变量检查或使用更健壮的输出方式。

Suggested change
echo "wheel_path=${WHEEL_PATH}" >> $GITHUB_OUTPUT
if [ -n "${GITHUB_OUTPUT:-}" ]; then
echo "wheel_path=${WHEEL_PATH}" >> "$GITHUB_OUTPUT"
else
# Fallback for non-GitHub Actions environments: print to stdout
echo "GITHUB_OUTPUT is not set. wheel_path=${WHEEL_PATH}"
fi

Copilot uses AI. Check for mistakes.
@@ -1,86 +1,43 @@
name: CI_XPU

name: CI-XPU
Copy link

Copilot AI Jan 7, 2026

Choose a reason for hiding this comment

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

PR标题缺少必要的标签格式。根据项目规范,PR标题应该遵循 [标签]描述 的格式。建议修改为:[XPU][CI] XPU CI Refactor,明确标注这是XPU和CI相关的改动。

Copilot generated this review using guidance from repository custom instructions.
"""
停止所有相关进程(最小改动版,避免误杀 pytest)
"""
xpu_id = get_xpu_id() # noqa: F841
Copy link

Copilot AI Jan 7, 2026

Choose a reason for hiding this comment

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

Variable xpu_id is not used.

Suggested change
xpu_id = get_xpu_id() # noqa: F841

Copilot uses AI. Check for mistakes.
# 真正 kill
for pid in safe_pids:
subprocess.run(f"kill -9 {pid}", shell=True, stdout=subprocess.DEVNULL, stderr=subprocess.DEVNULL)
except Exception:
Copy link

Copilot AI Jan 7, 2026

Choose a reason for hiding this comment

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

'except' clause does nothing but pass and there is no explanatory comment.

Copilot uses AI. Check for mistakes.
@codecov-commenter
Copy link

codecov-commenter commented Jan 7, 2026

Codecov Report

✅ All modified and coverable lines are covered by tests.
⚠️ Please upload report for BASE (develop@dc170e3). Learn more about missing BASE report.

Additional details and impacted files
@@            Coverage Diff             @@
##             develop    #5932   +/-   ##
==========================================
  Coverage           ?   67.02%           
==========================================
  Files              ?      348           
  Lines              ?    44648           
  Branches           ?     6868           
==========================================
  Hits               ?    29926           
  Misses             ?    12513           
  Partials           ?     2209           
Flag Coverage Δ
GPU 67.02% <ø> (?)

Flags with carried forward coverage won't be shown. Click here to find out more.

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

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

Labels

contributor External developers

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants