Does the latest stable pygame release work with python2.7? - python

Like the subject says: Does the latest stable pygame release work with python2.7?
I've got both versions installed on my OSX Snow Leopard, but import pygame only works on python2.6 - That's the official distro which is 2.6.6, not the pre-installed one which is 2.6.1).
And if it does work, how can I make it work on my machine? What am I doing wrong?
Thanks in advance.

My guess is that you installed it for 2.6 and so it is residing in 2.6's library directory. Install it in 2.7's library directory and you should be good to go. I don't know OSX so I can't help with the details but a little bit of googling shouldn't be too hard. The problem is that the two python installations have distinct import paths.

Related

How to uninstall and/or manage multiple versions of python in OS X 10.10.3

I have installed the Python IDE Spyder. For me it's a great development environment.
Some how in this process I have managed to install three versions of Python on my system.These can be located as following:
Version 2.7.6 from the OS X Terminal;
Version 2.7.8 from the Spyder Console; and
Version 2.7.9rc1 from an IDL window.
The problem I have is (I think) that the multiple versions are preventing Spyder from working correctly.
So how do I confirm that 2.7.6 is the latest version supported by Apple and is there a simple way ('silver bullet') to remove other versions from my system.
I hope this is the correct forum for this question. If not I would appreciate suggestions where I could go for help.
I want to keep my life simple and to develop python software in the Spyder IDE. I am not an OS X guru and I really don't want to get into a heavy duty command line action. To that end I just want to delete/uninstall the 'unofficial versions' of Python. Surely there must be an easy way to do this - perhaps 'pip uninstall Python-2.7.9rc1' or some such. The problem is that I am hesitant to try this due to the fear that it will crash my system.
Help on this would be greatly appreciated.
(Spyder dev here) There is no simple way to do what you ask for, at least for the Python version that comes with Spyder.
I imagine you downloaded and installed our DMG package. That package comes with its own Python version as part of the application (along with several important scientific packages), so it can't be removed because that would imply to remove Spyder itself :-)
I don't know how you installed IDL(E?), so I can't advise you on how to remove it.

GTK3 and Python3 on Windows?

Is there any way to launch a Python3 / GTK3 based application on a Windows machine? It seems that this is not that simple as with GTK2/Python2.
Thanks a lot,
Thomas
I hope, i understand the question. You Need a actual runtime of gtk3 on Windows.
inofficial gtk3.14.13 64bit-Runtime, 32bit here not available,
see:
https://github.com/tschoonj/GTK-for-Windows-Runtime-Environment-Installer
win32 and win64: experimental official runtime 3.6.4 in http://www.gtk.org/download/index.php
is very Alpha or beta.
I hope this helps enough for gtk3.
As far as I know, there are still no official GTK3 or GObject-Introspection libraries for Windows, and so there are no python bindings.
I'm assuming you want the development kit. Windows version has indeed been missing for a long time, but there's some available now.
Going to official site and finding https://wiki.gnome.org/Projects/PyGObject, you can find a link to "Windows installers" which should lead to a rather massive all-in-one installer for Gtk3 and many related libraries for Python 3. You can load a current cpython from https://www.python.org/downloads/ and install that first.
For windows, there's also a lot of unofficial pre-built packages in http://www.lfd.uci.edu/~gohlke/pythonlibs/. Cpython 3.4 at least seems to include a functional pip for installing wheels.
I've made some use of these for running some python and matplotlib code 64-bit windows and they work rather nicely with 64-bit python 3.4. You can test with e.g. http://gtk3-matplotlib-cookbook.readthedocs.org/en/latest/ to find backend settings and other tips.

How can I install Pygame on a 64-bit win7?

I have searched the forum and found some related questions, but seems no easy-to-understand answers to me.
I have come to https://bitbucket.org/pygame/pygame/downloads but it only provides 32-bit installer. I am on a 64-bit Win7, which is already installed Python 3.3.2. How can I install Pygame in this case? Thanks.
This site contains non-official binaries of many Python packages for 32 and 64 bit versions of Windows, and it is also mentioned in the downloads section of Pygame.org. The downloads for Pygame are here.

enthought python distribution wx

For some reason my 64 bit EPD can't import wx.
I also tried to install the wxPython2.8-osx-unicode-py2.7 version from the wx site.
It installed successfully, but is no where to be found on my harddrive.
I checked the sitepackes for 2.7 and the EPD 7.2.2. where all the modules usually should be installed.
I am confused.
This raises a similar question.
How can I install modules that are not part of EPD ?
I also didn't have luck to install other modules.
And every time I try to import older modules it doesn't work as well.
Often I get error message that architectures in universal rapper is wrong.
For example pygame doesn’t have a 64 bit version that works with 2.7, so I installed the 32 bit version.
If I try to do the trick arch -i386 /Path to python , I get "Bad CPU type in executable".
I am running a 64bit version of Python on a 64 bit Mac OS.
I wonder if the Enthougt 7.2 is equivalent with the 2.7 Python.
And if not, what I assume, what the differences are.
Any hints who can solve this, would be awesome.
Thanks for your patients.
I had the same problem. The only way around it that has worked for me is to uninstall your EPD version ($ sudo remove-EPD-7.2-1, or whichever version you have) and reinstall the 32 bit version. Wx comes as part of the EPD package, so once you have downloaded the 32 bit version there is no need to download and install wx.

upgrading python

Hi
I just want to install mercurial but for all versions it needs python 2.6, I tried to use .rpm file but the only thing I got is lots of lines full of error which tells: need old versions before 2.6 and after 2.5 which is installed on my linux. any help would be appreciated.
Bests
Go to ActiveState and download their versions: https://www.activestate.com/activepython/downloads
It's much easier than using the .rpms.
Which distribution are you using? I would recommend you to upgrade your system to a newer version of your linux distro, whatever it is. Modern Linux distros are using at least python2.6 now.
If you do not want to upgrade your system with various reasons, ActiveState's python version as stated in Jasie's answer is good for your cause. It installs python in your system without breaking anything, just you have to add some lines in your .bashrc to force system find your ActiveState python installation before the system's python.
Another alternative would be installing earlier version of mercurial which supports the python version installed on your system. But I would not recommend you to do so..
Among these, my suggestion is upgrading your system to a merely "up-to-date" version, so that python2.6 or higher is installed on your system.

Categories