<?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 Service Principal cannot access its own workspace folder in Data Engineering</title>
    <link>https://community.databricks.com/t5/data-engineering/service-principal-cannot-access-its-own-workspace-folder/m-p/120584#M46196</link>
    <description>&lt;P&gt;We are using Asset bundles with databricks runtime 14.3LTS. During DAB deployment, the wheel is built and stored in the folder of the service principal running the deployment via GH workflow. The full path is&lt;BR /&gt;/Workspace/Users/SERVICE-PRINCIPAL-ID/.bundle/main_bundle/dev_dev/artifacts/.internal/WHEEL-NAME.whl&lt;/P&gt;&lt;P&gt;Within the same DAB, we define and deploy a job which uses a job cluster. when using the wheel as a task dependency we get this error&amp;nbsp;&lt;SPAN&gt;message:&amp;nbsp;&lt;/SPAN&gt;&lt;/P&gt;&lt;LI-SPOILER&gt;run failed with error message Library installation failed for library due to user error for whl: "/Workspace/Users/SERVICE-PRINCIPAL-ID/.bundle/main_bundle/dev_dev/artifacts/.internal/WHEEL-NAME.whl" Error messages: Library installation attempted on the driver node of cluster CLUSTER-ID and failed. User does not have permission to read the library file, or the file path does not exist. Error Code: FILE_NOT_FOUND_FAILURE. Error Message: java.util.concurrent.ExecutionException: java.io.FileNotFoundException: File file:/Workspace/Users/SERVICE-PRINCIPAL-ID/.bundle/main_bundle/dev_dev/artifacts/.internalWHEEL-NAMEwhl does not exist&lt;/LI-SPOILER&gt;&lt;P&gt;This was working fine a couple days before and now it is failing out of nowhere.&lt;/P&gt;</description>
    <pubDate>Thu, 29 May 2025 21:07:15 GMT</pubDate>
    <dc:creator>juan_barreto</dc:creator>
    <dc:date>2025-05-29T21:07:15Z</dc:date>
    <item>
      <title>Service Principal cannot access its own workspace folder</title>
      <link>https://community.databricks.com/t5/data-engineering/service-principal-cannot-access-its-own-workspace-folder/m-p/120584#M46196</link>
      <description>&lt;P&gt;We are using Asset bundles with databricks runtime 14.3LTS. During DAB deployment, the wheel is built and stored in the folder of the service principal running the deployment via GH workflow. The full path is&lt;BR /&gt;/Workspace/Users/SERVICE-PRINCIPAL-ID/.bundle/main_bundle/dev_dev/artifacts/.internal/WHEEL-NAME.whl&lt;/P&gt;&lt;P&gt;Within the same DAB, we define and deploy a job which uses a job cluster. when using the wheel as a task dependency we get this error&amp;nbsp;&lt;SPAN&gt;message:&amp;nbsp;&lt;/SPAN&gt;&lt;/P&gt;&lt;LI-SPOILER&gt;run failed with error message Library installation failed for library due to user error for whl: "/Workspace/Users/SERVICE-PRINCIPAL-ID/.bundle/main_bundle/dev_dev/artifacts/.internal/WHEEL-NAME.whl" Error messages: Library installation attempted on the driver node of cluster CLUSTER-ID and failed. User does not have permission to read the library file, or the file path does not exist. Error Code: FILE_NOT_FOUND_FAILURE. Error Message: java.util.concurrent.ExecutionException: java.io.FileNotFoundException: File file:/Workspace/Users/SERVICE-PRINCIPAL-ID/.bundle/main_bundle/dev_dev/artifacts/.internalWHEEL-NAMEwhl does not exist&lt;/LI-SPOILER&gt;&lt;P&gt;This was working fine a couple days before and now it is failing out of nowhere.&lt;/P&gt;</description>
      <pubDate>Thu, 29 May 2025 21:07:15 GMT</pubDate>
      <guid>https://community.databricks.com/t5/data-engineering/service-principal-cannot-access-its-own-workspace-folder/m-p/120584#M46196</guid>
      <dc:creator>juan_barreto</dc:creator>
      <dc:date>2025-05-29T21:07:15Z</dc:date>
    </item>
    <item>
      <title>Re: Service Principal cannot access its own workspace folder</title>
      <link>https://community.databricks.com/t5/data-engineering/service-principal-cannot-access-its-own-workspace-folder/m-p/120614#M46207</link>
      <description>&lt;P&gt;You're encountering a common issue when using service principals and job clusters with workspace-scoped paths. This typically happens due to&lt;BR /&gt;permission mismatches or cluster identity issues. Here’s a breakdown of the root cause and a recommended solution:&lt;/P&gt;&lt;P&gt;Root Cause:&lt;/P&gt;&lt;P&gt;When using a job cluster, the cluster runs under a different identity (not the same service principal that created the bundle).&lt;BR /&gt;If your `.whl` file is stored under:&lt;/P&gt;&lt;P&gt;/Workspace/Users/SERVICE-PRINCIPAL-ID/.bundle/...&lt;/P&gt;&lt;P&gt;&lt;BR /&gt;the job cluster **may not have permission** to access that folder. This results in:&lt;/P&gt;&lt;P&gt;--&amp;gt; Library installation failed&lt;BR /&gt;--&amp;gt; java.io.FileNotFoundException` or `Permission Denied`&lt;/P&gt;&lt;P&gt;This behavior might have changed recently due to a permission policy update or workspace changes.&lt;/P&gt;&lt;P&gt;&lt;BR /&gt;Recommended Solution:&lt;/P&gt;&lt;P&gt;1.Avoid storing `.whl` under the service principal's folder&lt;/P&gt;&lt;P&gt;Instead, store the `.whl` in a shared location accessible by all clusters. Use **DBFS** or **Workspace shared folders**, such as:&lt;/P&gt;&lt;P&gt;dbfs:/FileStore/libs/your_wheel.whl&lt;/P&gt;&lt;P&gt;Then update your job/library reference like:&lt;/P&gt;&lt;P&gt;"libraries": [&lt;BR /&gt;{&lt;BR /&gt;"whl": "dbfs:/FileStore/libs/your_wheel.whl"&lt;BR /&gt;}&lt;BR /&gt;]&lt;/P&gt;&lt;P&gt;2.Check and adjust permissions (if still using workspace path):&lt;/P&gt;&lt;P&gt;If you must use `/Workspace/...` paths:&lt;/P&gt;&lt;P&gt;--&amp;gt; Navigate to the file or folder in the Workspace UI.&lt;BR /&gt;--&amp;gt; Click “Permissions” and ensure the service principal or cluster owner has **Can Read** or **Can Manage** permissions.&lt;/P&gt;&lt;P&gt;3.Alternative Approach – Use a repo or MLflow artifacts&lt;/P&gt;&lt;P&gt;Consider storing your wheel file in:&lt;/P&gt;&lt;P&gt;--&amp;gt; A Git repo connected to Databricks Repos&lt;BR /&gt;--&amp;gt; MLflow registered models or artifacts&lt;BR /&gt;--&amp;gt; A cloud storage location (S3, ADLS, GCS) with appropriate IAM access&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Fri, 30 May 2025 13:44:46 GMT</pubDate>
      <guid>https://community.databricks.com/t5/data-engineering/service-principal-cannot-access-its-own-workspace-folder/m-p/120614#M46207</guid>
      <dc:creator>HariSankar</dc:creator>
      <dc:date>2025-05-30T13:44:46Z</dc:date>
    </item>
  </channel>
</rss>

