Python: Multiple packages in one repository or one package per repository?

One aspect is covered here
https://pip.readthedocs.io/en/stable/reference/pip_install/#vcs-support (Updated link: https://pip.pypa.io/en/stable/topics/vcs-support/)

In particular, if setup.py is not in the root directory you have to specify the subdirectory where to find setup.py in the pip install command.

So if your repository layout is:

  • pkg_dir/
    • setup.py # setup.py for package pkg
    • some_module.py
  • other_dir/
    • some_file
    • some_other_file

You’ll need to use pip install -e vcs+protocol://repo_url/#egg=pkg&subdirectory=pkg_dir.

Leave a Comment

Hata!: SQLSTATE[HY000] [1045] Access denied for user 'divattrend_liink'@'localhost' (using password: YES)