Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 

The ultimate Microsoft Fabric, Power BI, Azure AI & SQL learning event! Join us in Las Vegas from March 26-28, 2024. Use code MSCUST for a $100 discount. Register Now

Python error when creating new Dataflow

Created a python script which executes fine in Power BI desktop.  The script exports a table called output which I then format.  I want to make the dataset available to others in my work group and so am attempting to create a new dataflow starting with a blank query.  I coppied and pasted the contents of my desktop files advanced editor into the blank query and recieved the following error that comes up at the 'Run Python script' step.

 

"We encountered an error during evaluation. Details: Expression.Error: The import Python.Execute matches no exports. Did you miss a module reference?"

 

I updated my power bi desktop version and re-tried with the same result.  I've coppied and pasted as plain text with the same result.  Is this a bug similar to the one when R script was originally released or is there something I can do to fix this error and get the same output as in my desktop file?

Status: Needs Info
Comments
v-qiuyu-msft
Community Support

Hi @Anonymous, 

 

Would you please share the pbix file with some dummy data with us? 

You can upload the pbix file to your OneDrive and paste the share link here. 

 

Best Regards,
Qiuyun Yu 

v-qiuyu-msft
Community Support
Status changed to: Needs Info
 
Anonymous
Not applicable

Hey @v-qiuyu-msft ,

 

Below is a link to my onedrive folder:

https://tsocorp-my.sharepoint.com/:o:/g/personal/w388900_andeavor_com/Ek0EGysLJvtBv4CW3vUYW5QB9DdRNV...

 

It is in the folder labeled PowerBI File

v-qiuyu-msft
Community Support

Hi @Anonymous, 

 

I don't have permission to access the URL. If the report doesn't contains sensitive data, you can share the file with anyone, then pastes the share link here. 

 

Best Regards,

Qiuyun Yu 

Anonymous
Not applicable

Hey @v-qiuyu-msft ,

 

My IT department has those sharing options locked down for anyone external to our company.  Could you please provide a way for me to contact you directly?

 

V/R,

-Alex

v-qiuyu-msft
Community Support

Hi @Anonymous, 

 

You can create a support ticket to let engineers look into the issue on your side directly. 

 

Support Ticket.gif

 

Best Regards,

Qiuyun Yu 

Anonymous
Not applicable

That is similar to the error that Power BI Service returns when you attempt to execute an R script in the query editor without the use of a personal data gateway to provide the R environment.  

Do you need to install a personal gateway?

See the accepted solution on this page: https://community.powerbi.com/t5/Service/Python-in-Power-Bi-Service/td-p/556628