mwilliamson / python-vendorize

Vendorize packages from PyPI
BSD 2-Clause "Simplified" License
95 stars 12 forks source link

Vendorize subdependency #17

Open abitrolly opened 2 years ago

abitrolly commented 2 years ago

I need to vendorize this dependency.

target = "vendor"
packages = [
  "sqlalchemy-schemadisplay @ https://github.com/fschulze/sqlalchemy_schemadisplay/archive/7c35dd35f07e55b2ed3880d62fcb4507152b7ac7.zip"
]

The problem is that it needs pydot, which I would have to install it separately. I am curious if it is possible to vendorize such subdependencies, so that my project could be run completely from local dir?

mwilliamson commented 1 year ago

If memory serves, you should be able to add pydot to the list of packages, and it will be vendorized with imports in other vendorized packages being rewritten accordingly.

pombredanne commented 1 year ago

it has been my understanding too. I guess the doc still needs to be written?

charbelmarche33 commented 3 weeks ago

Per this thread, I added dependencies of my project's required packages to the list of packages. However, I noticed when I do this it creates sibling directories with the vendorized packages. This is giving me issues because the packages are doing imports above the top level of their package structure ImportError: attempted relative import beyond top-level package. Is there an intended way to work around this? Or am I doing something wrong with the way I am adding my packages' dependencies?