web
You’re offline. This is a read only version of the page.
close
Skip to main content

Announcements

News and Announcements icon
Community site session details

Community site session details

Session Id :
Power Platform Community / Forums / Power Automate / python module error in...
Power Automate
Suggested Answer

python module error in power automate desktop

(2) ShareShare
ReportReport
Posted on by 2

i am trying to execute below part of my python script in power automate desktop

--------------------

# importing the pandas library

import pandas as pd

DataFile = "filepath";

#Reading Excel Files

test_data = pd.read_excel(DataFile);

-------------------------

However it is giving error "C:\Program Files\Python311\Lib\site-packages\pandas\__init__.py", line 1

from __future__ import annotations ^SyntaxError: future feature is not defined:annotations".

I tried searching on google it was showing future annotations supported for python >=3.7 and i am using python 3.11.9.

I have already given the module path in power automate desktop but still unable to resolve the error.

Also I have a doubt that in power automate desktop the option to select python version is showing 2.7 and 3.4 only and there is no option to upgrade. Is it because of that?

can anyone please help me on this? or is there any other alternative i can try (i have to use pandas only because of requirement)

test.png
I have the same question (0)
  • Suggested answer
    VishnuReddy1997 Profile Picture
    2,666 Super User 2026 Season 1 on at
    Hey Hi,
     
    As of my observation to execute Python script in PAD, Run Python script action is not that feasible and it only supports 3.4 and 2.7 versions and few modlues are not supporting with that action.
     
    So try this method to run the Python script using PAD.
     
    Save the Python script as .py file and use Run PowerShell Script action and pass the path as shown in below image.
     
     
    (Note:- if you got your solution you can mark as solution and gives kudos)
     
     
     
    Thanks & Regards
    Vishnu Reddy
     
     

Under review

Thank you for your reply! To ensure a great experience for everyone, your content is awaiting approval by our Community Managers. Please check back later.

Helpful resources

Quick Links

Season of Sharing Community Challenge Winners!

Congratulations to our community stars!

Kudos to our 2025 Community Spotlight Honorees

Expanding mentorship, skilling, and AI innovation

Congratulations to the June Top 10 Community Leaders!

These are the community rock stars!

Leaderboard > Power Automate

#1
David_MA Profile Picture

David_MA 229 Super User 2026 Season 1

#2
11manish Profile Picture

11manish 227

#3
Haque Profile Picture

Haque 181

Last 30 days Overall leaderboard