Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions examples/YOLOv8-Action-Recognition/requirements.txt
Original file line number Diff line number Diff line change
Expand Up @@ -2,3 +2,4 @@

ultralytics
transformers
zipp>=3.19.1 # not directly required, pinned by Snyk to avoid a vulnerability

Choose a reason for hiding this comment

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

medium

Pinning zipp here is a good immediate fix for the security vulnerability. However, this manual addition of a transitive dependency highlights a larger issue with this requirements.txt file. As the Snyk warning in the PR description shows, many dependencies (like numpy, torch, scipy) are missing from this list. This can lead to non-reproducible builds and makes dependency management difficult.

For more robust dependency management, I recommend using a tool like pip-tools to generate a fully-pinned requirements.txt from a requirements.in file. This ensures that all direct and transitive dependencies are explicitly listed and version-locked, which improves build reproducibility and simplifies security patching.

A requirements.in file would look like this:

# requirements.in
ultralytics
transformers
# Add other direct dependencies like torch, opencv-python here

Then, running pip-compile requirements.in would generate a complete requirements.txt.

Loading