# The specified Python path is not valid in uipath

**URL:** <https://forum.uipath.com/t/the-specified-python-path-is-not-valid-in-uipath/783754>\
**Category:** Studio\
**Tags:** activities-panel, question, studio, python, activities\
**Created:** [December 4, 2024, 5:55pm UTC](https://forum.uipath.com/t/the-specified-python-path-is-not-valid-in-uipath/783754 "2024-12-04T17:55:14Z")\
**Posts on this page:** 20\
**Page:** 1

<div class="post-metadata">

**Author:** ![chris.dease](https://sea2.discourse-cdn.com/uipath/user_avatar/forum.uipath.com/chris.dease/32/513004_2.png) [@chris.dease](https://forum.uipath.com/u/chris.dease)\
**Post date:** [December 4, 2024, 5:55pm UTC](https://forum.uipath.com/t/the-specified-python-path-is-not-valid-in-uipath/783754/1 "2024-12-04T17:55:15Z")

</div>

Hello, I’m getting the above error when trying to run python script in studio. Below are my specs:

- studio version 2023.4.7
- python package 1.8.2
- python version 3.11.5

i tried to use the forum’s other posts with no success. Here’s what i’ve done:

 ![The image shows a command prompt window where the user is locating the Python executable paths using `where python` and checking the installed Python version, which is Python 3.11.5. (Captioned by AI)](https://global.discourse-cdn.com/uipath/original/4X/2/5/0/2501c7596adf49c04c832a6493bbca09cf80c578.png)

- i’ve put both file path’s into the python scope. both have given me the same error
- i’ve tried right clicking the program to find folder location and get different path from cmd but that doesn’t work either. C:\ProgramData\Microsoft\Windows\Start Menu\Programs\Python 3.11
- i’ve tried leaving off “python.exe” as suggested in another forum and when i run file, nothing happens at all. studio freezes

---

<div class="post-metadata">

**Author:** ![loginerror](https://sea2.discourse-cdn.com/uipath/user_avatar/forum.uipath.com/loginerror/32/22614_2.png) [@loginerror](https://forum.uipath.com/u/loginerror)\
**Post date:** [December 4, 2024, 6:01pm UTC](https://forum.uipath.com/t/the-specified-python-path-is-not-valid-in-uipath/783754/2 "2024-12-04T18:01:08Z")

</div>

Hi @chris.dease

You might have to use the official Python installer rather than its Windows store version. The library path is supposed to point to the python311.dll file, and I don’t think there is one for this installation method.

---

<div class="post-metadata">

**Author:** ![ashokkarale](https://sea2.discourse-cdn.com/uipath/user_avatar/forum.uipath.com/ashokkarale/32/474400_2.png) [@ashokkarale](https://forum.uipath.com/u/ashokkarale)\
**Post date:** [December 4, 2024, 6:02pm UTC](https://forum.uipath.com/t/the-specified-python-path-is-not-valid-in-uipath/783754/3 "2024-12-04T18:02:40Z")

</div>

@chris.dease

Refer this how to guide.

> **[Activities - Invoking a Python Script](https://docs.uipath.com/activities/other/latest/developer/invoking-a-python-script)**
>
> The UiPath Documentation Portal - the home of all our valuable information. Find here everything you need to guide you in your automation journey in the UiPath ecosystem, from complex installation guides to quick tutorials, to practical business...

If still don’t work, share how you are configuring

---

<div class="post-metadata">

**Author:** ![chris.dease](https://sea2.discourse-cdn.com/uipath/user_avatar/forum.uipath.com/chris.dease/32/513004_2.png) [@chris.dease](https://forum.uipath.com/u/chris.dease)\
**Post date:** [December 4, 2024, 10:52pm UTC](https://forum.uipath.com/t/the-specified-python-path-is-not-valid-in-uipath/783754/4 "2024-12-04T22:52:09Z")

</div>

this is how i set it up:  
localAppDataPath = Environment.GetFolderPath(Environment.SpecialFolder.LocalApplicationData)

pythonPath = localAppDataPath + "\Programs\Python\Python311"

pythonLibraryPath = localAppDataPath + “\Programs\Python\Python312\python311.dll”

 ![image](https://global.discourse-cdn.com/uipath/original/4X/3/a/f/3af756a49f60b357cddba771e28d3e4f917ec014.png)

received the log message: The installation path of Python 3.12 was set as: C:\Users\ACI43\AppData\Local\Programs\Python\Python311\

still received the error.

Verified python does work by running script outside of UiPath

---

<div class="post-metadata">

**Author:** ![ashokkarale](https://sea2.discourse-cdn.com/uipath/user_avatar/forum.uipath.com/ashokkarale/32/474400_2.png) [@ashokkarale](https://forum.uipath.com/u/ashokkarale)\
**Post date:** [December 5, 2024, 2:56am UTC](https://forum.uipath.com/t/the-specified-python-path-is-not-valid-in-uipath/783754/5 "2024-12-05T02:56:44Z")

</div>

@chris.dease,

Have you set enviornment variable for python?

Have you tried the sample code from this?

> **[Activities - Invoking a Python Script](https://docs.uipath.com/activities/other/latest/developer/invoking-a-python-script)**
>
> The UiPath Documentation Portal - the home of all our valuable information. Find here everything you need to guide you in your automation journey in the UiPath ecosystem, from complex installation guides to quick tutorials, to practical business...

---

<div class="post-metadata">

**Author:** ![loginerror](https://sea2.discourse-cdn.com/uipath/user_avatar/forum.uipath.com/loginerror/32/22614_2.png) [@loginerror](https://forum.uipath.com/u/loginerror)\
**Post date:** [December 5, 2024, 9:32am UTC](https://forum.uipath.com/t/the-specified-python-path-is-not-valid-in-uipath/783754/6 "2024-12-05T09:32:02Z")

</div>

Hey @chris.dease

Just a sanity check, in case you copy pasted the content above. Please note the discrepancy:

 ![A user is troubleshooting an error with setting the Python installation path in UiPath, highlighting a potential path mismatch for Python 3.12 instead of Python 3.11. (Captioned by AI)](https://global.discourse-cdn.com/uipath/original/4X/3/9/b/39b6a5bf4ab7edba28df81c673e311c881028b9e.png)

---

<div class="post-metadata">

**Author:** ![chris.dease](https://sea2.discourse-cdn.com/uipath/user_avatar/forum.uipath.com/chris.dease/32/513004_2.png) [@chris.dease](https://forum.uipath.com/u/chris.dease)\
**Post date:** [December 5, 2024, 12:37pm UTC](https://forum.uipath.com/t/the-specified-python-path-is-not-valid-in-uipath/783754/7 "2024-12-05T12:37:11Z")

</div>

i did use 311. i just copied the log message from the documentation

---

<div class="post-metadata">

**Author:** ![chris.dease](https://sea2.discourse-cdn.com/uipath/user_avatar/forum.uipath.com/chris.dease/32/513004_2.png) [@chris.dease](https://forum.uipath.com/u/chris.dease)\
**Post date:** [December 5, 2024, 12:38pm UTC](https://forum.uipath.com/t/the-specified-python-path-is-not-valid-in-uipath/783754/8 "2024-12-05T12:38:34Z")

</div>

i changed from 312 to 311 and still same result

---

<div class="post-metadata">

**Author:** ![chris.dease](https://sea2.discourse-cdn.com/uipath/user_avatar/forum.uipath.com/chris.dease/32/513004_2.png) [@chris.dease](https://forum.uipath.com/u/chris.dease)\
**Post date:** [December 5, 2024, 1:01pm UTC](https://forum.uipath.com/t/the-specified-python-path-is-not-valid-in-uipath/783754/9 "2024-12-05T13:01:41Z")

</div>

i’m not running this exact script. i’m running one i have from youtube. same scenario though. but debug won’t even let me get to the script. it’s failing at python scope.

---

<div class="post-metadata">

**Author:** ![ashokkarale](https://sea2.discourse-cdn.com/uipath/user_avatar/forum.uipath.com/ashokkarale/32/474400_2.png) [@ashokkarale](https://forum.uipath.com/u/ashokkarale)\
**Post date:** [December 5, 2024, 1:10pm UTC](https://forum.uipath.com/t/the-specified-python-path-is-not-valid-in-uipath/783754/10 "2024-12-05T13:10:27Z")

</div>

@chris.dease,

Get the sample code from the documentation first to isolate the issue you have. Once the code from here works then you can try other scripts to run.

> **[Activities - Python how-to guides](https://docs.uipath.com/activities/other/latest/developer/python-how-to-guides)**
>
> The UiPath Documentation Portal - the home of all our valuable information. Find here everything you need to guide you in your automation journey in the UiPath ecosystem, from complex installation guides to quick tutorials, to practical business...

---

<div class="post-metadata">

**Author:** ![chris.dease](https://sea2.discourse-cdn.com/uipath/user_avatar/forum.uipath.com/chris.dease/32/513004_2.png) [@chris.dease](https://forum.uipath.com/u/chris.dease)\
**Post date:** [December 5, 2024, 1:18pm UTC](https://forum.uipath.com/t/the-specified-python-path-is-not-valid-in-uipath/783754/11 "2024-12-05T13:18:28Z")

</div>

i downloaded the entire sample workflow and changed the 312 to 311 in the code. Still getting the same issue.

 ![The debugger interface displays a problem indicating that the specified Python path is not valid. (Captioned by AI)](https://global.discourse-cdn.com/uipath/original/4X/7/0/7/7077e43b266e585d0d85d2decad13a33407a5264.png)

---

<div class="post-metadata">

**Author:** ![ashokkarale](https://sea2.discourse-cdn.com/uipath/user_avatar/forum.uipath.com/ashokkarale/32/474400_2.png) [@ashokkarale](https://forum.uipath.com/u/ashokkarale)\
**Post date:** [December 5, 2024, 1:30pm UTC](https://forum.uipath.com/t/the-specified-python-path-is-not-valid-in-uipath/783754/12 "2024-12-05T13:30:19Z")

</div>

@chris.dease,

Try removing that last `\` from the path.

 ![The image shows an error message indicating that the specified Python path is not valid during the debugging process in an IDE. (Captioned by AI)](https://global.discourse-cdn.com/uipath/original/4X/d/9/d/d9d22810e6711c3a54f6dd153ee03e3c07e382bc.png)

---

<div class="post-metadata">

**Author:** ![chris.dease](https://sea2.discourse-cdn.com/uipath/user_avatar/forum.uipath.com/chris.dease/32/513004_2.png) [@chris.dease](https://forum.uipath.com/u/chris.dease)\
**Post date:** [December 5, 2024, 1:58pm UTC](https://forum.uipath.com/t/the-specified-python-path-is-not-valid-in-uipath/783754/13 "2024-12-05T13:58:27Z")

</div>

same issue.  
 ![image](https://global.discourse-cdn.com/uipath/original/4X/b/f/3/bf329468bd22a6685880019274b378478b677ad1.png)

---

<div class="post-metadata">

**Author:** ![AJ\_Ask](https://sea2.discourse-cdn.com/uipath/user_avatar/forum.uipath.com/aj_ask/32/555384_2.png) [@AJ\_Ask](https://forum.uipath.com/u/AJ_Ask)\
**Post date:** [December 6, 2024, 1:08pm UTC](https://forum.uipath.com/t/the-specified-python-path-is-not-valid-in-uipath/783754/14 "2024-12-06T13:08:33Z")

</div>

Hi @chris.dease

Copy this path & try to open it in the run. Is it correclty pointing to the Python path.  
Also try to hardcode the path insted of varible. For testing.

---

<div class="post-metadata">

**Author:** ![chris.dease](https://sea2.discourse-cdn.com/uipath/user_avatar/forum.uipath.com/chris.dease/32/513004_2.png) [@chris.dease](https://forum.uipath.com/u/chris.dease)\
**Post date:** [December 6, 2024, 2:00pm UTC](https://forum.uipath.com/t/the-specified-python-path-is-not-valid-in-uipath/783754/15 "2024-12-06T14:00:00Z")

</div>

are you telling me to copy and paste what i put in my screenshot instead of passing the variable?

---

<div class="post-metadata">

**Author:** ![AJ\_Ask](https://sea2.discourse-cdn.com/uipath/user_avatar/forum.uipath.com/aj_ask/32/555384_2.png) [@AJ\_Ask](https://forum.uipath.com/u/AJ_Ask)\
**Post date:** [December 6, 2024, 2:13pm UTC](https://forum.uipath.com/t/the-specified-python-path-is-not-valid-in-uipath/783754/16 "2024-12-06T14:13:14Z")

</div>

Yes correct. Don’t pass it as variable.

---

<div class="post-metadata">

**Author:** ![chris.dease](https://sea2.discourse-cdn.com/uipath/user_avatar/forum.uipath.com/chris.dease/32/513004_2.png) [@chris.dease](https://forum.uipath.com/u/chris.dease)\
**Post date:** [December 6, 2024, 2:36pm UTC](https://forum.uipath.com/t/the-specified-python-path-is-not-valid-in-uipath/783754/17 "2024-12-06T14:36:57Z")

</div>

i used both C:\Users\ACI43\AppData\Local\Programs\Python\Python311\ and C:\Users\ACI43\AppData\Local\Programs\Python\Python311 as the path and got the same results.

hard coded library path to “C:\Users\ACI43\AppData\Local\Programs\Python\Python311\python311.dll”

 ![The image shows an error log indicating that a Python path is invalid, preventing an execution from completing successfully. (Captioned by AI)](https://global.discourse-cdn.com/uipath/original/4X/0/e/3/0e3d053a572d023e00ec266c5f7181b89ca15d30.png)

---

<div class="post-metadata">

**Author:** ![AJ\_Ask](https://sea2.discourse-cdn.com/uipath/user_avatar/forum.uipath.com/aj_ask/32/555384_2.png) [@AJ\_Ask](https://forum.uipath.com/u/AJ_Ask)\
**Post date:** [December 6, 2024, 4:49pm UTC](https://forum.uipath.com/t/the-specified-python-path-is-not-valid-in-uipath/783754/18 "2024-12-06T16:49:25Z")

</div>

Check python is installed correctly or not in cmd. Also your python version should match your system like 32 bit or 64bit.

---

<div class="post-metadata">

**Author:** ![chris.dease](https://sea2.discourse-cdn.com/uipath/user_avatar/forum.uipath.com/chris.dease/32/513004_2.png) [@chris.dease](https://forum.uipath.com/u/chris.dease)\
**Post date:** [December 6, 2024, 6:11pm UTC](https://forum.uipath.com/t/the-specified-python-path-is-not-valid-in-uipath/783754/19 "2024-12-06T18:11:51Z")

</div>

I’m not sure what you’re asking by checking if python is installed correctly but I was able to run the script outside of Studio with success.

**i did do the following based on a youtube video and the results were no error but also no output. the automation would not move forward or would never stop.**

the video told me to right click on python icon and get folder location. i got back C:\ProgramData\Microsoft\Windows\Start Menu\Programs\Python 3.11. when i added that path, i got the issue in the bold.

also confirmed it’s 64-bit and i have that configured in studio.

---

<div class="post-metadata">

**Author:** ![AJ\_Ask](https://sea2.discourse-cdn.com/uipath/user_avatar/forum.uipath.com/aj_ask/32/555384_2.png) [@AJ\_Ask](https://forum.uipath.com/u/AJ_Ask)\
**Post date:** [December 6, 2024, 6:29pm UTC](https://forum.uipath.com/t/the-specified-python-path-is-not-valid-in-uipath/783754/20 "2024-12-06T18:29:51Z")

</div>

I think when you followed the youtube video & there was no error & bot was not moving ahead you were on right track.

You also need to install .net 6.0 version for python scope to work

> **[Download .NET 6.0 Desktop Runtime (v6.0.33) - Windows x64 Installer](https://dotnet.microsoft.com/en-us/download/dotnet/thank-you/runtime-desktop-6.0.33-windows-x64-installer)**

[Next page](https://forum.uipath.com/t/the-specified-python-path-is-not-valid-in-uipath/783754.md?page=2)
