cancel
Showing results for 
Search instead for 
Did you mean: 
Data Engineering
Join discussions on data engineering best practices, architectures, and optimization strategies within the Databricks Community. Exchange insights and solutions with fellow data engineers.
cancel
Showing results for 
Search instead for 
Did you mean: 

Cannot run another notebook from same directory

fix_databricks
New Contributor II

Hello, I am having a similar problem from this thread which was never resolved: https://community.databricks.com/t5/data-engineering/unexpected-error-while-calling-notebook-string-...

 

I renamed a notebook (utility_data_wrangling) which I am using in my current notebook. When I do 

%run "./utility_metrics" (a different notebook), it runs fine. But when I run 
%run "./utility_data_wrangling" it gives me the error:

Failed to parse %run command: string matching regex `\$[\w_]+' expected but `%' found. If notebook path contains spaces, wrap with double quotes. Stacktrace: /Shared/Inbound Forecasting/testing_error: python

This seems to break something fundamentally because now %run "./utility_metrics" will give the same error even when commenting out %run "./utility_data_wrangling"
2 REPLIES 2

feiyun0112
Honored Contributor

The error message indicates that the notebook name contains special characters, please modify the notebook name to contain only English letters, and remove double quotation marks

%run ./utility123

 

It has no special characters, like I mentioned it's just utility_data_wrangling. It does not work with or without the double quotation marks.

Connect with Databricks Users in Your Area

Join a Regional User Group to connect with local Databricks users. Events will be happening in your city, and you won’t want to miss the chance to attend and share knowledge.

If there isn’t a group near you, start one and help create a community that brings people together.

Request a New Group