Power BI is turning 10, and we’re marking the occasion with a special community challenge. Use your creativity to tell a story, uncover trends, or highlight something unexpected.
Get startedJoin us for an expert-led overview of the tools and concepts you'll need to become a Certified Power BI Data Analyst and pass exam PL-300. Register now.
Hello,
We wanted to start using Python libraries in some of our dashboards. As proof of concept, I had to test if Pandas library is working.
Test #1 - Excell as source file
I used Excel as source, added some simple step at Power Query using Pandas. Everything worked on Desktop and workspace.
Test #2 - Table from Snowflake as source
Connected via connector to Snowflake, picked one table as Import and as previously did some simple changes using Pandas Library. There are also other tables in direct query mode used at this file.
It worked on desktop. But when published to Workspace errors showed up:
Not sure what should be changed or set up differently. Was reading many guides, but was not able to solve it. I know it's not Pandas / Python version issue, because excel version is working.
Thank you in advance for help.
Solved! Go to Solution.
Hi @Pawel_1990 ,
Thank you for reaching out to the Microsoft Community Forum.
Some of the issues listed below:
1. Verify Python Installation: Ensure that Python is installed on your machine and that the path to the Python executable is correctly set in the environment variables.
https://learn.microsoft.com/en-us/power-bi/connect-data/service-python-packages-support
2. Python scripts only work with personal gateways. Please refer the below thread
3. Additionally, as @Akash_Varuna suggested try running the Python transformations outside Power BI.
If my response has resolved your query, please mark it as the Accepted Solution to assist others. Additionally, a 'Kudos' would be appreciated if you found my response helpful.
Thank you
@Akash_Varuna , @v-priyankata
Thank you both for help. Had some successes, will try to summarize:
1. Switched all tables in Power Bi desktop to import from direct query.
2. Configured Personal Gateway
3. Uploaded file - it works at Power Bi Workspace
4. Scheduled refresh cannot be set - issue with Python Creditentials. Tried every possible combination and it fails.
Are you able to advice what can be the issue there? Had to cover company important info 🙂
Hi @Pawel_1990 ,
Thank you for reaching out to the Microsoft Community Forum.
Some of the issues listed below:
1. Verify Python Installation: Ensure that Python is installed on your machine and that the path to the Python executable is correctly set in the environment variables.
https://learn.microsoft.com/en-us/power-bi/connect-data/service-python-packages-support
2. Python scripts only work with personal gateways. Please refer the below thread
3. Additionally, as @Akash_Varuna suggested try running the Python transformations outside Power BI.
If my response has resolved your query, please mark it as the Accepted Solution to assist others. Additionally, a 'Kudos' would be appreciated if you found my response helpful.
Thank you
Hi @Pawel_1990 ,
If you find this post helpful, please mark it as an "Accept as Solution" and consider giving a KUDOS. Feel free to reach out if you need further assistance.
Thanks and Regards
Hi @Pawel_1990 ,
If you find this post helpful, please mark it as an "Accept as Solution" and consider giving a KUDOS. Feel free to reach out if you need further assistance.
Thanks and Regards
Hi @Pawel_1990 ,
If you find this post helpful, please mark it as an "Accept as Solution" and consider giving a KUDOS. Feel free to reach out if you need further assistance.
Thanks and Regards
Hi @Pawel_1990 Personal Gateway doesn’t support Python scripts, try running the Python transformations outside Power BI . You can also use an Enterprise Gateway instead which may solve the case
Hi @Pawel_1990 ,
Thank you for reaching out to the Microsoft Community Forum.
Some of the issues listed below:
Python Environment on Power BI Service : Ensure that the Python environment on the Power BI Service has the same libraries installed. Unfortunately, you can't directly install packages in Power BI Service, but you can test with a minimal script to isolate the issue. And use a Python script in Power BI Desktop to check for errors before publishing.
Data Source Credentials & Permissions (Snowflake connection issues are common when moving from Desktop to Service due to credential handling):
Go to Power BI Service > Dataset Settings > Data source credentials and verify that the credentials are configured correctly. Check if the Snowflake credentials are supported in the Service (especially if using a custom connector).
DirectQuery vs Import Mode Conflict: You mentioned using DirectQuery for other tables and Import for the Snowflake table. Mixing these modes can cause issues, especially when applying transformations with Python. Try converting the other tables to Import mode to see if that resolves the issue. Alternatively, test with all tables in DirectQuery mode to check for conflicts.
Power BI Service Limitation : The Service has some limitations with Python scripts. No support for interactive visualizations within Python scripts. Certain operations (especially heavy computations) might not run due to resource constraints. Optimize your Pandas code for performance. Test with simpler data to narrow down the problem.
If my response has resolved your query, please mark it as the Accepted Solution to assist others. Additionally, a 'Kudos' would be appreciated if you found my response helpful.
Thank you
Hi @Pawel_1990 As you said the excel is working fine it is likely because of the connection to Snowflake it actually requires Gateway ..... some of the likely issues are listed please check these and see if it solves your issue
Gateway Requirement – Power BI Service needs an on-premises data gateway for Snowflake. Ensure it's installed and configured.
Authentication Issues – Check Dataset Settings → Data source credentials and confirm your Snowflake login is correctly set.
DirectQuery and Python Conflict – If some tables use DirectQuery, Python transformations may fail. Try switching all Snowflake tables to Import mode and republish.
This is your chance to engage directly with the engineering team behind Fabric and Power BI. Share your experiences and shape the future.
Check out the June 2025 Power BI update to learn about new features.
User | Count |
---|---|
60 | |
33 | |
25 | |
23 | |
21 |
User | Count |
---|---|
57 | |
40 | |
26 | |
24 | |
22 |