<?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 setup databricks connect on VsCode and PyCharm in Data Engineering</title>
    <link>https://community.databricks.com/t5/data-engineering/setup-databricks-connect-on-vscode-and-pycharm/m-p/141159#M51637</link>
    <description>&lt;P&gt;Hello Guyz,&lt;BR /&gt;&lt;BR /&gt;Someone Know what's is the best pratices to setup databricks connect for Pycharm and VsCode using Docker, Justfile and .env file&amp;nbsp;&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;Cordially,&amp;nbsp;&lt;BR /&gt;Seefoods&lt;/P&gt;</description>
    <pubDate>Thu, 04 Dec 2025 13:20:08 GMT</pubDate>
    <dc:creator>seefoods</dc:creator>
    <dc:date>2025-12-04T13:20:08Z</dc:date>
    <item>
      <title>setup databricks connect on VsCode and PyCharm</title>
      <link>https://community.databricks.com/t5/data-engineering/setup-databricks-connect-on-vscode-and-pycharm/m-p/141159#M51637</link>
      <description>&lt;P&gt;Hello Guyz,&lt;BR /&gt;&lt;BR /&gt;Someone Know what's is the best pratices to setup databricks connect for Pycharm and VsCode using Docker, Justfile and .env file&amp;nbsp;&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;Cordially,&amp;nbsp;&lt;BR /&gt;Seefoods&lt;/P&gt;</description>
      <pubDate>Thu, 04 Dec 2025 13:20:08 GMT</pubDate>
      <guid>https://community.databricks.com/t5/data-engineering/setup-databricks-connect-on-vscode-and-pycharm/m-p/141159#M51637</guid>
      <dc:creator>seefoods</dc:creator>
      <dc:date>2025-12-04T13:20:08Z</dc:date>
    </item>
    <item>
      <title>Re: setup databricks connect on VsCode and PyCharm</title>
      <link>https://community.databricks.com/t5/data-engineering/setup-databricks-connect-on-vscode-and-pycharm/m-p/141350#M51703</link>
      <description>&lt;P&gt;Hi&amp;nbsp;&lt;a href="https://community.databricks.com/t5/user/viewprofilepage/user-id/65591"&gt;@seefoods&lt;/a&gt;!&lt;/P&gt;&lt;P&gt;&lt;FONT size="3"&gt;I’ve worked with Databricks Connect and VSCode in different projects, and although your question mentions Docker, Justfile and .env, the “best practices” really depend on what you’re trying to do.&amp;nbsp;&lt;FONT size="3"&gt;Here’s what has worked best for me:&lt;/FONT&gt;&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;U&gt;&lt;FONT size="3"&gt;&lt;STRONG&gt;1.- Databricks Connect → for local development inside VSCode&lt;/STRONG&gt;&lt;/FONT&gt;&lt;/U&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT size="3"&gt;I mainly use Databricks Connect to:&lt;/FONT&gt;&lt;/P&gt;&lt;UL&gt;&lt;LI&gt;&lt;FONT size="3"&gt;run Spark code locally&lt;/FONT&gt;&lt;/LI&gt;&lt;LI&gt;&lt;FONT size="3"&gt;get autocompletion and type hints&lt;/FONT&gt;&lt;/LI&gt;&lt;LI&gt;&lt;FONT size="3"&gt;debug transformations&lt;/FONT&gt;&lt;/LI&gt;&lt;LI&gt;quickly test code before sending it to a Databricks cluster&lt;/LI&gt;&lt;/UL&gt;&lt;P&gt;&lt;FONT size="3"&gt;It’s perfect for the development loop inside VSCode.&lt;/FONT&gt;&lt;/P&gt;&lt;H1&gt;&lt;U&gt;&lt;FONT size="3"&gt;&lt;STRONG&gt;2.- Databricks VSCode extension → for running real workloads on Databricks&lt;/STRONG&gt;&lt;/FONT&gt;&lt;/U&gt;&lt;/H1&gt;&lt;P&gt;&lt;FONT size="3"&gt;For me, this is the cleanest workflow when you want to run things on the platform:&lt;/FONT&gt;&lt;/P&gt;&lt;UL&gt;&lt;LI&gt;&lt;FONT size="3"&gt;run scripts/notebooks on a cluster&lt;/FONT&gt;&lt;/LI&gt;&lt;LI&gt;&lt;FONT size="3"&gt;browse catalogs, tables, repos&lt;/FONT&gt;&lt;/LI&gt;&lt;LI&gt;&lt;FONT size="3"&gt;switch profiles&lt;/FONT&gt;&lt;/LI&gt;&lt;LI&gt;see job logs and outputs&lt;/LI&gt;&lt;/UL&gt;&lt;P&gt;&lt;FONT size="3"&gt;So the combination works really well:&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT size="3"&gt;&lt;STRONG&gt;Databricks Connect → local dev experience&lt;/STRONG&gt;&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT size="3"&gt;&lt;FONT size="3"&gt;&lt;STRONG&gt;VSCode extension → execute remotely on Databricks&lt;/STRONG&gt;&lt;/FONT&gt;&lt;/FONT&gt;&lt;/P&gt;&lt;H1&gt;&lt;U&gt;&lt;FONT size="3"&gt;&lt;STRONG&gt;3.- Use .databrickscfg for VSCode authentication&lt;/STRONG&gt;&lt;/FONT&gt;&lt;/U&gt;&lt;/H1&gt;&lt;P&gt;&lt;U&gt;&lt;FONT size="3"&gt;&lt;A href="https://docs.databricks.com/aws/en/dev-tools/vscode-ext/" target="_self"&gt;What is the Databricks extension for Visual Studio Code?&lt;/A&gt;&lt;/FONT&gt;&lt;/U&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT size="3"&gt;The Databricks VSCode extension expects credentials in:&amp;nbsp;&lt;FONT size="3"&gt;~/.databrickscfg&lt;/FONT&gt;&lt;/FONT&gt;&lt;/P&gt;&lt;LI-CODE lang="markup"&gt;[DEFAULT]
