Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!

Bug 511814

Summary: dev-python/pygame-1.9.2_pre20120101-r2 - pygame.midi.init(): ImportError: No module named pypm
Product: Gentoo Linux Reporter: MaurizioB <mauriziob>
Component: [OLD] DevelopmentAssignee: Python Gentoo Team <python>
Status: RESOLVED FIXED    
Severity: normal    
Priority: Normal    
Version: unspecified   
Hardware: All   
OS: Linux   
Whiteboard:
Package list:
Runtime testing required: ---
Attachments: output of emerge --info pygame

Description MaurizioB 2014-05-29 21:06:13 UTC
Created attachment 377822 [details]
output of emerge --info pygame

It looks like the pypm module, required by pygame.midi, is not available.

>>> import pygame.midi 
>>> pygame.midi.init() 
Traceback (most recent call last): 
  File "<stdin>", line 1, in <module> 
  File "/usr/lib/python2.7/site-packages/pygame/midi.py", line 71, in init 
    import pygame.pypm 
ImportError: No module named pypm


I checked the python_targets and they are correctly set for 2.7 and 3.3, the portmidi library is installed and checked during configure of pygame.
Comment 1 bugzilla 2015-02-01 17:33:01 UTC
Hi,

I have stumbled on this bug.

I have following versions:
→ eix portmidi
[I] media-libs/portmidi
     Available versions:  217 ~217-r1 {debug doc java python static-libs test-programs ELIBC="FreeBSD" PYTHON_TARGETS="python2_7"}
     Installed versions:  217(17:08:12 01.02.2015)(python -debug -doc -java -static-libs -test-programs ELIBC="-FreeBSD")

→ eix pygame         
[I] dev-python/pygame
     Available versions:  1.9.2_pre20120101-r1 1.9.2_pre20120101-r2 {X doc examples test PYTHON_TARGETS="python2_7 python3_3 python3_4"}
     Installed versions:  1.9.2_pre20120101-r2(17:07:51 01.02.2015)(X examples -doc -test PYTHON_TARGETS="python2_7 python3_3 -python3_4")
Comment 2 Tim Harder gentoo-dev 2017-04-27 07:23:45 UTC
Fixed in 1.9.3 now in the tree. Enable the midi USE flag to enable midi support via portmidi.