Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Issue using pip download -r requirements.txt

I have my Python script and my requirements.txt ready.

What I want to do is to get all the packages listed in the "requirements.txt" into a folder. In the bundle, I'd for example have the full packages of "pymysql", "bs4" as well as all their dependencies.

I have absolutely no idea how to do this. Could you help me please? I am stuck and I am really struggling with this.

I am using Python 3.6

I am using "pip download -r requirements.txt" but it's not downloading the dependencies and outputs me only.whl files whereas I'm looking for "proper" folders..

like image 738
sammtt Avatar asked Sep 15 '25 10:09

sammtt


1 Answers

To make pip prefer source files over wheels, use the --no-binary flag:

pip download -r requirements.txt --no-binary :all: -d /path/to/download/dir
like image 85
Phydeaux Avatar answered Sep 16 '25 23:09

Phydeaux