Is there new version of pygame for anaconda env?

Viewed 249

I have pygame in pip environment and used it without problem.
But now I switched to conda environment (called tf-gpu) to have TF features also. As I figured out the most used channel for conda version of pygame is cogsci.
But conda install -c cogsci pygame in terminal causes an error:enter image description here


It seems there is a version incompatibility.

I then downloaded the original tar.bz2 file from conda, and tried conda install --offline C:\...(file path)
It downloaded and recognized by interpreter(python 3.8.8, conda('tf_gp' env)).
Then Pyhton imported pygame but error of there is no module "from python.base import *" proceeded it.(as it is in the __init__ file of package)
Are these problem due to old version of pygame? I tried other channels in anaconda but unsuccessful(also they were older).
And also i can not downgrade python because of many packages' prerequisites.
I also tried installing via pip(in that conda promp), but it said that the requirment has been satisfied(as i previoisly used pygame in pip env(python 3.8.2).

  • Is there any new conda version of pygame?
  • Should i remove previous pygame in pip and try pip install again in conda env?
  • Or is it possible to modify main package source code(old file)?
2 Answers

This issue usually comes in when you are running many versions of python and pygame together which causes some incompatibility. Another problem which may occur is that anaconda environment stop recognising the pygame as it can’t locate it.

My suggestion is that uninstall all the older versions of python and pygame and install the latest ones.

Or else you may shift to Visual studio code for better experience and lesser problems.

Thanks,

The problem was solved by uninstalling other python version that I had(3.6). and using pip version of pygame(which did not work when two python versions (3.6, 3.8) were on my system.)

Related