<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Manage Project Dependencies with pyproject.toml in Data Engineering</title>
    <link>https://community.databricks.com/t5/data-engineering/manage-project-dependencies-with-pyproject-toml/m-p/178072#M57473</link>
    <description>&lt;DIV class=""&gt;&lt;DIV class=""&gt;&lt;DIV class=""&gt;&lt;DIV class=""&gt;&lt;P&gt;Dear Community!&lt;/P&gt;&lt;P&gt;I want to work in a serverless environment. I tried this &lt;A href="https://docs.databricks.com/aws/en/dev-tools/bundles/library-dependencies#uv-and-pyprojecttoml" target="_blank" rel="nofollow noopener noreferrer"&gt;code&lt;/A&gt; here a couple of weeks:&lt;/P&gt;&lt;PRE&gt;resources:
  pipelines:
    test_uv_etl:
      name: test_uv_etl
      catalog: ${var.catalog}
      schema: ${var.schema}
      serverless: true
      root_path: '../src/test_uv_etl'

      libraries:
        - glob:
            include: ../src/test_uv_etl/transformations/**

      environment:
        dependencies:
          - --editable ${workspace.file_path}&lt;/PRE&gt;&lt;P&gt;I really like it: it simply installs all libraries defined in the pyproject.toml. On top, it builds a wheel for the package specified in the pyproject.toml. &lt;EM&gt;I assume, that this also works for jobs.&lt;/EM&gt;&lt;/P&gt;&lt;P&gt;Now, I saw this pretty &lt;A href="https://docs.databricks.com/aws/en/compute/serverless/notebooks/shared-serverless#manage-the-environment-with-pyprojecttoml" target="_blank" rel="nofollow noopener noreferrer"&gt;new docu&lt;/A&gt; about serverless folders&lt;/P&gt;&lt;P&gt;Here the following code snippet is suggested:&lt;/P&gt;&lt;PRE&gt;resources:
  jobs:
    my_project_job:
      name: my-project-job
      environments:
        - environment_key: project
          spec:
            project_environment: ../pyproject.toml
      tasks:
        - task_key: main
          environment_key: project
          spark_python_task:
            python_file: ../src/main.py&lt;/PRE&gt;&lt;P&gt;&lt;EM&gt;I assume, that this also works for pipelines.&lt;/EM&gt;&lt;/P&gt;&lt;P&gt;Pretty similar, but still not clear for me:&lt;/P&gt;&lt;UL&gt;&lt;LI&gt;With --editable I shouldn't have any issues with cache. When I refer to the project environment directly as it is done in the second snippet: is it also cache-safe?&lt;/LI&gt;&lt;LI&gt;The first snippet also triggers a build (e.g. via hatchling): is that also trigger in the second option?&lt;/LI&gt;&lt;LI&gt;Finally: are the two approaches at the end the same? If not: what is the difference (I know that shared serverless is for the whole bundle, I mean difference in processing the pyproject.toml)?&lt;/LI&gt;&lt;/UL&gt;&lt;/DIV&gt;&lt;/DIV&gt;&lt;DIV class=""&gt;&amp;nbsp;&lt;/DIV&gt;&lt;DIV class=""&gt;&lt;A class="" href="https://community.databricks.com/t5/data-engineering/pyproject-toml-driven-environment-management/td-p/177839#" target="_blank" rel="noopener"&gt;Add Products&lt;/A&gt;&lt;/DIV&gt;&lt;DIV class=""&gt;&lt;DIV class=""&gt;&lt;UL class=""&gt;&lt;LI&gt;Labels:&lt;/LI&gt;&lt;LI&gt;&lt;A class="" href="https://community.databricks.com/t5/forums/filteredbylabelpage/board-id/data-engineering/label-name/workflows" target="_blank" rel="noopener"&gt;Workflows&lt;/A&gt;&lt;/LI&gt;&lt;/UL&gt;&lt;/DIV&gt;&lt;/DIV&gt;&lt;DIV class=""&gt;&lt;A class="" href="https://community.databricks.com/t5/data-engineering/pyproject-toml-driven-environment-management/td-p/177839#" target="_blank" rel="noopener" aria-label="Add Tag..."&gt;Add tags&lt;/A&gt;&lt;/DIV&gt;&lt;/DIV&gt;&lt;/DIV&gt;</description>
    <pubDate>Sun, 29 Nov 2026 17:08:36 GMT</pubDate>
    <dc:creator>a_user12</dc:creator>
    <dc:date>2026-11-29T17:08:36Z</dc:date>
    <item>
      <title>Manage Project Dependencies with pyproject.toml</title>
      <link>https://community.databricks.com/t5/data-engineering/manage-project-dependencies-with-pyproject-toml/m-p/178072#M57473</link>
      <description>&lt;DIV class=""&gt;&lt;DIV class=""&gt;&lt;DIV class=""&gt;&lt;DIV class=""&gt;&lt;P&gt;Dear Community!&lt;/P&gt;&lt;P&gt;I want to work in a serverless environment. I tried this &lt;A href="https://docs.databricks.com/aws/en/dev-tools/bundles/library-dependencies#uv-and-pyprojecttoml" target="_blank" rel="nofollow noopener noreferrer"&gt;code&lt;/A&gt; here a couple of weeks:&lt;/P&gt;&lt;PRE&gt;resources:
  pipelines:
    test_uv_etl:
      name: test_uv_etl
      catalog: ${var.catalog}
      schema: ${var.schema}
      serverless: true
      root_path: '../src/test_uv_etl'

      libraries:
        - glob:
            include: ../src/test_uv_etl/transformations/**

      environment:
        dependencies:
          - --editable ${workspace.file_path}&lt;/PRE&gt;&lt;P&gt;I really like it: it simply installs all libraries defined in the pyproject.toml. On top, it builds a wheel for the package specified in the pyproject.toml. &lt;EM&gt;I assume, that this also works for jobs.&lt;/EM&gt;&lt;/P&gt;&lt;P&gt;Now, I saw this pretty &lt;A href="https://docs.databricks.com/aws/en/compute/serverless/notebooks/shared-serverless#manage-the-environment-with-pyprojecttoml" target="_blank" rel="nofollow noopener noreferrer"&gt;new docu&lt;/A&gt; about serverless folders&lt;/P&gt;&lt;P&gt;Here the following code snippet is suggested:&lt;/P&gt;&lt;PRE&gt;resources:
  jobs:
    my_project_job:
      name: my-project-job
      environments:
        - environment_key: project
          spec:
            project_environment: ../pyproject.toml
      tasks:
        - task_key: main
          environment_key: project
          spark_python_task:
            python_file: ../src/main.py&lt;/PRE&gt;&lt;P&gt;&lt;EM&gt;I assume, that this also works for pipelines.&lt;/EM&gt;&lt;/P&gt;&lt;P&gt;Pretty similar, but still not clear for me:&lt;/P&gt;&lt;UL&gt;&lt;LI&gt;With --editable I shouldn't have any issues with cache. When I refer to the project environment directly as it is done in the second snippet: is it also cache-safe?&lt;/LI&gt;&lt;LI&gt;The first snippet also triggers a build (e.g. via hatchling): is that also trigger in the second option?&lt;/LI&gt;&lt;LI&gt;Finally: are the two approaches at the end the same? If not: what is the difference (I know that shared serverless is for the whole bundle, I mean difference in processing the pyproject.toml)?&lt;/LI&gt;&lt;/UL&gt;&lt;/DIV&gt;&lt;/DIV&gt;&lt;DIV class=""&gt;&amp;nbsp;&lt;/DIV&gt;&lt;DIV class=""&gt;&lt;A class="" href="https://community.databricks.com/t5/data-engineering/pyproject-toml-driven-environment-management/td-p/177839#" target="_blank" rel="noopener"&gt;Add Products&lt;/A&gt;&lt;/DIV&gt;&lt;DIV class=""&gt;&lt;DIV class=""&gt;&lt;UL class=""&gt;&lt;LI&gt;Labels:&lt;/LI&gt;&lt;LI&gt;&lt;A class="" href="https://community.databricks.com/t5/forums/filteredbylabelpage/board-id/data-engineering/label-name/workflows" target="_blank" rel="noopener"&gt;Workflows&lt;/A&gt;&lt;/LI&gt;&lt;/UL&gt;&lt;/DIV&gt;&lt;/DIV&gt;&lt;DIV class=""&gt;&lt;A class="" href="https://community.databricks.com/t5/data-engineering/pyproject-toml-driven-environment-management/td-p/177839#" target="_blank" rel="noopener" aria-label="Add Tag..."&gt;Add tags&lt;/A&gt;&lt;/DIV&gt;&lt;/DIV&gt;&lt;/DIV&gt;</description>
      <pubDate>Sun, 29 Nov 2026 17:08:36 GMT</pubDate>
      <guid>https://community.databricks.com/t5/data-engineering/manage-project-dependencies-with-pyproject-toml/m-p/178072#M57473</guid>
      <dc:creator>a_user12</dc:creator>
      <dc:date>2026-11-29T17:08:36Z</dc:date>
    </item>
  </channel>
</rss>

