Reputation: 1
System: OSX Yosemite 10.10.5
Language: Python 2.7 (must use 2.7 for class)
IDE: LiClipse
Background: For the longest time I could NOT get pygame to work at all in python. After much research I realized that pygame for mac is 32-bit while the general python 2.7 is 64-bit. So I uninstalled the 64-bit python and reinstalled 32-bit python 2.7.
Problem now: When I enter IDLE, I am able to write
>> import pygame
>> print(pygame.ver)
and
1.9.1release
is successfully returned. No problem in IDLE
HOWEVER
When I enter LiClipse and simply run:
import pygame
The following is returned:
ImportError: No module named pygame
How is this possible if pygame can be imported in IDLE?
Upvotes: 0
Views: 280
Reputation: 146
Make sure your IDE is running the same python version and same PYTHONPATH environment variable (check sys.version
and sys.path
from both IDEs).
Upvotes: 1