Open dcjona opened 4 years ago
after making the *.yaml
Traceback (most recent call last):
File "/usr/lib/python2.7/runpy.py", line 174, in _run_module_as_main
"__main__", fname, loader, pkg_name)
File "/usr/lib/python2.7/runpy.py", line 72, in _run_code
exec code in run_globals
File "/root/infopanel/infopanel/__main__.py", line 3, in <module>
from infopanel import driver
File "infopanel/driver.py", line 11, in <module>
from infopanel import mqtt, scenes, config, display, sprites, data
File "infopanel/scenes.py", line 10, in <module>
from infopanel import sprites, helpers
File "infopanel/sprites.py", line 10, in <module>
from PIL import Image as PILImage
ImportError: No module named PIL
Ok it looks like there are some python incompatibility issues there. The first errors you're seeing due to type annotations, which were introduced around 2015. While infopanel is supposed to be compatible with python2 and python3, it looks like some of the dependencies are assuming python3 now. Can you try with python3
instead of python
?
I also do recommend using a virtualenv rather than sudo
in case it interferes with other packages on your system.
What version of python3
are you using? python3 --version
.
hello, i use Python 3.7.3
if i try to use python3, i get this :
root@DietPi:~/infopanel# python3 setup.py install
Traceback (most recent call last):
File "setup.py", line 1, in <module>
from setuptools import setup, find_packages
ModuleNotFoundError: No module named 'setuptools'
Interesting. Can you try the solution listed in this SO post to that one?
Namely: sudo apt-get install python3-setuptools
If that helps I guess I can add that to the list of dependencies.
It seems to install but get many errors
running install
running bdist_egg
running egg_info
writing infopanel.egg-info/PKG-INFO
writing dependency_links to infopanel.egg-info/dependency_links.txt
writing requirements to infopanel.egg-info/requires.txt
writing top-level names to infopanel.egg-info/top_level.txt
reading manifest file 'infopanel.egg-info/SOURCES.txt'
reading manifest template 'MANIFEST.in'
writing manifest file 'infopanel.egg-info/SOURCES.txt'
installing library code to build/bdist.linux-armv7l/egg
running install_lib
running build_py
creating build/lib
creating build/lib/infopanel
copying infopanel/helpers.py -> build/lib/infopanel
copying infopanel/mqtt.py -> build/lib/infopanel
copying infopanel/driver.py -> build/lib/infopanel
copying infopanel/data.py -> build/lib/infopanel
copying infopanel/colors.py -> build/lib/infopanel
copying infopanel/scenes.py -> build/lib/infopanel
copying infopanel/sprites.py -> build/lib/infopanel
copying infopanel/display.py -> build/lib/infopanel
copying infopanel/__main__.py -> build/lib/infopanel
copying infopanel/config.py -> build/lib/infopanel
copying infopanel/__init__.py -> build/lib/infopanel
creating build/lib/infopanel/tests
copying infopanel/tests/test_mqtt.py -> build/lib/infopanel/tests
copying infopanel/tests/test_sprites.py -> build/lib/infopanel/tests
copying infopanel/tests/test_scenes.py -> build/lib/infopanel/tests
copying infopanel/tests/test_driver.py -> build/lib/infopanel/tests
copying infopanel/tests/dummy_screen.py -> build/lib/infopanel/tests
copying infopanel/tests/__init__.py -> build/lib/infopanel/tests
copying infopanel/tests/test_config.yaml -> build/lib/infopanel/tests
creating build/bdist.linux-armv7l/egg
creating build/bdist.linux-armv7l/egg/infopanel
copying build/lib/infopanel/helpers.py -> build/bdist.linux-armv7l/egg/infopanel
copying build/lib/infopanel/mqtt.py -> build/bdist.linux-armv7l/egg/infopanel
copying build/lib/infopanel/driver.py -> build/bdist.linux-armv7l/egg/infopanel
copying build/lib/infopanel/data.py -> build/bdist.linux-armv7l/egg/infopanel
copying build/lib/infopanel/colors.py -> build/bdist.linux-armv7l/egg/infopanel
copying build/lib/infopanel/scenes.py -> build/bdist.linux-armv7l/egg/infopanel
creating build/bdist.linux-armv7l/egg/infopanel/tests
copying build/lib/infopanel/tests/test_config.yaml -> build/bdist.linux-armv7l/egg/infopanel/tests
copying build/lib/infopanel/tests/test_mqtt.py -> build/bdist.linux-armv7l/egg/infopanel/tests
copying build/lib/infopanel/tests/test_sprites.py -> build/bdist.linux-armv7l/egg/infopanel/tests
copying build/lib/infopanel/tests/test_scenes.py -> build/bdist.linux-armv7l/egg/infopanel/tests
copying build/lib/infopanel/tests/test_driver.py -> build/bdist.linux-armv7l/egg/infopanel/tests
copying build/lib/infopanel/tests/dummy_screen.py -> build/bdist.linux-armv7l/egg/infopanel/tests
copying build/lib/infopanel/tests/__init__.py -> build/bdist.linux-armv7l/egg/infopanel/tests
copying build/lib/infopanel/sprites.py -> build/bdist.linux-armv7l/egg/infopanel
copying build/lib/infopanel/display.py -> build/bdist.linux-armv7l/egg/infopanel
copying build/lib/infopanel/__main__.py -> build/bdist.linux-armv7l/egg/infopanel
copying build/lib/infopanel/config.py -> build/bdist.linux-armv7l/egg/infopanel
copying build/lib/infopanel/__init__.py -> build/bdist.linux-armv7l/egg/infopanel
byte-compiling build/bdist.linux-armv7l/egg/infopanel/helpers.py to helpers.cpython-37.pyc
byte-compiling build/bdist.linux-armv7l/egg/infopanel/mqtt.py to mqtt.cpython-37.pyc
byte-compiling build/bdist.linux-armv7l/egg/infopanel/driver.py to driver.cpython-37.pyc
byte-compiling build/bdist.linux-armv7l/egg/infopanel/data.py to data.cpython-37.pyc
byte-compiling build/bdist.linux-armv7l/egg/infopanel/colors.py to colors.cpython-37.pyc
byte-compiling build/bdist.linux-armv7l/egg/infopanel/scenes.py to scenes.cpython-37.pyc
byte-compiling build/bdist.linux-armv7l/egg/infopanel/tests/test_mqtt.py to test_mqtt.cpython-37.pyc
byte-compiling build/bdist.linux-armv7l/egg/infopanel/tests/test_sprites.py to test_sprites.cpython-37.pyc
byte-compiling build/bdist.linux-armv7l/egg/infopanel/tests/test_scenes.py to test_scenes.cpython-37.pyc
byte-compiling build/bdist.linux-armv7l/egg/infopanel/tests/test_driver.py to test_driver.cpython-37.pyc
byte-compiling build/bdist.linux-armv7l/egg/infopanel/tests/dummy_screen.py to dummy_screen.cpython-37.pyc
byte-compiling build/bdist.linux-armv7l/egg/infopanel/tests/__init__.py to __init__.cpython-37.pyc
byte-compiling build/bdist.linux-armv7l/egg/infopanel/sprites.py to sprites.cpython-37.pyc
byte-compiling build/bdist.linux-armv7l/egg/infopanel/display.py to display.cpython-37.pyc
byte-compiling build/bdist.linux-armv7l/egg/infopanel/__main__.py to __main__.cpython-37.pyc
byte-compiling build/bdist.linux-armv7l/egg/infopanel/config.py to config.cpython-37.pyc
byte-compiling build/bdist.linux-armv7l/egg/infopanel/__init__.py to __init__.cpython-37.pyc
creating build/bdist.linux-armv7l/egg/EGG-INFO
copying infopanel.egg-info/PKG-INFO -> build/bdist.linux-armv7l/egg/EGG-INFO
copying infopanel.egg-info/SOURCES.txt -> build/bdist.linux-armv7l/egg/EGG-INFO
copying infopanel.egg-info/dependency_links.txt -> build/bdist.linux-armv7l/egg/EGG-INFO
copying infopanel.egg-info/requires.txt -> build/bdist.linux-armv7l/egg/EGG-INFO
copying infopanel.egg-info/top_level.txt -> build/bdist.linux-armv7l/egg/EGG-INFO
zip_safe flag not set; analyzing archive contents...
infopanel.tests.__pycache__.__init__.cpython-37: module references __file__
creating 'dist/infopanel-0.1-py3.7.egg' and adding 'build/bdist.linux-armv7l/egg' to it
removing 'build/bdist.linux-armv7l/egg' (and everything under it)
Processing infopanel-0.1-py3.7.egg
creating /usr/local/lib/python3.7/dist-packages/infopanel-0.1-py3.7.egg
Extracting infopanel-0.1-py3.7.egg to /usr/local/lib/python3.7/dist-packages
Adding infopanel 0.1 to easy-install.pth file
Installed /usr/local/lib/python3.7/dist-packages/infopanel-0.1-py3.7.egg
Processing dependencies for infopanel==0.1
Searching for voluptuous>=0.9.3
Reading https://pypi.org/simple/voluptuous/
Downloading https://files.pythonhosted.org/packages/24/3b/fe531688c0d9e057fccc0bc9430c0a3d4b90e0d2f015326e659c2944e328/voluptuous-0.11.7.tar.gz#sha256=2abc341dbc740c5e2302c7f9b8e2e243194fb4772585b991931cb5b22e9bf456
Best match: voluptuous 0.11.7
Processing voluptuous-0.11.7.tar.gz
Writing /tmp/easy_install-fbevpysl/voluptuous-0.11.7/setup.cfg
Running voluptuous-0.11.7/setup.py -q bdist_egg --dist-dir /tmp/easy_install-fbevpysl/voluptuous-0.11.7/egg-dist-tmp-uijcppr9
zip_safe flag not set; analyzing archive contents...
Moving voluptuous-0.11.7-py3.7.egg to /usr/local/lib/python3.7/dist-packages
Adding voluptuous 0.11.7 to easy-install.pth file
Installed /usr/local/lib/python3.7/dist-packages/voluptuous-0.11.7-py3.7.egg
Searching for pytest
Reading https://pypi.org/simple/pytest/
Downloading https://files.pythonhosted.org/packages/9f/f3/0a83558da436a081344aa6c8b85ea5b5f05071214106036ce341b7769b0b/pytest-5.4.3-py3-none-any.whl#sha256=5c0db86b698e8f170ba4582a492248919255fcd4c79b1ee64ace34301fb589a1
Best match: pytest 5.4.3
Processing pytest-5.4.3-py3-none-any.whl
Installing pytest-5.4.3-py3-none-any.whl to /usr/local/lib/python3.7/dist-packages
writing requirements to /usr/local/lib/python3.7/dist-packages/pytest-5.4.3-py3.7.egg/EGG-INFO/requires.txt
Adding pytest 5.4.3 to easy-install.pth file
Installing py.test script to /usr/local/bin
Installing pytest script to /usr/local/bin
Installed /usr/local/lib/python3.7/dist-packages/pytest-5.4.3-py3.7.egg
Searching for pydocstyle
Reading https://pypi.org/simple/pydocstyle/
Downloading https://files.pythonhosted.org/packages/cc/fb/0662498401c663606ef35b4ec6a0aca6b4121d6da8c3ac40a4e68f6ac521/pydocstyle-5.0.2-py3-none-any.whl#sha256=da7831660b7355307b32778c4a0dbfb137d89254ef31a2b2978f50fc0b4d7586
Best match: pydocstyle 5.0.2
Processing pydocstyle-5.0.2-py3-none-any.whl
Installing pydocstyle-5.0.2-py3-none-any.whl to /usr/local/lib/python3.7/dist-packages
writing requirements to /usr/local/lib/python3.7/dist-packages/pydocstyle-5.0.2-py3.7.egg/EGG-INFO/requires.txt
Adding pydocstyle 5.0.2 to easy-install.pth file
Installing pydocstyle script to /usr/local/bin
Installed /usr/local/lib/python3.7/dist-packages/pydocstyle-5.0.2-py3.7.egg
Searching for paho-mqtt
Reading https://pypi.org/simple/paho-mqtt/
Downloading https://files.pythonhosted.org/packages/59/11/1dd5c70f0f27a88a3a05772cd95f6087ac479fac66d9c7752ee5e16ddbbc/paho-mqtt-1.5.0.tar.gz#sha256=e3d286198baaea195c8b3bc221941d25a3ab0e1507fc1779bdb7473806394be4
Best match: paho-mqtt 1.5.0
Processing paho-mqtt-1.5.0.tar.gz
Writing /tmp/easy_install-0c4dg2dh/paho-mqtt-1.5.0/setup.cfg
Running paho-mqtt-1.5.0/setup.py -q bdist_egg --dist-dir /tmp/easy_install-0c4dg2dh/paho-mqtt-1.5.0/egg-dist-tmp-i60vma5b
creating /usr/local/lib/python3.7/dist-packages/paho_mqtt-1.5.0-py3.7.egg
Extracting paho_mqtt-1.5.0-py3.7.egg to /usr/local/lib/python3.7/dist-packages
Adding paho-mqtt 1.5.0 to easy-install.pth file
Installed /usr/local/lib/python3.7/dist-packages/paho_mqtt-1.5.0-py3.7.egg
Searching for matplotlib>=1.0
Reading https://pypi.org/simple/matplotlib/
Downloading https://files.pythonhosted.org/packages/9e/d5/3c08575959065ca475b0df0ef6ae3f0832d3766104be021369a4abf324c6/matplotlib-3.3.0rc1.tar.gz#sha256=2ae5f279e6d9afc25cde907c514b2819bbd8a59551c883aa96777077635127ef
Best match: matplotlib 3.3.0rc1
Processing matplotlib-3.3.0rc1.tar.gz
Writing /tmp/easy_install-_u3tyq_i/matplotlib-3.3.0rc1/setup.cfg
Running matplotlib-3.3.0rc1/setup.py -q bdist_egg --dist-dir /tmp/easy_install-_u3tyq_i/matplotlib-3.3.0rc1/egg-dist-tmp-siit5mtl
Running from numpy source directory.
/tmp/easy_install-_u3tyq_i/matplotlib-3.3.0rc1/temp/easy_install-6cbszu68/numpy-1.19.0/setup.py:460: UserWarning: Unrecognized setuptools command, proceeding with generating Cython sources and expanding templates
run_build = parse_setuppy_commands()
Cythonizing sources
Processing numpy/random/_bounded_integers.pxd.in
Processing numpy/random/mtrand.pyx
Traceback (most recent call last):
File "/tmp/easy_install-_u3tyq_i/matplotlib-3.3.0rc1/temp/easy_install-6cbszu68/numpy-1.19.0/tools/cythonize.py", line 59, in process_pyx
from Cython.Compiler.Version import version as cython_version
ModuleNotFoundError: No module named 'Cython'
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "/tmp/easy_install-_u3tyq_i/matplotlib-3.3.0rc1/temp/easy_install-6cbszu68/numpy-1.19.0/tools/cythonize.py", line 235, in <module>
main()
File "/tmp/easy_install-_u3tyq_i/matplotlib-3.3.0rc1/temp/easy_install-6cbszu68/numpy-1.19.0/tools/cythonize.py", line 231, in main
find_process_files(root_dir)
File "/tmp/easy_install-_u3tyq_i/matplotlib-3.3.0rc1/temp/easy_install-6cbszu68/numpy-1.19.0/tools/cythonize.py", line 222, in find_process_files
process(root_dir, fromfile, tofile, function, hash_db)
File "/tmp/easy_install-_u3tyq_i/matplotlib-3.3.0rc1/temp/easy_install-6cbszu68/numpy-1.19.0/tools/cythonize.py", line 188, in process
processor_function(fromfile, tofile)
File "/tmp/easy_install-_u3tyq_i/matplotlib-3.3.0rc1/temp/easy_install-6cbszu68/numpy-1.19.0/tools/cythonize.py", line 64, in process_pyx
raise OSError('Cython needs to be installed in Python as a module')
OSError: Cython needs to be installed in Python as a module
Traceback (most recent call last):
File "/usr/lib/python3/dist-packages/setuptools/sandbox.py", line 154, in save_modules
yield saved
File "/usr/lib/python3/dist-packages/setuptools/sandbox.py", line 195, in setup_context
yield
File "/usr/lib/python3/dist-packages/setuptools/sandbox.py", line 250, in run_setup
_execfile(setup_script, ns)
File "/usr/lib/python3/dist-packages/setuptools/sandbox.py", line 45, in _execfile
exec(code, globals, locals)
File "/tmp/easy_install-_u3tyq_i/matplotlib-3.3.0rc1/temp/easy_install-6cbszu68/numpy-1.19.0/setup.py", line 489, in <module>
File "/tmp/easy_install-_u3tyq_i/matplotlib-3.3.0rc1/temp/easy_install-6cbszu68/numpy-1.19.0/setup.py", line 469, in setup_package
File "/tmp/easy_install-_u3tyq_i/matplotlib-3.3.0rc1/temp/easy_install-6cbszu68/numpy-1.19.0/setup.py", line 274, in generate_cython
RuntimeError: Running cythonize failed!
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "/usr/lib/python3/dist-packages/setuptools/sandbox.py", line 154, in save_modules
yield saved
File "/usr/lib/python3/dist-packages/setuptools/sandbox.py", line 195, in setup_context
yield
File "/usr/lib/python3/dist-packages/setuptools/sandbox.py", line 250, in run_setup
_execfile(setup_script, ns)
File "/usr/lib/python3/dist-packages/setuptools/sandbox.py", line 45, in _execfile
exec(code, globals, locals)
File "/tmp/easy_install-_u3tyq_i/matplotlib-3.3.0rc1/setup.py", line 289, in <module>
File "/usr/lib/python3/dist-packages/setuptools/__init__.py", line 144, in setup
_install_setup_requires(attrs)
File "/usr/lib/python3/dist-packages/setuptools/__init__.py", line 139, in _install_setup_requires
dist.fetch_build_eggs(dist.setup_requires)
File "/usr/lib/python3/dist-packages/setuptools/dist.py", line 724, in fetch_build_eggs
replace_conflicting=True,
File "/usr/lib/python3/dist-packages/pkg_resources/__init__.py", line 782, in resolve
replace_conflicting=replace_conflicting
File "/usr/lib/python3/dist-packages/pkg_resources/__init__.py", line 1065, in best_match
return self.obtain(req, installer)
File "/usr/lib/python3/dist-packages/pkg_resources/__init__.py", line 1077, in obtain
return installer(requirement)
File "/usr/lib/python3/dist-packages/setuptools/dist.py", line 791, in fetch_build_egg
return cmd.easy_install(req)
File "/usr/lib/python3/dist-packages/setuptools/command/easy_install.py", line 704, in easy_install
return self.install_item(spec, dist.location, tmpdir, deps)
File "/usr/lib/python3/dist-packages/setuptools/command/easy_install.py", line 730, in install_item
dists = self.install_eggs(spec, download, tmpdir)
File "/usr/lib/python3/dist-packages/setuptools/command/easy_install.py", line 915, in install_eggs
return self.build_and_install(setup_script, setup_base)
File "/usr/lib/python3/dist-packages/setuptools/command/easy_install.py", line 1183, in build_and_install
self.run_setup(setup_script, setup_base, args)
File "/usr/lib/python3/dist-packages/setuptools/command/easy_install.py", line 1169, in run_setup
run_setup(setup_script, args)
File "/usr/lib/python3/dist-packages/setuptools/sandbox.py", line 253, in run_setup
raise
File "/usr/lib/python3.7/contextlib.py", line 130, in __exit__
self.gen.throw(type, value, traceback)
File "/usr/lib/python3/dist-packages/setuptools/sandbox.py", line 195, in setup_context
yield
File "/usr/lib/python3.7/contextlib.py", line 130, in __exit__
self.gen.throw(type, value, traceback)
File "/usr/lib/python3/dist-packages/setuptools/sandbox.py", line 166, in save_modules
saved_exc.resume()
File "/usr/lib/python3/dist-packages/setuptools/sandbox.py", line 141, in resume
six.reraise(type, exc, self._tb)
File "/usr/lib/python3/dist-packages/setuptools/_vendor/six.py", line 685, in reraise
raise value.with_traceback(tb)
File "/usr/lib/python3/dist-packages/setuptools/sandbox.py", line 154, in save_modules
yield saved
File "/usr/lib/python3/dist-packages/setuptools/sandbox.py", line 195, in setup_context
yield
File "/usr/lib/python3/dist-packages/setuptools/sandbox.py", line 250, in run_setup
_execfile(setup_script, ns)
File "/usr/lib/python3/dist-packages/setuptools/sandbox.py", line 45, in _execfile
exec(code, globals, locals)
File "/tmp/easy_install-_u3tyq_i/matplotlib-3.3.0rc1/temp/easy_install-6cbszu68/numpy-1.19.0/setup.py", line 489, in <module>
File "/tmp/easy_install-_u3tyq_i/matplotlib-3.3.0rc1/temp/easy_install-6cbszu68/numpy-1.19.0/setup.py", line 469, in setup_package
File "/tmp/easy_install-_u3tyq_i/matplotlib-3.3.0rc1/temp/easy_install-6cbszu68/numpy-1.19.0/setup.py", line 274, in generate_cython
RuntimeError: Running cythonize failed!
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "setup.py", line 37, in <module>
include_package_data=True
File "/usr/lib/python3/dist-packages/setuptools/__init__.py", line 145, in setup
return distutils.core.setup(**attrs)
File "/usr/lib/python3.7/distutils/core.py", line 148, in setup
dist.run_commands()
File "/usr/lib/python3.7/distutils/dist.py", line 966, in run_commands
self.run_command(cmd)
File "/usr/lib/python3.7/distutils/dist.py", line 985, in run_command
cmd_obj.run()
File "/usr/lib/python3/dist-packages/setuptools/command/install.py", line 67, in run
self.do_egg_install()
File "/usr/lib/python3/dist-packages/setuptools/command/install.py", line 117, in do_egg_install
cmd.run()
File "/usr/lib/python3/dist-packages/setuptools/command/easy_install.py", line 443, in run
self.easy_install(spec, not self.no_deps)
File "/usr/lib/python3/dist-packages/setuptools/command/easy_install.py", line 685, in easy_install
return self.install_item(None, spec, tmpdir, deps, True)
File "/usr/lib/python3/dist-packages/setuptools/command/easy_install.py", line 732, in install_item
self.process_distribution(spec, dist, deps)
File "/usr/lib/python3/dist-packages/setuptools/command/easy_install.py", line 777, in process_distribution
[requirement], self.local_index, self.easy_install
File "/usr/lib/python3/dist-packages/pkg_resources/__init__.py", line 782, in resolve
replace_conflicting=replace_conflicting
File "/usr/lib/python3/dist-packages/pkg_resources/__init__.py", line 1065, in best_match
return self.obtain(req, installer)
File "/usr/lib/python3/dist-packages/pkg_resources/__init__.py", line 1077, in obtain
return installer(requirement)
File "/usr/lib/python3/dist-packages/setuptools/command/easy_install.py", line 704, in easy_install
return self.install_item(spec, dist.location, tmpdir, deps)
File "/usr/lib/python3/dist-packages/setuptools/command/easy_install.py", line 730, in install_item
dists = self.install_eggs(spec, download, tmpdir)
File "/usr/lib/python3/dist-packages/setuptools/command/easy_install.py", line 915, in install_eggs
return self.build_and_install(setup_script, setup_base)
File "/usr/lib/python3/dist-packages/setuptools/command/easy_install.py", line 1183, in build_and_install
self.run_setup(setup_script, setup_base, args)
File "/usr/lib/python3/dist-packages/setuptools/command/easy_install.py", line 1169, in run_setup
run_setup(setup_script, args)
File "/usr/lib/python3/dist-packages/setuptools/sandbox.py", line 253, in run_setup
raise
File "/usr/lib/python3.7/contextlib.py", line 130, in __exit__
self.gen.throw(type, value, traceback)
File "/usr/lib/python3/dist-packages/setuptools/sandbox.py", line 195, in setup_context
yield
File "/usr/lib/python3.7/contextlib.py", line 130, in __exit__
self.gen.throw(type, value, traceback)
File "/usr/lib/python3/dist-packages/setuptools/sandbox.py", line 166, in save_modules
saved_exc.resume()
File "/usr/lib/python3/dist-packages/setuptools/sandbox.py", line 141, in resume
six.reraise(type, exc, self._tb)
File "/usr/lib/python3/dist-packages/setuptools/_vendor/six.py", line 685, in reraise
raise value.with_traceback(tb)
File "/usr/lib/python3/dist-packages/setuptools/sandbox.py", line 154, in save_modules
yield saved
File "/usr/lib/python3/dist-packages/setuptools/sandbox.py", line 195, in setup_context
yield
File "/usr/lib/python3/dist-packages/setuptools/sandbox.py", line 250, in run_setup
_execfile(setup_script, ns)
File "/usr/lib/python3/dist-packages/setuptools/sandbox.py", line 45, in _execfile
exec(code, globals, locals)
File "/tmp/easy_install-_u3tyq_i/matplotlib-3.3.0rc1/setup.py", line 289, in <module>
File "/usr/lib/python3/dist-packages/setuptools/__init__.py", line 144, in setup
_install_setup_requires(attrs)
File "/usr/lib/python3/dist-packages/setuptools/__init__.py", line 139, in _install_setup_requires
dist.fetch_build_eggs(dist.setup_requires)
File "/usr/lib/python3/dist-packages/setuptools/dist.py", line 724, in fetch_build_eggs
replace_conflicting=True,
File "/usr/lib/python3/dist-packages/pkg_resources/__init__.py", line 782, in resolve
replace_conflicting=replace_conflicting
File "/usr/lib/python3/dist-packages/pkg_resources/__init__.py", line 1065, in best_match
return self.obtain(req, installer)
File "/usr/lib/python3/dist-packages/pkg_resources/__init__.py", line 1077, in obtain
return installer(requirement)
File "/usr/lib/python3/dist-packages/setuptools/dist.py", line 791, in fetch_build_egg
return cmd.easy_install(req)
File "/usr/lib/python3/dist-packages/setuptools/command/easy_install.py", line 704, in easy_install
return self.install_item(spec, dist.location, tmpdir, deps)
File "/usr/lib/python3/dist-packages/setuptools/command/easy_install.py", line 730, in install_item
dists = self.install_eggs(spec, download, tmpdir)
File "/usr/lib/python3/dist-packages/setuptools/command/easy_install.py", line 915, in install_eggs
return self.build_and_install(setup_script, setup_base)
File "/usr/lib/python3/dist-packages/setuptools/command/easy_install.py", line 1183, in build_and_install
self.run_setup(setup_script, setup_base, args)
File "/usr/lib/python3/dist-packages/setuptools/command/easy_install.py", line 1169, in run_setup
run_setup(setup_script, args)
File "/usr/lib/python3/dist-packages/setuptools/sandbox.py", line 253, in run_setup
raise
File "/usr/lib/python3.7/contextlib.py", line 130, in __exit__
self.gen.throw(type, value, traceback)
File "/usr/lib/python3/dist-packages/setuptools/sandbox.py", line 195, in setup_context
yield
File "/usr/lib/python3.7/contextlib.py", line 130, in __exit__
self.gen.throw(type, value, traceback)
File "/usr/lib/python3/dist-packages/setuptools/sandbox.py", line 166, in save_modules
saved_exc.resume()
File "/usr/lib/python3/dist-packages/setuptools/sandbox.py", line 141, in resume
six.reraise(type, exc, self._tb)
File "/usr/lib/python3/dist-packages/setuptools/_vendor/six.py", line 685, in reraise
raise value.with_traceback(tb)
File "/usr/lib/python3/dist-packages/setuptools/sandbox.py", line 154, in save_modules
yield saved
File "/usr/lib/python3/dist-packages/setuptools/sandbox.py", line 195, in setup_context
yield
File "/usr/lib/python3/dist-packages/setuptools/sandbox.py", line 250, in run_setup
_execfile(setup_script, ns)
File "/usr/lib/python3/dist-packages/setuptools/sandbox.py", line 45, in _execfile
exec(code, globals, locals)
File "/tmp/easy_install-_u3tyq_i/matplotlib-3.3.0rc1/temp/easy_install-6cbszu68/numpy-1.19.0/setup.py", line 489, in <module>
File "/tmp/easy_install-_u3tyq_i/matplotlib-3.3.0rc1/temp/easy_install-6cbszu68/numpy-1.19.0/setup.py", line 469, in setup_package
File "/tmp/easy_install-_u3tyq_i/matplotlib-3.3.0rc1/temp/easy_install-6cbszu68/numpy-1.19.0/setup.py", line 274, in generate_cython
RuntimeError: Running cythonize failed!
That's installing numpy
which should have been installed when you ran the initial apt installs (it's a dependency of matplotlib I believe). The instructions have you install the python2 ones but let's try installing the python3 ones. I will update the instructions if this works:
sudo apt-get install libyaml-dev python3-setuptools python3-matplotlib python3-numpy
Then re-run the python3 setup.py install
line.
thank you installation is ok now, i'm not in venv so i try to creater the infopanel.yaml directly in the directeroy infopanel. adapt my config and then :
root@DietPi:~/infopanel# python3 -m infopanel --config infopanel.yaml
/root/infopanel/infopanel/config.py:68: YAMLLoadWarning: calling yaml.load() without Loader=... is deprecated, as the default Loader is unsafe. Please read https://msg. pyyaml.org/load for full details.
config = yaml.load(configfile)
Traceback (most recent call last):
File "/usr/lib/python3.7/runpy.py", line 193, in _run_module_as_main
"__main__", mod_spec)
File "/usr/lib/python3.7/runpy.py", line 85, in _run_code
exec(code, run_globals)
File "/root/infopanel/infopanel/__main__.py", line 4, in <module>
driver.run()
File "/root/infopanel/infopanel/driver.py", line 229, in run
conf = config.load_config_yaml(conf_file)
File "/root/infopanel/infopanel/config.py", line 68, in load_config_yaml
config = yaml.load(configfile)
File "/usr/local/lib/python3.7/dist-packages/PyYAML-5.3.1-py3.7-linux-armv7l.egg/y aml/__init__.py", line 114, in load
return loader.get_single_data()
File "/usr/local/lib/python3.7/dist-packages/PyYAML-5.3.1-py3.7-linux-armv7l.egg/y aml/constructor.py", line 49, in get_single_data
node = self.get_single_node()
File "/usr/local/lib/python3.7/dist-packages/PyYAML-5.3.1-py3.7-linux-armv7l.egg/y aml/composer.py", line 36, in get_single_node
document = self.compose_document()
File "/usr/local/lib/python3.7/dist-packages/PyYAML-5.3.1-py3.7-linux-armv7l.egg/y aml/composer.py", line 55, in compose_document
node = self.compose_node(None, None)
File "/usr/local/lib/python3.7/dist-packages/PyYAML-5.3.1-py3.7-linux-armv7l.egg/y aml/composer.py", line 84, in compose_node
node = self.compose_mapping_node(anchor)
File "/usr/local/lib/python3.7/dist-packages/PyYAML-5.3.1-py3.7-linux-armv7l.egg/y aml/composer.py", line 127, in compose_mapping_node
while not self.check_event(MappingEndEvent):
File "/usr/local/lib/python3.7/dist-packages/PyYAML-5.3.1-py3.7-linux-armv7l.egg/y aml/parser.py", line 98, in check_event
self.current_event = self.state()
File "/usr/local/lib/python3.7/dist-packages/PyYAML-5.3.1-py3.7-linux-armv7l.egg/y aml/parser.py", line 439, in parse_block_mapping_key
"expected <block end>, but found %r" % token.id, token.start_mark)
yaml.parser.ParserError: while parsing a block mapping
in "infopanel.yaml", line 1, column 1
expected <block end>, but found '<block mapping start>'
in "infopanel.yaml", line 39, column 2
root@DietPi:~/infopanel#
as i use dietpi normaly no need to use sudo as i'm logged in root
Installation complete, hooray! I changed the README a little to point to python3 in a94c937611a3b09d39faa, which should help future users.
Now it looks like it's complaining about the format of the YAML file now as it reads the settings. Can you paste your yaml content into a validator like this one to see if it has any clear syntax issues?
yes installation is ok now 👍
i try to paste mine and yours but : (
This is the test config that comes with infopanel. If you copy and paste it verbatim into the validator linked above it comes back as valid.
Does yours look different than this?
ok thanks again, my yaml is valid , i just change the mqtt info, next trying to launch the infopanel.yaml i get this :
config = yaml.load(configfile)
Traceback (most recent call last):
File "/usr/lib/python3.7/runpy.py", line 193, in _run_module_as_main
"__main__", mod_spec)
File "/usr/lib/python3.7/runpy.py", line 85, in _run_code
exec(code, run_globals)
File "/root/infopanel/infopanel/__main__.py", line 4, in <module>
driver.run()
File "/root/infopanel/infopanel/driver.py", line 231, in run
disp = display.display_factory(conf)
File "/root/infopanel/infopanel/display.py", line 156, in display_factory
from infopanel.tests import dummy_screen # pylint: disable=import-outside-toplevel, cyclic-import
File "/root/infopanel/infopanel/tests/dummy_screen.py", line 9, in <module>
import pygame
ModuleNotFoundError: No module named 'pygame'
This means that you have DummyMatrix
in your config, and so it will load a dummy screen from pygame, and so you need to apt install python3-pygame
or pip install it. On the other hand, if you are trying to use an actual LCD matrix, you should remove DummyMatrix
from your config and replace it with RGBMatrix
with the appropriate options.
ok i will try to find the correct matrix code thank you but this message is normal .?
/usr/local/lib/python3.7/dist-packages/infopanel-0.1-py3.7.egg/infopanel/config.py:68: YAMLLoadWarning: calling yaml.load() without Loader=... is deprecated, as the default Loader is unsafe. Please read https://msg.pyyaml.org/load for full details.
config = yaml.load(configfile)
if i change to RGB matrix :
/root/infopanel/infopanel/config.py:68: YAMLLoadWarning: calling yaml.load() without Loader=... is deprecated, as the default Loader is unsafe. Please read https://msg.pyyaml.org/load for full details.
config = yaml.load(configfile)
INFO:infopanel.driver:Starting InfoPanel.
Traceback (most recent call last):
File "/usr/lib/python3.7/runpy.py", line 193, in _run_module_as_main
"__main__", mod_spec)
File "/usr/lib/python3.7/runpy.py", line 85, in _run_code
exec(code, run_globals)
File "/root/infopanel/infopanel/__main__.py", line 4, in <module>
File "/root/infopanel/infopanel/driver.py", line 233, in run
File "/root/infopanel/infopanel/driver.py", line 208, in driver_factory
File "/root/infopanel/infopanel/sprites.py", line 682, in sprite_factory
File "/root/infopanel/infopanel/sprites.py", line 372, in apply_config
File "/root/infopanel/infopanel/sprites.py", line 295, in apply_config
File "/root/infopanel/infopanel/sprites.py", line 98, in apply_config
File "/root/infopanel/infopanel/helpers.py", line 36, in load_font
File "graphics.pyx", line 32, in rgbmatrix.graphics.Font.LoadFont
Exception: Couldn't load font $RPI_RGB_LED_MATRIX/fonts/5x8.bdf
what works on test with RPI RGB led matrix :
root@DietPi:~/rpi-rgb-led-matrix/examples-api-use# sudo ./demo -D -m 0 --led-no-hardware-pulse --led-gpio-mapping=adafruit-hat --led-slowdown-gpio=2
i see the two squares turning on the matrix :)
Your font_dir
config listed in the config file has to point to a valid path. In your case, the fonts are probably in somewhere like ~/rpi-rgb-led-matrix/fonts
. Find out where the fonts are and point to them in the config.
global:
font_dir: ~/rpi-rgb-led-matrix/fonts
EDIT: got more specific.
but this message is normal .?
That is currently an expected message, though we should update the code to fix the issue it's talking about. Shouldn't be a big problem as long as you aren't loading YAML config files from untrusted sources.
i try to fix it by copying directly in infopanel folder but same issue :
/root/infopanel/infopanel/config.py:68: YAMLLoadWarning: calling yaml.load() without Loader=... is deprecated, as the default Loader is unsafe. Please read https://msg.pyyaml.org/load for full details.
config = yaml.load(configfile)
INFO:infopanel.driver:Starting InfoPanel.
Traceback (most recent call last):
File "/usr/lib/python3.7/runpy.py", line 193, in _run_module_as_main
"__main__", mod_spec)
File "/usr/lib/python3.7/runpy.py", line 85, in _run_code
exec(code, run_globals)
File "/root/infopanel/infopanel/__main__.py", line 4, in <module>
File "/root/infopanel/infopanel/driver.py", line 233, in run
File "/root/infopanel/infopanel/driver.py", line 208, in driver_factory
File "/root/infopanel/infopanel/sprites.py", line 682, in sprite_factory
File "/root/infopanel/infopanel/sprites.py", line 372, in apply_config
File "/root/infopanel/infopanel/sprites.py", line 295, in apply_config
File "/root/infopanel/infopanel/sprites.py", line 98, in apply_config
File "/root/infopanel/infopanel/helpers.py", line 36, in load_font
File "graphics.pyx", line 32, in rgbmatrix.graphics.Font.LoadFont
Exception: Couldn't load font ~/infopanel/infopanel/5x8.bdf
note that the setting I show above point to a folder, not a full file path. Just set your config font_dir
exactly as I have mine shown above and it will find the fonts in the rgb library's folder.
Though if you did copy the font and point to that folder it should have worked. Can you confirm the font is there by showing the output of:
ls ~/infopanel/infopanel
Hello, yes font is present :
5x8.bdf __main__.py config.py driver.py mqtt.py scenes.pyc tests
__init__.py __pycache__ data.py driver.pyc mqtt.pyc sprites.py
__init__.pyc colors.py display.py helpers.py scenes.py sprites.pyc
mine point to a folder too :
10x20.bdf 6x12.bdf 7x13.bdf 8x13.bdf 9x18.bdf clR6x12.bdf
4x6.bdf 6x13.bdf 7x13B.bdf 8x13B.bdf 9x18B.bdf helvR12.bdf
5x7.bdf 6x13B.bdf 7x13O.bdf 8x13O.bdf AUTHORS texgyre-27.bdf
5x8.bdf 6x13O.bdf 7x14.bdf 9x15.bdf README tom-thumb.bdf
6x10.bdf 6x9.bdf 7x14B.bdf 9x15B.bdf README.md
here is the config yaml :
global:
font_dir: ~/rpi-rgb-led-matrix/fonts
default_mode: morning
and the begining of the config (i didn't modify anything else) :
mqtt:
broker: 192.168.100.9
#port: 8883
port: 1883
client_id: screen
keepalive: 60
username: dcjona
password: password
#certificate: /etc/ssl/certs/DST_Root_CA_X3.pem
topic: sryled/#
RGBMatrix:
led-rows: 32
led-cols: 64
led-chain: 1
led-parallel: 1
led-pwm-bits: 11
led-brightness: 100
led-gpio-mapping: adafruit-hat-pwm
led-scan-mode: 1
led-pwm-lsb-nanoseconds: 130
led-show-refresh: false
led-slowdown-gpio: 0
led-no-hardware-pulse: false
Final idea: change the directory to not use the ~
special character and just try a full path, like:
global:
font_dir: /home/pi/rpi-rgb-led-matrix/fonts
default_mode: morning
So did it work? I'm wondering if I should close this issue.
Hello i try to install but have severals error : command :
root@DietPi:~/infopanel# python setup.py install
response :