Installing Pygame for Mac OS X 10.6.8

后端 未结 5 1643
花落未央
花落未央 2020-11-30 05:01

Using Python 2.7.2. When I try to import pygame I get this error message:

Traceback (most recent call last):
  File \"\", line 1, in 

        
5条回答
  •  挽巷
    挽巷 (楼主)
    2020-11-30 05:38

    I was having the same problem. I had Python 2.7.2, the installation version for OSX 10.6. Here is what I did to fix it:

    1) Deleted my current installation of Python, both from the applications folder and from /Library/Frameworks/Python.framework (I just deleted 2.7.2, left 3.2 alone)

    2) Reinstalled Python 2.7.2, the installation version for OSX 10.3 (my pygame installation file was labeled for OSX 10.3, which prompted me in this direction)

    3) Reinstalled pygame

    Now pygame imports without throwing an error.

提交回复
热议问题