Jump to content

Recommended Posts

Posted
What happens when you run pip?

It complains that pip doesn't exist. I'm currently testing replacing our installation of 3.9 with 3.10.5, which not only puts us on a newer version, it is also installing pip and the Scripts folder. I'm now testing the deployment of Pygame to the test collection using @chris_uk's post for SCCM.

Posted

Hi all!

 

Thanks for all your support on this. In the end, I'm using a quick script which I deploy via PDQ. Works well :)

 

pip install //share/pygame-2.1.2-cp310-cp310-win_amd64.whl

 

'pygame-2.1.2-cp310-cp310-win_amd64.whl' is the file that I downloaded from a VM I installed it on for testing. This way, it makes it a local install rather than doing via the internet!

 

Many thanks :)

  • Thanks 1
Posted
Hi all!

 

Thanks for all your support on this. In the end, I'm using a quick script which I deploy via PDQ. Works well :)

 

pip install //share/pygame-2.1.2-cp310-cp310-win_amd64.whl

 

'pygame-2.1.2-cp310-cp310-win_amd64.whl' is the file that I downloaded from a VM I installed it on for testing. This way, it makes it a local install rather than doing via the internet!

 

Many thanks :)

 

Where did you get the whl file from? I can't seem to find it. I've deployed Pygame via SCCM, but each installation pulls the files from the internet, which is proving hit and miss (with some clients reporting it's installed in SCCM, but Python cannot load the module). So I'd rather do an offline install via SCCM than have each client pull from the Internet. I also don't know what to reliably use for a detection method.

Posted
Where did you get the whl file from? I can't seem to find it.

 

pip download pygame --dir c:\temp

I also don't know what to reliably use for a detection method.

 

I use File System, the type is a folder, path is %ProgramFiles%\Python310\include, and the file/folder name is pygame.h

 

 

...And then after all that

pip install //share/pygame-2.1.2-cp310-cp310-win_amd64.whl

  • Thanks 2
Posted

If you have a proxy server you do need to inform PIP of the proxy details, to get PIP to install Python modules.

Please find below the script that I used to install Python, Pycharm, and some modules.

 

 

rem silent install of python, and PyCharm, and some Python modules

 

net use y: \\joa-app01\Repository

Y:

cd python

cd python

python-3.10.3-amd64.exe /passive /InstallAllUsers

 

Cd ..

cd pycharm

pycharm-community-2021.3.3.exe /S /config=silent.config

 

c:

cd c:\progra~1

cd python

 

rem set python proxy

set http_proxy=wf2.thegrid.org.uk:80

set https_proxy=wf2.thegrid.org.uk:80

 

 

pip install wheel

 

pip install Pygame

 

pip install numpy

 

pip install pyopengl

 

 

net use y: /delete

 

exit

  • 2 weeks later...
Posted

I've been asked to install Pygame Zero, which is a different Python project, built from Pygame...but I've been having trouble installing it. I have the WHL file, but I'm getting the following error when I try to install it:

 

C:\Windows>"C:\Program Files\Python310\python.exe" -m pip install \\server\share$\Apps\Python\Pygame Zero\1.2.1\pgero-1.2.1-py3-none-any.whl
Defaulting to user installation because normal site-packages is not writable
Error: Directory '\\\\server\\share$\\Apps\\Python\\Pygame' is not installable. Neither 'setup.py' nor 'pyproject.toml' found.

 

I get the same error when I try running these two commands:

"C:\Program Files\Python310\Scripts\pip3.exe" install %~dp0pgzero-1.2.1-py3-none-any.whl
and
"C:\Program Files\Python310\python.exe" -m pip install %~dp0pgzero-1.2.1-py3-none-any.whl

 

It looks like it's trying to install it to the same folder/share that the whl installer file is located in, but I want it to install in the default site-packages folder on the local machine's Python installation folder. I can't figure out why this is happening. I've used the same command to install the original Pygame and that works correctly. It just seems to be an issue with Pygame Zero.

Posted
I've been asked to install Pygame Zero, which is a different Python project, built from Pygame...but I've been having trouble installing it. I have the WHL file, but I'm getting the following error when I try to install it:

 

It looks like it's trying to install it to the same folder/share that the whl installer file is located in, but I want it to install in the default site-packages folder on the local machine's Python installation folder. I can't figure out why this is happening. I've used the same command to install the original Pygame and that works correctly. It just seems to be an issue with Pygame Zero.

 

You can specify the destination folder:

 

pip install --target=d:\somewhere\other\than\the\default package_name

Posted
You can specify the destination folder:

 

pip install --target=d:\somewhere\other\than\the\default package_name

Thanks. I've just tried that, but unfortunately I get the same error message.

  • 8 months later...
Posted
# benfaminb12 I know this is an old post but looking at getting python - pygame working with PDW Deploy, I have python 3.10 and the pygame-2.3.0-cp310-cp310-win_amd64.whl but not understanding how you command line this, have you used a batch file, see you have // for computer share not \\ as in Windows environment. then the last remark on %ProgramFiles%\Python310\include, and the file/folder name is pygame.h how that works with PDQ Deploy, when you place a new step in PDQ Deploy what do you use. Install, Command, PowerShell. Benn working with command but not sure it needs a batch filepippygame.JPG
Posted
# benfaminb12 I know this is an old post but looking at getting python - pygame working with PDW Deploy, I have python 3.10 and the pygame-2.3.0-cp310-cp310-win_amd64.whl but not understanding how you command line this, have you used a batch file, see you have // for computer share not \\ as in Windows environment. then the last remark on %ProgramFiles%\Python310\include, and the file/folder name is pygame.h how that works with PDQ Deploy, when you place a new step in PDQ Deploy what do you use. Install, Command, PowerShell. Benn working with command but not sure it needs a batch file[ATTACH=CONFIG]68376[/ATTACH]

 

Hi - I literally deployed Python 3.10.2 via SCCM and then using PDQ deployed a batch file called installscript.bat. Inside that script is 'pip install \\install_location\pygame-2.1.2-cp310-cp310-win_amd64.whl' rather than using the custom script button inside PDQ.

Posted
I'd recommend logging in as a local admin on the machine, running the scripts in cmd and then it should work - providing that the script doesn't need to be run every time!

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now



×
×
  • Create New...