host = https://&amp;lt;workspace-url&amp;gt;
token = &amp;lt;PAT&amp;gt; &lt;/LI-CODE&gt;&lt;P&gt;&lt;FONT size="3"&gt;Or multiple profiles:&lt;/FONT&gt;&lt;/P&gt;&lt;LI-CODE lang="markup"&gt;[dev] 
host = https://dev-workspace 
token = &amp;lt;token-dev&amp;gt; 

[prod] 
host = https://prod-workspace 
token = &amp;lt;token-prod&amp;gt; &lt;/LI-CODE&gt;&lt;DIV class=""&gt;&lt;DIV class=""&gt;&lt;DIV class=""&gt;&lt;DIV class=""&gt;&lt;FONT&gt;&lt;FONT&gt;VSCode reads this automatically. S&lt;FONT&gt;o for the &lt;STRONG&gt;plugin, .databrickscfg is definitely the best practice.&lt;/STRONG&gt;&lt;/FONT&gt;&lt;/FONT&gt;&lt;/FONT&gt;&lt;H1&gt;&lt;U&gt;&lt;FONT size="3"&gt;&lt;STRONG&gt;4.- When building external services (FastAPI, Uvicorn, etc.), .env &lt;EM&gt;is useful&lt;/EM&gt;&lt;/STRONG&gt;&lt;/FONT&gt;&lt;/U&gt;&lt;/H1&gt;&lt;P&gt;&lt;FONT size="3"&gt;For microservices calling Databricks Model Serving, I do use .env, for example:&lt;/FONT&gt;&lt;/P&gt;&lt;/DIV&gt;&lt;/DIV&gt;&lt;/DIV&gt;&lt;/DIV&gt;&lt;LI-CODE lang="markup"&gt;DATABRICKS_HOST=https://&amp;lt;workspace-url&amp;gt; 
DATABRICKS_TOKEN=&amp;lt;token&amp;gt; 
MODEL_SERVING_ENDPOINT=/serving-endpoints/my-model/invocations &lt;/LI-CODE&gt;&lt;DIV class=""&gt;&lt;DIV class=""&gt;&lt;DIV class=""&gt;&lt;DIV class=""&gt;&lt;EM&gt;&lt;EM&gt;&lt;SPAN&gt;Two options to load the .env&lt;SPAN&gt;:&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/EM&gt;&lt;/EM&gt;&lt;P&gt;&lt;STRONG&gt;1) Use --env-file directly with Uvicorn (supported natively).&amp;nbsp;This works perfectly inside a Justfile&lt;SPAN&gt;:&lt;/SPAN&gt;&lt;/STRONG&gt;&lt;/P&gt;&lt;/DIV&gt;&lt;/DIV&gt;&lt;/DIV&gt;&lt;/DIV&gt;&lt;LI-CODE lang="markup"&gt;run: 
  uvicorn app.main:app --host 0.0.0.0 --port 8080 --env-file .env &lt;/LI-CODE&gt;&lt;DIV class=""&gt;&lt;DIV class=""&gt;&lt;DIV class=""&gt;&lt;DIV class=""&gt;&lt;EM&gt;&lt;EM&gt;&lt;STRONG&gt;2. Load .env inside your FastAPI app&lt;/STRONG&gt;&lt;/EM&gt;&lt;/EM&gt;&lt;DIV class=""&gt;&amp;nbsp;&lt;/DIV&gt;&lt;/DIV&gt;&lt;/DIV&gt;&lt;/DIV&gt;&lt;/DIV&gt;&lt;LI-CODE lang="markup"&gt;from dotenv import load_dotenv
