Repository navigation
Remove stale host device names from dpctl.__all__ - #2410
Merged
Merged
Conversation
select_host_device and has_host_device were removed together with the host device, but stayed in dpctl.__all__, so `from dpctl import *` raised AttributeError. Add a test that the star import resolves every name in __all__.
antonwolfy
requested review from
ndgrigorian and
vlad-perevezentsev
as code owners
November 3, 2026 17:24
|
Deleted rendered PR docs from intelpython.github.com/dpctl, latest should be updated shortly. 🤞 |
Collaborator
There was a problem hiding this comment.
🟢 Approval recommended
No active review issues are recorded for the change removing obsolete host-device exports to fix star imports.
No open issues 🎉
What changed in this PR
Fixes from dpctl import * by removing obsolete host-device names from the package’s public export list.
Changes:
- Removes
select_host_deviceandhas_host_devicefromdpctl.__all__. - Adds a regression test that performs a star import and checks every declared export.
- Documents the fix in the changelog.
| File | Description |
|---|---|
dpctl/tests/test_service.py |
Adds regression coverage for star imports. |
dpctl/__init__.py |
Removes the two stale host-device exports. |
CHANGELOG.md |
Records the star-import fix. |
Review effort: Balanced
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
select_host_deviceandhas_host_devicewere removed together with the host device in cee5afe, but they stayed listed indpctl.__all__. Because of that,from dpctl import *fails:This PR drops both names and adds
test_star_import, which checks that the star import resolves every name indpctl.__all__. The test fails without the fix and passes with it (checked on an Intel Arc B390 GPU).