-
Notifications
You must be signed in to change notification settings - Fork 1.6k
fix: Ensure that Python stub generation works against libnvidia-ml stubs #6188
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: main
Are you sure you want to change the base?
fix: Ensure that Python stub generation works against libnvidia-ml stubs #6188
Conversation
Signed-off-by: Martin Marciniszyn Mehringer <11665257+MartinMarciniszyn@users.noreply.github.com>
WalkthroughThe Docker multi-stage build process was updated to handle the creation of a symbolic link for Changes
Suggested reviewers
Poem
📜 Recent review detailsConfiguration used: .coderabbit.yaml 📒 Files selected for processing (1)
✅ Files skipped from review due to trivial changes (1)
⏰ Context from checks skipped due to timeout of 90000ms. You can increase the timeout in your CodeRabbit configuration to a maximum of 15 minutes (900000ms). (1)
🪧 TipsChatThere are 3 ways to chat with CodeRabbit:
SupportNeed help? Create a ticket on our support page for assistance with any issues or questions. Note: Be mindful of the bot's finite context window. It's strongly recommended to break down tasks such as reading entire modules into smaller chunks. For a focused discussion, use review comments to chat about specific files and their changes, instead of using the PR comments. CodeRabbit Commands (Invoked using PR comments)
Other keywords and placeholders
Documentation and Community
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Actionable comments posted: 1
📜 Review details
Configuration used: .coderabbit.yaml
Review profile: CHILL
Plan: Pro
📒 Files selected for processing (2)
docker/Dockerfile.multi
(2 hunks)scripts/build_wheel.py
(0 hunks)
💤 Files with no reviewable changes (1)
- scripts/build_wheel.py
🔇 Additional comments (1)
docker/Dockerfile.multi (1)
73-77
: Uninstall command may miss the actual package name
opencv
is not the canonical PyPI package; the wheel in NVIDIA images is usuallyopencv-python
/opencv-python-headless
.
If the base layer was installed withopencv-python
, thepip uninstall -y opencv
line becomes a no-op and leaves the old wheel on disk, defeating the purpose of the clean re-install.Consider uninstalling all known OpenCV wheels in one shot:
-RUN pip3 uninstall -y opencv && \ +RUN pip3 uninstall -y opencv opencv-python opencv-python-headless opencv-contrib-python || true && \This will work regardless of which flavour was pre-installed.
Signed-off-by: Martin Marciniszyn Mehringer <11665257+MartinMarciniszyn@users.noreply.github.com>
/bot run --skip-test |
PR_Github #12339 [ run ] triggered by Bot |
Supersedes #5940 . |
These changes look good to me. |
PR_Github #12339 [ run ] completed with state |
if "libnvidia-ml.so" in result.stdout: | ||
line = result.stdout.splitlines()[0] | ||
path = os.path.dirname(line) | ||
new_library_path += f":{path}" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This line adds the stub lib path to LD_LIBRARY_PATH
. Removing this causes the build error. I think we need to add code like:
new_library_path += ":/usr/local/cuda/lib64/stub"
Summary by CodeRabbit