0

Im using python 3.7 Im new to python (my main dev experience comes from javascript). I understand there is a Pipfile who specify the packages Im using directly . Additionally, there is a Pipfile.lock which specifies exact versions of direct and indirect dependencies (like yarn\package.lock in js ). requirements.txt looks like its doing the exact same thing .

Which ones should I track ? Thanks

yoty66
  • 390
  • 2
  • 12

1 Answers1

0

Pipfile (and Pipfile.lock) are specific to pipenv, which is a relatively new tool. Whether you maintain requirements.txt depends on whether you want people using your repository to be able to use pip directly, rather than using pipenv themselves

In general, you should keep both Pipfile and Pipfile.lock under source control. Pipfile.lock is what specifies exactly what packages should be installed in the pipenv-managed virtual environment for reproducible builds. Pipfile is mostly a convenience for generating Pipfile.lock.

chepner
  • 497,756
  • 71
  • 530
  • 681