mirror of
https://github.com/deepseek-ai/DeepEP.git
synced 2026-11-05 00:47:32 +00:00
[PR #712] Reject NCCL runtimes older than the build #725
Labels
No labels
pull-request
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference
deepseek-ai/DeepEP#725
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
📋 Pull Request Information
Original PR: https://github.com/deepseek-ai/DeepEP/pull/712
Author: @gambletan
Created: 8/1/2026
Status: 🔄 Open
Base:
main← Head:fix/nccl-runtime-version-guard📝 Commits (4)
7c0b6c4feat: record the NCCL build version49474ccfix: reject NCCL runtimes older than the build6716e23fix: defer extension import until after NCCL checks841e4e3fix: clarify NCCL runtime guard failures📊 Changes
7 files changed (+414 additions, -6 deletions)
View changed files
📝
deep_ep/__init__.py(+18 -3)📝
deep_ep/utils/__init__.py(+11 -3)➕
deep_ep/utils/nccl.py(+40 -0)📝
setup.py(+7 -0)➕
tests/test_nccl_import_guard.py(+179 -0)➕
tests/utils/test_nccl.py(+126 -0)➕
tests/utils/test_utils_init.py(+33 -0)📄 Description
Summary
deep_ep._CEventHandleexport so_Cis not loaded before the NCCL guardWhy
When another package downgrades NCCL, the existing loaded-vs-installed binary comparison moves both sides to the downgraded library. The check therefore cannot detect that
_Cwas built against a newer NCCL Device API, and users see an opaque undefined-symbol error.Generated wheel metadata now carries
built_nccl_version. At import, DeepEP callsncclGetVersionon the mapped runtime and allows equal or newer versions. Source checkouts without generated metadata keep the existing behavior, andEP_SUPPRESS_NCCL_CHECK=1still bypasses the checks.Testing
PYTHONPYCACHEPREFIX=/tmp/deepep-pycache python3 -m pytest tests/utils/test_nccl.py tests/utils/test_utils_init.py tests/test_nccl_import_guard.py -qPYTHONPYCACHEPREFIX=/tmp/deepep-pycache python3 -m compileall -q deep_ep testsResult: 14 tests passed. These are GPU-free unit tests; no CUDA/NCCL integration run was performed.
Fixes #710
🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.