import os

load_dotenv()

host = os.getenv("DATABRICKS_HOST")
token = os.getenv("DATABRICKS_TOKEN")
endpoint = os.getenv("MODEL_SERVING_ENDPOINT") &lt;/LI-CODE&gt;&lt;DIV class=""&gt;&lt;DIV class=""&gt;&lt;DIV class=""&gt;&lt;DIV class=""&gt;&lt;SPAN&gt;&lt;SPAN&gt;In this case, your Justfile stays:&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV class=""&gt;&amp;nbsp;&lt;/DIV&gt;&lt;/DIV&gt;&lt;/DIV&gt;&lt;/DIV&gt;&lt;LI-CODE lang="markup"&gt;run:
  uvicorn app.main:app --host 0.0.0.0 --port 8080 &lt;/LI-CODE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;DIV class=""&gt;&lt;DIV class=""&gt;&lt;DIV class=""&gt;&lt;SPAN&gt;&lt;SPAN&gt;And your service reads the .env&lt;SPAN&gt; programmatically.&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV class=""&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;At the end of the day, both approaches are valid and in my experience, &lt;STRONG&gt;which one you use really depends on the specific use case. For local development and running things directly on Databricks, I prefer the VSCode plugin + .databrickscfg. For external services (FastAPI, Uvicorn, Justfile deployments), .env works perfectly.&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;So depending on what you want to build, you will naturally choose one approach or the other.&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;FONT size="3"&gt;Hope it helps!&amp;nbsp;&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT size="3"&gt;&lt;SPAN&gt;Gema&amp;nbsp;&lt;SPAN class="lia-unicode-emoji"&gt;&lt;SPAN class="lia-unicode-emoji"&gt;&lt;span class="lia-unicode-emoji" title=":woman_technologist:"&gt;👩‍💻&lt;/span&gt;&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/FONT&gt;&lt;/P&gt;&lt;/DIV&gt;&lt;/DIV&gt;&lt;/DIV&gt;</description>
      <pubDate>Sun, 07 Dec 2025 17:55:53 GMT</pubDate>
      <guid>https://community.databricks.com/t5/data-engineering/setup-databricks-connect-on-vscode-and-pycharm/m-p/141350#M51703</guid>
      <dc:creator>Gecofer</dc:creator>
      <dc:date>2025-12-07T17:55:53Z</dc:date>
    </item>
    <item>
      <title>Re: setup databricks connect on VsCode and PyCharm</title>
      <link>https://community.databricks.com/t5/data-engineering/setup-databricks-connect-on-vscode-and-pycharm/m-p/142092#M51883</link>
      <description>&lt;P&gt;Hello Mrs&amp;nbsp;&lt;a href="https://community.databricks.com/t5/user/viewprofilepage/user-id/135464"&gt;@Gecofer&lt;/a&gt;&amp;nbsp;,&amp;nbsp;&lt;BR /&gt;&lt;BR /&gt;Thanks for your response.&amp;nbsp;&lt;BR /&gt;&lt;BR /&gt;Cordially,&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Wed, 17 Dec 2025 14:40:15 GMT</pubDate>
      <guid>https://community.databricks.com/t5/data-engineering/setup-databricks-connect-on-vscode-and-pycharm/m-p/142092#M51883</guid>
      <dc:creator>seefoods</dc:creator>
      <dc:date>2025-12-17T14:40:15Z</dc:date>
    </item>
  </channel>
</rss>

