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

Reply
chulpanvl
Helper I
Helper I

Power Bi Service Error - Failed to update data source credentials: ADO.NET: python.exe not found

Hello everyone!

I am trying to schedule a refresh using Power BI Service for my dataset that contains Python script which is:

import pandas as pd

data = [['Alex',10],['Bob',12],['Clarke',13]]

df = pd.DataFrame(data,columns=['Name','Age'],dtype=float)

print (df)

I have a On-premises data gateway (personal mode) installed.

 

So far I’ve tried:

  1. To run a python script via anaconda virtual environment. This gives me an error (Importing the numpy C-extensions failed) even on PBI Desktop level.
  2. I tried creating virtual env with an older version of python (3.6), no luck, same error.
  3. I gave up on Anaconda and tried using default python env. I’ve changed a Python home directory (which is C:\Users\chz.vladimirova\AppData\Local\Programs\Python\Python310\) in Options and Settings in PBI Desktop accordingly. Script worked fine on PBI Desktop but data failed to refresh at PBI Service. For some reason PowerBI Service was still referring to Anaconda environment and was returning the same error message about numpy ImportError as earlier. Here is a community post addressing the same issue, there is no solution however.
  4. I uninstalled Anaconda from my computer. Now PBI Service doesn’t refer to anaconda env but returns an error: Failed to update data source credentials: ADO.NET: python.exe not found. python.exe was not found in the specified directory. Please make sure you have a complete Python installation.
  5. I tried using an older version of On-premises data gateway (personal mode) - from March 2020. Problem remains.

chulpanvl_0-1643725101343.png

Privacy level of a source is set to Public both in PBI Service and PBI Desktop.

 

Python version: Python 3.10.2

Windows version: 21H1 Windows 10 Pro, Build 19043.1110

PBI Desktop version: 2.100.1401.0 64-bit

 

I am really confused. Any help is appreciated!

6 REPLIES 6
rmsl
Frequent Visitor

@chulpanvl Have you managed to find a way around it by any chance? I am having the exact same issue.

chulpanvl
Helper I
Helper I

@v-janeyg-msft 

Are you using a normal python environment - Yes, I uninstalled Anaconda and now using just a normal python env.

and using an older version of python - Yes, I uninstalled 3.10 and reinstalled 3.7.7.

Does it refresh properly on the desktop - Yes, it doesn't throw any error messages.

 

In case If this info can help

My Python path

chulpanvl_0-1645769409014.png

 

Data source settings 

chulpanvl_1-1645769454808.png

And a personal gateway seems to work properly

Снимок экрана 2022-02-25 в 09.23.35.png

 

 

@chulpanvl 

 

If there is no problem now, you can mark the reply that is helpful to you and close this thread. Thank you.

 

Best Regards,
Community Support Team _ Janey

 

 

v-janeyg-msft
Community Support
Community Support

Hi, @chulpanvl 

 

Not sure if the latest version of python is supported according to the doc. 

vjaneygmsft_0-1643941213964.png

More details:

Learn which Python packages are supported - Power BI | Microsoft Docs

Create Power BI visuals using Python in Power BI Desktop - Power BI | Microsoft Docs

It is recommended to use an older version of python, and powerbi desktop and gateway can be downloaded the latest version normally. 

I suggest you open the data source settings in desktop and delete the previous credentials and update it. Delete the original report in the service and re-publieh the report.

vjaneygmsft_2-1643941596307.png

 

vjaneygmsft_1-1643941583900.png

You can create a simple sample file to see if there is a problem.

Did I answer your question? Please mark my reply as solution. Thank you very much.
If not, please feel free to ask me.

Best Regards,
Community Support Team _ Janey

Hi @v-janeyg-msft , unfortunately this didn't help((

@chulpanvl 

 

Are you using a normal python environment and using an older version of python? Does it refresh properly on the desktop? If not, please show a screenshot of the error message.

 

Janey

 

Helpful resources

Announcements
Fabric Community Conference

Microsoft Fabric Community Conference

Join us at our first-ever Microsoft Fabric Community Conference, March 26-28, 2024 in Las Vegas with 100+ sessions by community experts and Microsoft engineering.

February 2024 Update Carousel

Power BI Monthly Update - February 2024

Check out the February 2024 Power BI update to learn about new features.

Fabric Career Hub

Microsoft Fabric Career Hub

Explore career paths and learn resources in Fabric.

Fabric Partner Community

Microsoft Fabric Partner Community

Engage with the Fabric engineering team, hear of product updates, business opportunities, and resources in the Fabric Partner Community.

Top Solution Authors
Top Kudoed Authors