-
Notifications
You must be signed in to change notification settings - Fork 579
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Python 3.10+ on Windows x86 architecture doesn't have the Scripts
folder on path
#1005
Comments
Hello @Avasam, Thank you for creating this issue and we will look into it :) |
I am temporarily working around this issue with the following step: - name: Fix user Scripts missing from PATH
if: matrix.architecture == 'x86'
run: |
# Work around https://github.com/actions/setup-python/issues/1005
$ScriptsPath = python -c "import sysconfig,os; print(sysconfig.get_path('scripts', f'{os.name}_user'))"
echo $ScriptsPath
Add-Content $env:GITHUB_PATH $ScriptsPath |
Hello @Avasam, Thank you for your patience as we worked through this issue. Here’s an explanation of why the warning appears during the installation of PyInstaller, but not for pywin32: When the PyInstaller package is installed with the --user flag, the following warning appears: This behavior is expected when installing Python packages with the --user flag as per the official Python documentation on --user flag. The user-specific installation directory is typically located in ~/.local/ (on Linux/macOS) or %APPDATA%\Python (on Windows). For further details on where this directory is and how it works, you can refer to the Python documentation here. We can address the warning in one of two ways:
For guidance on modifying the PATH variable, see the Python documentation for User Installation Path.
pip install --no-warn-script-location In our basic workflow, we did not encounter this warning because the script locations were likely already included in the correct PATH, or it could be due to differences in the environment (e.g., virtual environments or the default system setup). However, the warning appeared in your case when using the --user flag due to the specific installation method and the location of the scripts. I’ve also attached screenshots for reference to illustrate this. I hope this clarifies the situation. Please let us know if you need any further assistance! |
Thanks for the response @aparnajyothi-y . I don't need to, or intend to, suppress the pip warning as it is merely a symptom and a helpful message that helped me find my issue. The core issue I have is not being able to run installed Python scripts on the CI for Python 3.10+ on x86 architecture specifically. (at least not without a workaround as I have shared above) I would ask for I can see that https://docs.python.org/3/library/sysconfig.html#nt-user does not mention the Do note that I verified, by printing the result of PS.: The link you shared https://docs.python.org/3/install/index.html#custom-installation is not valid (404 Not Found) |
Description:
When pip installing a library that adds console scripts on Python 3.10+ on Windows x86, I get the following message:
See this action run at this specific line for example: https://github.com/mhammond/pywin32/actions/runs/12664473637/job/35292676675?pr=2408#step:5:3578
This doesn't see to affect x64 self-hosted runners or Python 3.9 and under.
I'm not 100% certain where the issue lies, but I'm assuming that this path not being added to
PATH
lies withsetup-python
I couldn't find anything in Python 3.10's changelog indicating that this is an intended change within official Python installers themselves (no idea if this would happen with a local install)
Action version:
v5
Platform:
Runner type:
Tools version:
3.10, x86
3.11, x86
3.12, x86
3.13, x86
Repro steps:
Run the actions of this commit (permalink): https://github.com/Avasam/pywin32/blob/61e4698/.github/workflows/main.yml
Expected behavior:
C:\Users\runneradmin\AppData\Roaming\Python\Python310-32\Scripts
to be present on path, no warning and scripts are accessibleActual behavior:
The text was updated successfully, but these errors were encountered: