Jaa


Troubleshooting errors for Databricks Git folders

This page provides guidance for common error messages and troubleshooting issues with Databricks Git folders.

Invalid credentials

Try the following:

  • Confirm that the Git integration settings (Settings > Linked accounts) are correct. You must enter both your Git provider username and token.

  • Confirm that you selected the correct Git provider in Settings > Linked accounts.

  • Verify that your personal access token or app password has the correct repo access.

  • If your Git provider has SSO enabled, authorize your tokens for SSO.

  • Test your token with the Git command line. Replace the text strings in angle brackets:

    git clone https://<username>:<personal-access-token>@github.com/<org>/<repo-name>.git
    

Secure connection...SSL problems

This error occurs if Azure Databricks can't access your Git server. To access a private Git server, contact your Azure Databricks account team.

<link>: Secure connection to <link> could not be established because of SSL problems

Microsoft Entra ID credentials error

Encountered an error with your :re[ms-entra-id] credentials. Try logging out of :re[ms-entra-id] and logging back in.

This error can occur if your team recently started using a multi-factor authentication (MFA) policy. To resolve the error, go to portal.azure.com and log out of Microsoft Entra ID. When you log back in, you should see a prompt to use MFA.

If that doesn't work, try logging out of all Azure services before logging in again.

Timeout errors

Operations like cloning a large repository or checking out a large branch can result in timeout errors. However, the operation might complete in the background. Retry later if the workspace was under heavy load.

To work with a large repo, try sparse checkout.

404 errors

If you get a 404 error when you open a non-notebook file, wait a few minutes and try again. There's a brief delay between when the system enables the workspace and when the webapp picks up the configuration.

Detached head state

A Databricks Git folder can get into the detached head state if:

  • Someone deletes the remote branch. Databricks tries to recover uncommitted local changes by applying them to the default branch. If there are conflicting changes, Databricks applies them on a snapshot of the default branch (detached head).
  • A user or service principal checked out a tag using the update repo API.

To recover from this state:

  1. Click Create branch to create a new branch from the current commit, or Select branch to check out an existing branch.
  2. Commit and push to keep your changes. To discard changes, click the Kebab menu icon. kebab menu under Changes.

Resolve notebook name conflicts

Notebooks with identical or similar filenames can cause errors when you create a repository or pull request, such as Cannot perform Git operation due to conflicting names or A folder cannot contain a notebook with the same name as a notebook, file, or folder (excluding file extensions).

Naming conflicts can occur even with different file extensions. For example, these two files conflict:

  • notebook.ipynb
  • notebook.py

Diagram: Name conflict for notebook, file, or folder.

To fix the conflict, rename the notebook, file, or folder that's contributing to the error state. If the error occurs when you clone the repo, rename the notebooks, files, or folders in the remote Git repo.

Errors suggest recloning

There was a problem with deleting folders. The repo could be in an inconsistent state and re-cloning is recommended.

This error indicates that a problem occurred while deleting folders, which can leave the repository in an inconsistent state. Delete and re-clone the repository to reset its state.

Notebooks appear modified without user edits

If every line of a notebook appears modified without any user edits, the changes are likely due to line ending characters. Databricks uses Linux-style line endings, which can differ from files committed on Windows systems.

To diagnose this issue, check if you have a .gitattributes file. If you do:

  • It can't contain * text eol=crlf.
  • If you're not using Windows, remove this setting. Both your development environment and Databricks use Linux line endings.
  • If you're using Windows, change the setting to * text=auto. Git then stores files with Linux-style line endings internally, but checks out with platform-specific line endings automatically.

If you already committed files with Windows end-of-line characters into Git, perform the following steps:

  1. Clear any outstanding changes.
  2. Update the .gitattributes file as described above for your environment.
  3. Commit the change.
  4. Run git add --renormalize. Commit and push all changes.