Skip to content

Latest commit

 

History

History
61 lines (37 loc) · 1.73 KB

File metadata and controls

61 lines (37 loc) · 1.73 KB

Compiling the dependencies

We're using pip-tools to manage our dependencies.

Notes

  • So the main dependencies are in requirements.in
  • The dev dependencies are in dev-requirements.in . Please note that this file starts with -c requirements.txt This tells pip-compile to take into consideration the requirements from that file when compiling the dev dependencies
  • IMPORTANT ! The owner of the project folder needs to be the same as the user that runs the pip-compile and pip-sync commands. Otherwise you can get RemoteNotFoundError errors when pip tries to use vcs (git).

Compilation steps

  1. Make sure to have pip-tools installed, at least version 5.5.0 for python2 and 6.6.0 for python3:
    • FOR PYTHON 2:

      pip install pip-tools==5.5.0
      
    • FOR PYTHON 3:

      pip install pip-tools==6.10.0
      
      #for python 3.10
      pip install pip-tools==7.3.0
      
  2. Compile the main dependencies:

    • FOR PYTHON 2:

      pip-compile requirements-py2.in --output-file=requirements-py2.txt
      
    • FOR PYTHON 3:

      pip-compile requirements.in --output-file=requirements.txt
      
  3. Compile the dev dependencies:

    • FOR PYTHON 2:

      pip-compile dev-requirements-py2.in --output-file=dev-requirements-py2.txt
      
    • FOR PYTHON 3:

      pip-compile dev-requirements.in --output-file=dev-requirements.txt
      
  4. Make sure your python environment has the correct libraries installed. Notice that we're using the dev-requirements-local.txt file here:

    • FOR PYTHON 2:

      pip-sync requirements-py2.txt dev-requirements-py2.txt
      
    • FOR PYTHON 3:

      pip-sync requirements.txt dev-requirements.txt