最新消息:雨落星辰是一个专注网站SEO优化、网站SEO诊断、搜索引擎研究、网络营销推广、网站策划运营及站长类的自媒体原创博客

python - Build a monorepo with UV and common packages - Stack Overflow

programmeradmin0浏览0评论

I am building a monorepo that manages multiple projects with independent requirements. I am using UV to manage libraries in a monorepo and using databricks asset bundle to deploy the projects as workflows. This is the folder structure:

datalab/
│── databricks_init_script.sh
│── databricks.yml
│── databricks_init_script.sh
│── projects
│   └── project1
│       ├── pyproject.toml
│       ├── notebooks
│       └── src
│──shared
│   ├── pyproject.toml
│   ├── src/
│   └── <other necessary files>

In the toml file within each project I'm including the shared modules requirements with

dependencies = [
  "data-lab-shared"
]
[tool.uv.sources]
data-lab-shared = {path = "../../shared"}

And in the toml file in the shared folder I'm including this build-system

[build-system]
requires = ["hatchling"]
build-backend = "hatchling.build"

In the init script I am build a wheel file and install the packages using uv build and pip install the wheel file.

The problem is that the packages specified in the shared folder are not being installed. What would be a correct way to make sure that these packages are installed?

发布评论

评论列表(0)

  1. 暂无评论