Issue with libraries with hyphens "-" in the name
Author: Abhishek0075Created Jun 23, 2025Updated Jun 3, 2026
I have a project with "cv2" and "scikit-learn" but when i used the command
pipreqs . --force --mode no-pin
It was giving the requirements.txt as
noise numpy opencv_python Pillow scikit_learn scipy skimage torch torchvision tqdm
As you can see the opencv-python is written as opencv_python (which is in correct manner "opencv-python") and more of the bad one is "skimage" which is really "scikit-image".
If I am doing something wrong please guide me.
Source: bndr/pipreqs