简体   繁体   中英

kivy in virtual environment, window provider error (linux)

I am trying to get the kivy framework to run on a Ubuntu 16.04 LTS machine with anaconda python.

I have followed the installation instructions provided here both in virtualenv and conda virtualenv environments.

In both kinds of environments I encountered the same issue. When trying to run a kivy program with python file.py I get (among others) the following messages and the program doesn't execute:

    [INFO   ] [Kivy        ] v1.9.1
    [INFO   ] [Python      ] v2.7.12 (default, [...]) 
    [GCC 5.4.0 ...]
    [INFO   ] [Factory     ] 179 symbols loaded
    [INFO   ] [Image       ] Providers: img_tex, img_dds, img_gif (img_sdl2, img_pil, img_ffpyplayer ignored)
    [CRITICAL] [Window      ] Unable to find any valuable Window provider at all!
    egl_rpi - ImportError: cannot import name bcm
...

However, when I run a file from an interactive python session using execfile('file.py') it works without problems.

Does anyone know how to resolve this issue?

Are you sure you had a clean installation? try this in your virtual environment:

hg clone https://bitbucket.org/pygame/pygame
cd pygame
python setup.py build
python setup.py install

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM