Skip to content

Conversation

@siyengar
Copy link
Contributor

Summary:
The _load_backend function was crashing with ValueError: too many values to unpack (expected 1) when entry_points() returned multiple results for
the same backend name. This can happen when multiple packages in a test
binary register the same torchcomms backend entry point.

Changed from tuple unpacking (wheel,) = found to wheel = next(iter(found))
to gracefully handle this case by using the first matching entry point.

Fixes T253323758

Differential Revision: D91865034

Summary:
The `_load_backend` function was crashing with `ValueError: too many values
to unpack (expected 1)` when `entry_points()` returned multiple results for
the same backend name. This can happen when multiple packages in a test
binary register the same torchcomms backend entry point.

Changed from tuple unpacking `(wheel,) = found` to `wheel = next(iter(found))`
to gracefully handle this case by using the first matching entry point.

Fixes T253323758

Differential Revision: D91865034
@meta-cla meta-cla bot added the CLA Signed This label is managed by the Meta Open Source bot. label Jan 30, 2026
@meta-codesync
Copy link

meta-codesync bot commented Jan 30, 2026

@siyengar has exported this pull request. If you are a Meta employee, you can view the originating Diff in D91865034.

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

Labels

CLA Signed This label is managed by the Meta Open Source bot. fb-exported meta-exported

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant