Skip to content

Conversation

@Hz188
Copy link
Contributor

@Hz188 Hz188 commented Dec 30, 2025

PR Category

Communication Library

PR Types

New features

Description

Now dist.all_gather supports 0-size tensor, not raise a bug.
pcard-73145

@paddle-bot
Copy link

paddle-bot bot commented Dec 30, 2025

你的PR提交成功,感谢你对开源项目的贡献!
请关注后续CI自动化测试结果,详情请参考Paddle-CI手册
Your PR has been submitted. Thanks for your contribution!
Please wait for the result of CI firstly. See Paddle CI Manual for details.

@Hz188
Copy link
Contributor Author

Hz188 commented Dec 31, 2025

/re-run all-failed

def all_gather_object(
object_list: list[_T], obj: _T, group: Group = None
) -> None:
def all_gather_object(object_list: list, obj, group: Group = None) -> None:
Copy link
Member

Choose a reason for hiding this comment

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

怎么能直接删掉类型呢?公开 API 必须添加类型

>>> dist.init_parallel_env()
>>> object_list = [] # type: ignore
>>> object_list = [None for _ in dist.get_world_size()] # type: ignore
Copy link
Member

Choose a reason for hiding this comment

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

Suggested change
>>> object_list = [None for _ in dist.get_world_size()] # type: ignore
>>> object_list = [None for _ in range(dist.get_world_size())] # type: ignore

明显的错误,类型提示都检查出来了

@SigureMo
Copy link
Member

改好了

SigureMo
SigureMo previously approved these changes Jan 1, 2026
@codecov-commenter
Copy link

Codecov Report

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

Additional details and impacted files
@@             Coverage Diff             @@
##             develop    #77152   +/-   ##
===========================================
  Coverage           ?   100.00%           
===========================================
  Files              ?         2           
  Lines              ?        14           
  Branches           ?         0           
===========================================
  Hits               ?        14           
  Misses             ?         0           
  Partials           ?         0           

☔ 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.

@Hz188
Copy link
Contributor Author

Hz188 commented Jan 4, 2026

/re-run all-failed

Copy link
Member

@ForFishes ForFishes left a comment

Choose a reason for hiding this comment

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

LGTM

@ForFishes ForFishes merged commit 76860dc into PaddlePaddle:develop Jan 5, 2026
117 of 123 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants