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 Script Not prod...
Power Automate
Answered

Python Script Not producing output

(0) ShareShare
ReportReport
Posted on by 431

I have a CurrMonthList which is delimited by newlines. my python script does not produce an output: ActiveMonth is always empty. The script works in PyCharm

 

CurrentMonthList.png

Script.png

I have the same question (0)
  • Steve48 Profile Picture
    431 on at

    I am the OP. I see that there is a script error. It seems like it is being caused by the first data item in the list which has the word "Calendar" Why is this causing an error and how do i prevent this from causing an error

     

    Steve48_0-1704646896160.png

     

  • Steve48 Profile Picture
    431 on at

    OP here again. The updated script runs without error, but it's not getting a match. The ActiveMonth output is None. It should match on 'Deceber, because that is in the input list.

    Steve48_1-1704649519663.png

     

  • Verified answer
    Agnius Bartninkas Profile Picture
    Most Valuable Professional on at

    Scripts in PAD only accept strings as inputs. Your list is not actually interpreted as a list by your Python script. It would be better to join it using Join text in your flow, pass it in as a string and then split it into list in the Python script itself.

    -------------------------------------------------------------------------
    If I have answered your question, please mark it as the preferred solution. If you like my response, please give it a Thumbs Up.

    I also provide paid consultancy and development services using Power Automate. If you're interested, DM me and we can discuss it.

  • Steve48 Profile Picture
    431 on at

    Hi @Agnius I didnt know that. I dont recall seeing it in the documention. That is very helpful but my flow/script still doesnt work. Now that I have taken your input into account, I'm thinking the problem is occurring before the script.  However I will regard this post as closed and solved and post a new topic now that I know I have to pass  string into the Python script.

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 July Top 10 Community Leaders!

These are the community rock stars!

Leaderboard > Power Automate

#1
David_MA Profile Picture

David_MA 248 Super User 2026 Season 2

#2
trice602 Profile Picture

trice602 160 Super User 2026 Season 2

#3
11manish Profile Picture

11manish 142 Super User 2026 Season 2

Last 30 days Overall leaderboard