64 bit installation errors

I’ve been trying to get this working on a pristine new install on an RPI-4 with 64 bit Bullseye, with no success so far.
There appears to be some dependencies missing in the automated installation script (still figuring the specific list out), but the big problem is when it comes to install Kivy 2.0.0. Bullseye ships with a 1.x version of Kivy which is of course too old so the script attempts to upgrade.

When I attempt to run the script it tries to install Kivy-2.0.0. This fails:

[i] Kivy Python library installation check (will be updated)
[✗] Updating Kivy Python library
Error: Unable to install Kivy Python library

Looking in indexes: Simple index, piwheels - Simple index
Collecting kivy==2.0.0
Using cached Kivy-2.0.0.tar.gz (23.7 MB)
Installing build dependencies: started
Installing build dependencies: finished with status ‘done’
Getting requirements to build wheel: started
Getting requirements to build wheel: finished with status ‘error’
error: subprocess-exited-with-error

I get the same result if I try to install Kivy manually:

python3 -m pip install kivy[base]==2.0.0

However if I install Kivy 2.1.0 it succeeds with the update to 2.1.0.

Then when I run the wfpiconsole.sh script again it attempts to downgrade to Kivy 2.0.0 which of course fails with the same error as above.

Can the dependency on Kivy be made to be 2.0.0 or greater? Or is there something about 2.1.0 which breaks things…?

Sorry, I’ve tweaked the install script recently and clearly made a mess of things. Can you try running this command and share all the output that is printed to the terminal?

python3 -m pip install --no-cache-dir kivy[base]==2.0.0

Sure:

root@weatherstation:~# python3 -m pip install --no-cache-dir kivy[base]==2.0.0
Looking in indexes: Simple index, piwheels - Simple index
Collecting kivy[base]==2.0.0
Downloading Kivy-2.0.0.tar.gz (23.7 MB)
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 23.7/23.7 MB 2.1 MB/s eta 0:00:00
Installing build dependencies … done
Getting requirements to build wheel … error
error: subprocess-exited-with-error

× Getting requirements to build wheel did not run successfully.
│ exit code: 1
╰─> [126 lines of output]
[WARNING] [Config ] Older configuration version detected (24 instead of 21)
[WARNING] [Config ] Upgrading configuration in progress.
[INFO ] [Logger ] Record log in /root/.kivy/logs/kivy_23-02-04_9.txt
[INFO ] [Kivy ] v2.0.0
[INFO ] [Kivy ] Installed at “/tmp/pip-install-z0d4vn1e/kivy_c31797065a7c492cacdefa9360269893/kivy/init.py”
[INFO ] [Python ] v3.9.2 (default, Feb 28 2021, 17:03:44)
[GCC 10.2.1 20210110]
[INFO ] [Python ] Interpreter at “/usr/bin/python3”
:374: DeprecationWarning: distutils Version classes are deprecated. Use packaging.version instead.
:377: DeprecationWarning: distutils Version classes are deprecated. Use packaging.version instead.
:381: DeprecationWarning: distutils Version classes are deprecated. Use packaging.version instead.
Current directory is: /tmp/pip-install-z0d4vn1e/kivy_c31797065a7c492cacdefa9360269893
Source and initial build directory is: /tmp/pip-install-z0d4vn1e/kivy_c31797065a7c492cacdefa9360269893
Python path is:
/tmp/pip-install-z0d4vn1e/kivy_c31797065a7c492cacdefa9360269893
/root/.local/lib/python3.9/site-packages/pip/_vendor/pyproject_hooks/_in_process
/tmp/pip-build-env-ya4ru6wk/site
/usr/lib/python39.zip
/usr/lib/python3.9
/usr/lib/python3.9/lib-dynload
/tmp/pip-build-env-ya4ru6wk/overlay/lib/python3.9/site-packages
/tmp/pip-build-env-ya4ru6wk/normal/lib/python3.9/site-packages
/tmp/pip-install-z0d4vn1e/kivy_c31797065a7c492cacdefa9360269893/kivy/modules
/root/.kivy/mods

  Found Cython at /tmp/pip-build-env-ya4ru6wk/overlay/lib/python3.9/site-packages/Cython/__init__.py
  Detected supported Cython version 0.29.21
  Using this graphics system: OpenGL
  GStreamer found via pkg-config
  SDL2 found via pkg-config
  SDL2: found SDL header at /usr/include/SDL2/SDL.h
  SDL2: found SDL_mixer header at /usr/include/SDL2/SDL_mixer.h
  SDL2: found SDL_ttf header at /usr/include/SDL2/SDL_ttf.h
  SDL2: found SDL_image header at /usr/include/SDL2/SDL_image.h
  Pango: pangoft2 found via pkg-config
  {'libraries': ['pangoft2-1.0', 'pango-1.0', 'gobject-2.0', 'glib-2.0', 'harfbuzz', 'fontconfig', 'freetype'], 'include_dirs': ['/tmp/pip-install-z0d4vn1e/kivy_c31797065a7c492cacdefa9360269893/kivy/include', '/usr/include/pango-1.0', '/usr/include/libmount', '/usr/include/blkid', '/usr/include/fribidi', '/usr/include/cairo', '/usr/include/pixman-1', '/usr/include/harfbuzz', '/usr/include/glib-2.0', '/usr/lib/aarch64-linux-gnu/glib-2.0/include', '/usr/include/uuid', '/usr/include/freetype2', '/usr/include/libpng16'], 'library_dirs': [], 'extra_link_args': [], 'extra_compile_args': [], 'depends': ['lib/pango/pangoft2.pxi', 'lib/pango/pangoft2.h']}
  ERROR: Dependency for context.pyx not resolved: config.pxi
  ERROR: Dependency for compiler.pyx not resolved: config.pxi
  ERROR: Dependency for context_instructions.pyx not resolved: config.pxi
  ERROR: Dependency for fbo.pyx not resolved: config.pxi
  ERROR: Dependency for gl_instructions.pyx not resolved: config.pxi
  ERROR: Dependency for instructions.pyx not resolved: config.pxi
  ERROR: Dependency for opengl.pyx not resolved: config.pxi
  ERROR: Dependency for opengl_utils.pyx not resolved: config.pxi
  ERROR: Dependency for shader.pyx not resolved: config.pxi
  ERROR: Dependency for stencil_instructions.pyx not resolved: config.pxi
  ERROR: Dependency for scissor_instructions.pyx not resolved: config.pxi
  ERROR: Dependency for texture.pyx not resolved: config.pxi
  ERROR: Dependency for vbo.pyx not resolved: config.pxi
  ERROR: Dependency for vertex.pyx not resolved: config.pxi
  ERROR: Dependency for vertex_instructions.pyx not resolved: config.pxi
  ERROR: Dependency for cgl.pyx not resolved: config.pxi
  ERROR: Dependency for cgl_mock.pyx not resolved: config.pxi
  ERROR: Dependency for cgl_gl.pyx not resolved: config.pxi
  ERROR: Dependency for cgl_glew.pyx not resolved: config.pxi
  ERROR: Dependency for cgl_sdl2.pyx not resolved: config.pxi
  ERROR: Dependency for svg.pyx not resolved: config.pxi
   Traceback (most recent call last):
     File "/tmp/pip-build-env-ya4ru6wk/overlay/lib/python3.9/site-packages/setuptools/_vendor/packaging/requirements.py", line 35, in __init__
       parsed = parse_requirement(requirement_string)
     File "/tmp/pip-build-env-ya4ru6wk/overlay/lib/python3.9/site-packages/setuptools/_vendor/packaging/_parser.py", line 64, in parse_requirement
       return _parse_requirement(Tokenizer(source, rules=DEFAULT_RULES))
     File "/tmp/pip-build-env-ya4ru6wk/overlay/lib/python3.9/site-packages/setuptools/_vendor/packaging/_parser.py", line 82, in _parse_requirement
       url, specifier, marker = _parse_requirement_details(tokenizer)
     File "/tmp/pip-build-env-ya4ru6wk/overlay/lib/python3.9/site-packages/setuptools/_vendor/packaging/_parser.py", line 126, in _parse_requirement_details
       marker = _parse_requirement_marker(
     File "/tmp/pip-build-env-ya4ru6wk/overlay/lib/python3.9/site-packages/setuptools/_vendor/packaging/_parser.py", line 147, in _parse_requirement_marker
       tokenizer.raise_syntax_error(
     File "/tmp/pip-build-env-ya4ru6wk/overlay/lib/python3.9/site-packages/setuptools/_vendor/packaging/_tokenizer.py", line 163, in raise_syntax_error
       raise ParserSyntaxError(
   setuptools.extern.packaging._tokenizer.ParserSyntaxError: Expected end or semicolon (after name and no valid version specifier)
       sys_platform == "win32"
                    ^
  
   The above exception was the direct cause of the following exception:
  
   Traceback (most recent call last):
     File "/tmp/pip-build-env-ya4ru6wk/overlay/lib/python3.9/site-packages/setuptools/config/setupcfg.py", line 212, in _warn_accidental_env_marker_misconfig
       req = Requirement(parsed[1])
     File "/tmp/pip-build-env-ya4ru6wk/overlay/lib/python3.9/site-packages/setuptools/_vendor/packaging/requirements.py", line 37, in __init__
       raise InvalidRequirement(str(e)) from e
   setuptools.extern.packaging.requirements.InvalidRequirement: Expected end or semicolon (after name and no valid version specifier)
       sys_platform == "win32"
                    ^
  
   The above exception was the direct cause of the following exception:
  
   Traceback (most recent call last):
     File "/root/.local/lib/python3.9/site-packages/pip/_vendor/pyproject_hooks/_in_process/_in_process.py", line 353, in <module>
       main()
     File "/root/.local/lib/python3.9/site-packages/pip/_vendor/pyproject_hooks/_in_process/_in_process.py", line 335, in main
       json_out['return_val'] = hook(**hook_input['kwargs'])
     File "/root/.local/lib/python3.9/site-packages/pip/_vendor/pyproject_hooks/_in_process/_in_process.py", line 118, in get_requires_for_build_wheel
       return hook(config_settings)
     File "/tmp/pip-build-env-ya4ru6wk/overlay/lib/python3.9/site-packages/setuptools/build_meta.py", line 338, in get_requires_for_build_wheel
       return self._get_build_requires(config_settings, requirements=['wheel'])
     File "/tmp/pip-build-env-ya4ru6wk/overlay/lib/python3.9/site-packages/setuptools/build_meta.py", line 320, in _get_build_requires
       self.run_setup()
     File "/tmp/pip-build-env-ya4ru6wk/overlay/lib/python3.9/site-packages/setuptools/build_meta.py", line 484, in run_setup
       super(_BuildMetaLegacyBackend,
     File "/tmp/pip-build-env-ya4ru6wk/overlay/lib/python3.9/site-packages/setuptools/build_meta.py", line 335, in run_setup
       exec(code, locals())
     File "<string>", line 1068, in <module>
     File "/tmp/pip-build-env-ya4ru6wk/overlay/lib/python3.9/site-packages/setuptools/__init__.py", line 107, in setup
       _install_setup_requires(attrs)
     File "/tmp/pip-build-env-ya4ru6wk/overlay/lib/python3.9/site-packages/setuptools/__init__.py", line 78, in _install_setup_requires
       dist.parse_config_files(ignore_option_errors=True)
     File "/tmp/pip-build-env-ya4ru6wk/overlay/lib/python3.9/site-packages/setuptools/dist.py", line 868, in parse_config_files
       setupcfg.parse_configuration(
     File "/tmp/pip-build-env-ya4ru6wk/overlay/lib/python3.9/site-packages/setuptools/config/setupcfg.py", line 163, in parse_configuration
       options.parse()
     File "/tmp/pip-build-env-ya4ru6wk/overlay/lib/python3.9/site-packages/setuptools/config/setupcfg.py", line 508, in parse
       section_parser_method(section_options)
     File "/tmp/pip-build-env-ya4ru6wk/overlay/lib/python3.9/site-packages/setuptools/config/setupcfg.py", line 761, in parse_section_extras_require
       parsed = self._parse_section_to_dict_with_key(
     File "/tmp/pip-build-env-ya4ru6wk/overlay/lib/python3.9/site-packages/setuptools/config/setupcfg.py", line 458, in _parse_section_to_dict_with_key
       value[key] = values_parser(key, val)
     File "/tmp/pip-build-env-ya4ru6wk/overlay/lib/python3.9/site-packages/setuptools/config/setupcfg.py", line 763, in <lambda>
       lambda k, v: self._parse_requirements_list(f"extras_require[{k}]", v)
     File "/tmp/pip-build-env-ya4ru6wk/overlay/lib/python3.9/site-packages/setuptools/config/setupcfg.py", line 642, in _parse_requirements_list
       _warn_accidental_env_marker_misconfig(label, value, parsed)
     File "/tmp/pip-build-env-ya4ru6wk/overlay/lib/python3.9/site-packages/setuptools/config/setupcfg.py", line 217, in _warn_accidental_env_marker_misconfig
       raise InvalidRequirement(msg) from ex
   setuptools.extern.packaging.requirements.InvalidRequirement: One of the parsed requirements in `extras_require[gstreamer]` looks like a valid environment marker: 'sys_platform == "win32"'
   Make sure that the config is correct and check https://setuptools.pypa.io/en/latest/userguide/declarative_config.html#opt-2
  [end of output]

note: This error originates from a subprocess, and is likely not a problem with pip.
error: subprocess-exited-with-error

× Getting requirements to build wheel did not run successfully.
│ exit code: 1
╰─> See above for output.

note: This error originates from a subprocess, and is likely not a problem with pip.
root@weatherstation:~#

And for comparison with kivy 2.1:

root@weatherstation:~# python3 -m pip install --no-cache-dir kivy[base]==2.1.0
Looking in indexes: Simple index, piwheels - Simple index
Requirement already satisfied: kivy[base]==2.1.0 in /usr/local/lib/python3.9/dist-packages (2.1.0)
Requirement already satisfied: Kivy-Garden>=0.1.4 in /usr/local/lib/python3.9/dist-packages (from kivy[base]==2.1.0) (0.1.5)
Requirement already satisfied: pygments in /usr/lib/python3/dist-packages (from kivy[base]==2.1.0) (2.7.1)
Requirement already satisfied: docutils in /usr/lib/python3/dist-packages (from kivy[base]==2.1.0) (0.16)
Requirement already satisfied: pillow in /usr/lib/python3/dist-packages (from kivy[base]==2.1.0) (8.1.2)
Requirement already satisfied: requests in /usr/lib/python3/dist-packages (from Kivy-Garden>=0.1.4->kivy[base]==2.1.0) (2.25.1)
WARNING: Running pip as the ‘root’ user can result in broken permissions and conflicting behaviour with the system package manager. It is recommended to use a virtual environment instead: 12. Virtual Environments and Packages — Python 3.12.0 documentation
root@weatherstation:~#

I also ran into this unrelated issue after changing the script to allow kivy 2.1.0:

[✓] Installing latest version of WeatherFlow PiConsole: v22.12.3
chown: missing operand after ‘/home//wfpiconsole/’
Try ‘chown --help’ for more information.
root@weatherstation:~/wfpi

I’m doing SSH key authentication as root, which means I am not using sudo.

Have you managed to get up and running with v2.1.0? If so, I may wait until I can troubleshoot this when I get home after the weekend

Almost! Everything proceeds much further with kivy 2.1.0 but fails much further down the script at this point:

chown: missing operand after ‘/home//wfpiconsole/’

That looks to be a trivial issue to fix (or workaround) though.

Yep, I think this is almost certainly caused by the fact you are running the install script as a root user. It was never designed to be run like that. Are you sure you need to be running as root user? I also use ssh keys for authentication, but not as a root user, and then I use sudo for elevated privileges

No, no hard requirement. This Pi is built only to run this software and it is in a secured network (with only key based auth) so it’s not a big concern if a script is run as root.

It would be good to add a condition or at least a warning to the installer script if installation as root is not supported or is known to not work :slight_smile:

Good idea, I will add that as a check.

If you have a spare SD card it would be worthwhile trying to run the installer as a non root user. I can’t test the Kivy install error you are seeing at the moment, but it’s possible that it is caused by running as root

Ok, I did that. Brand new install with the Raspberry Pi Imager (1.7.3) and 64 bit desktop Raspberry Pi OS.

This is the first login.

wfpiconsole@192.168.240.146’s password:
Linux weatherstation 5.15.61-v8+ #1579 SMP PREEMPT Fri Aug 26 11:16:44 BST 2022 aarch64

The programs included with the Debian GNU/Linux system are free software;
the exact distribution terms for each program are described in the
individual files in /usr/share/doc/*/copyright.

Debian GNU/Linux comes with ABSOLUTELY NO WARRANTY, to the extent
permitted by applicable law.
Last login: Thu Sep 22 13:17:58 2022

Wi-Fi is currently blocked by rfkill.
Use raspi-config to set the country before use.

wfpiconsole@weatherstation:~ $ curl -sSL https://peted-davis.github.io/wfpiconsole | bash

[✓] Root user check passed
[✓] Hardware check passed (aarch64)
[✓] OS check passed (Debian GNU/Linux 11 (bullseye))

================================
Installing WeatherFlow PiConsole

[✓] Checking for updated packages
[i] 122 updated packages available. Use ‘sudo apt upgrade’ to install

[i] WeatherFlow PiConsole dependency checks…
[✓] Checking for git
[✓] Checking for curl
[✓] Checking for rng-tools
[✓] Checking for build-essential
[✓] Checking for python3-dev
[✓] Checking for python3-pip
[✓] Checking for python3-setuptools
[i] Checking for libssl-dev (will be installed)
[i] Checking for libffi-dev (will be installed)
[i] Checking for libatlas-base-dev (will be installed)
[i] Checking for jq (will be installed)

[i] Installing WeatherFlow PiConsole Python modules…
[✓] Updating Python package manager
[✓] Installing Python module cython
[✓] Installing Python module websockets
[✓] Installing Python module numpy
[✓] Installing Python module pytz
[✓] Installing Python module ephem
[✓] Installing Python module packaging
[✓] Installing Python module cryptography
[✓] Installing Python module pyOpenSSL
[✓] Installing Python module certifi

[i] Kivy Python library dependency checks…
[✓] Checking for ffmpeg
[i] Checking for libsdl2-dev (will be installed)
[i] Checking for libsdl2-image-dev (will be installed)
[i] Checking for libsdl2-mixer-dev (will be installed)
[i] Checking for libsdl2-ttf-dev (will be installed)
[i] Checking for libportmidi-dev (will be installed)
[i] Checking for libswscale-dev (will be installed)
[i] Checking for libavformat-dev (will be installed)
[i] Checking for libavcodec-dev (will be installed)
[✓] Checking for zlib1g-dev
[i] Checking for libgstreamer1.0-dev (will be installed)
[✓] Checking for gstreamer1.0-plugins-base
[✓] Checking for gstreamer1.0-plugins-good

[i] Kivy Python library installation check (will be installed)
[✗] Installing Kivy Python library
Error: Unable to install Kivy Python library

Looking in indexes: Simple index, piwheels - Simple index
Collecting kivy==2.0.0
Downloading Kivy-2.0.0.tar.gz (23.7 MB)
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 23.7/23.7 MB 3.2 MB/s eta 0:00:00
Installing build dependencies: started
Installing build dependencies: finished with status ‘done’
Getting requirements to build wheel: started
Getting requirements to build wheel: finished with status ‘error’
error: subprocess-exited-with-error

× Getting requirements to build wheel did not run successfully.
│ exit code: 1
╰─> [128 lines of output]
[WARNING] [Config ] Older configuration version detected (0 instead of 21)
[WARNING] [Config ] Upgrading configuration in progress.
[INFO ] [Logger ] Record log in /home/wfpiconsole/.kivy/logs/kivy_23-02-05_0.txt
[INFO ] [Kivy ] v2.0.0
[INFO ] [Kivy ] Installed at “/tmp/pip-install-jmvli9c6/kivy_61ddcb3f153343849e58fee8e194d338/kivy/init.py”
[INFO ] [Python ] v3.9.2 (default, Feb 28 2021, 17:03:44)
[GCC 10.2.1 20210110]
[INFO ] [Python ] Interpreter at “/usr/bin/python3”
:374: DeprecationWarning: distutils Version classes are deprecated. Use packaging.version instead.
:377: DeprecationWarning: distutils Version classes are deprecated. Use packaging.version instead.
:381: DeprecationWarning: distutils Version classes are deprecated. Use packaging.version instead.
Current directory is: /tmp/pip-install-jmvli9c6/kivy_61ddcb3f153343849e58fee8e194d338
Source and initial build directory is: /tmp/pip-install-jmvli9c6/kivy_61ddcb3f153343849e58fee8e194d338
Python path is:
/tmp/pip-install-jmvli9c6/kivy_61ddcb3f153343849e58fee8e194d338
/home/wfpiconsole/.local/lib/python3.9/site-packages/pip/_vendor/pyproject_hooks/_in_process
/tmp/pip-build-env-wgud0th8/site
/usr/lib/python39.zip
/usr/lib/python3.9
/usr/lib/python3.9/lib-dynload
/tmp/pip-build-env-wgud0th8/overlay/lib/python3.9/site-packages
/tmp/pip-build-env-wgud0th8/normal/lib/python3.9/site-packages
/tmp/pip-install-jmvli9c6/kivy_61ddcb3f153343849e58fee8e194d338/kivy/modules
/home/wfpiconsole/.kivy/mods

  Found Cython at /tmp/pip-build-env-wgud0th8/overlay/lib/python3.9/site-packages/Cython/__init__.py
  Detected supported Cython version 0.29.21
  Using this graphics system: OpenGL
  GStreamer found via pkg-config
  SDL2 found via pkg-config
  SDL2: found SDL header at /usr/include/SDL2/SDL.h
  SDL2: found SDL_mixer header at /usr/include/SDL2/SDL_mixer.h
  SDL2: found SDL_ttf header at /usr/include/SDL2/SDL_ttf.h
  SDL2: found SDL_image header at /usr/include/SDL2/SDL_image.h
  WARNING: A problem occurred while running pkg-config --libs --cflags pangoft2 (code 1)
  
  b"Package pangoft2 was not found in the pkg-config search path.\nPerhaps you should add the directory containing `pangoft2.pc'\nto the PKG_CONFIG_PATH environment variable\nNo package 'pangoft2' found\n"
  
  ERROR: Dependency for context.pyx not resolved: config.pxi
  ERROR: Dependency for compiler.pyx not resolved: config.pxi
  ERROR: Dependency for context_instructions.pyx not resolved: config.pxi
  ERROR: Dependency for fbo.pyx not resolved: config.pxi
  ERROR: Dependency for gl_instructions.pyx not resolved: config.pxi
  ERROR: Dependency for instructions.pyx not resolved: config.pxi
  ERROR: Dependency for opengl.pyx not resolved: config.pxi
  ERROR: Dependency for opengl_utils.pyx not resolved: config.pxi
  ERROR: Dependency for shader.pyx not resolved: config.pxi
  ERROR: Dependency for stencil_instructions.pyx not resolved: config.pxi
  ERROR: Dependency for scissor_instructions.pyx not resolved: config.pxi
  ERROR: Dependency for texture.pyx not resolved: config.pxi
  ERROR: Dependency for vbo.pyx not resolved: config.pxi
  ERROR: Dependency for vertex.pyx not resolved: config.pxi
  ERROR: Dependency for vertex_instructions.pyx not resolved: config.pxi
  ERROR: Dependency for cgl.pyx not resolved: config.pxi
  ERROR: Dependency for cgl_mock.pyx not resolved: config.pxi
  ERROR: Dependency for cgl_gl.pyx not resolved: config.pxi
  ERROR: Dependency for cgl_glew.pyx not resolved: config.pxi
  ERROR: Dependency for cgl_sdl2.pyx not resolved: config.pxi
  ERROR: Dependency for svg.pyx not resolved: config.pxi
   Traceback (most recent call last):
     File "/tmp/pip-build-env-wgud0th8/overlay/lib/python3.9/site-packages/setuptools/_vendor/packaging/requirements.py", line 35, in __init__
       parsed = parse_requirement(requirement_string)
     File "/tmp/pip-build-env-wgud0th8/overlay/lib/python3.9/site-packages/setuptools/_vendor/packaging/_parser.py", line 64, in parse_requirement
       return _parse_requirement(Tokenizer(source, rules=DEFAULT_RULES))
     File "/tmp/pip-build-env-wgud0th8/overlay/lib/python3.9/site-packages/setuptools/_vendor/packaging/_parser.py", line 82, in _parse_requirement
       url, specifier, marker = _parse_requirement_details(tokenizer)
     File "/tmp/pip-build-env-wgud0th8/overlay/lib/python3.9/site-packages/setuptools/_vendor/packaging/_parser.py", line 126, in _parse_requirement_details
       marker = _parse_requirement_marker(
     File "/tmp/pip-build-env-wgud0th8/overlay/lib/python3.9/site-packages/setuptools/_vendor/packaging/_parser.py", line 147, in _parse_requirement_marker
       tokenizer.raise_syntax_error(
     File "/tmp/pip-build-env-wgud0th8/overlay/lib/python3.9/site-packages/setuptools/_vendor/packaging/_tokenizer.py", line 163, in raise_syntax_error
       raise ParserSyntaxError(
   setuptools.extern.packaging._tokenizer.ParserSyntaxError: Expected end or semicolon (after name and no valid version specifier)
       sys_platform == "win32"
                    ^
  
   The above exception was the direct cause of the following exception:
  
   Traceback (most recent call last):
     File "/tmp/pip-build-env-wgud0th8/overlay/lib/python3.9/site-packages/setuptools/config/setupcfg.py", line 212, in _warn_accidental_env_marker_misconfig
       req = Requirement(parsed[1])
     File "/tmp/pip-build-env-wgud0th8/overlay/lib/python3.9/site-packages/setuptools/_vendor/packaging/requirements.py", line 37, in __init__
       raise InvalidRequirement(str(e)) from e
   setuptools.extern.packaging.requirements.InvalidRequirement: Expected end or semicolon (after name and no valid version specifier)
       sys_platform == "win32"
                    ^
  
   The above exception was the direct cause of the following exception:
  
   Traceback (most recent call last):
     File "/home/wfpiconsole/.local/lib/python3.9/site-packages/pip/_vendor/pyproject_hooks/_in_process/_in_process.py", line 353, in <module>
       main()
     File "/home/wfpiconsole/.local/lib/python3.9/site-packages/pip/_vendor/pyproject_hooks/_in_process/_in_process.py", line 335, in main
       json_out['return_val'] = hook(**hook_input['kwargs'])
     File "/home/wfpiconsole/.local/lib/python3.9/site-packages/pip/_vendor/pyproject_hooks/_in_process/_in_process.py", line 118, in get_requires_for_build_wheel
       return hook(config_settings)
     File "/tmp/pip-build-env-wgud0th8/overlay/lib/python3.9/site-packages/setuptools/build_meta.py", line 338, in get_requires_for_build_wheel
       return self._get_build_requires(config_settings, requirements=['wheel'])
     File "/tmp/pip-build-env-wgud0th8/overlay/lib/python3.9/site-packages/setuptools/build_meta.py", line 320, in _get_build_requires
       self.run_setup()
     File "/tmp/pip-build-env-wgud0th8/overlay/lib/python3.9/site-packages/setuptools/build_meta.py", line 484, in run_setup
       super(_BuildMetaLegacyBackend,
     File "/tmp/pip-build-env-wgud0th8/overlay/lib/python3.9/site-packages/setuptools/build_meta.py", line 335, in run_setup
       exec(code, locals())
     File "<string>", line 1068, in <module>
     File "/tmp/pip-build-env-wgud0th8/overlay/lib/python3.9/site-packages/setuptools/__init__.py", line 107, in setup
       _install_setup_requires(attrs)
     File "/tmp/pip-build-env-wgud0th8/overlay/lib/python3.9/site-packages/setuptools/__init__.py", line 78, in _install_setup_requires
       dist.parse_config_files(ignore_option_errors=True)
     File "/tmp/pip-build-env-wgud0th8/overlay/lib/python3.9/site-packages/setuptools/dist.py", line 868, in parse_config_files
       setupcfg.parse_configuration(
     File "/tmp/pip-build-env-wgud0th8/overlay/lib/python3.9/site-packages/setuptools/config/setupcfg.py", line 163, in parse_configuration
       options.parse()
     File "/tmp/pip-build-env-wgud0th8/overlay/lib/python3.9/site-packages/setuptools/config/setupcfg.py", line 508, in parse
       section_parser_method(section_options)
     File "/tmp/pip-build-env-wgud0th8/overlay/lib/python3.9/site-packages/setuptools/config/setupcfg.py", line 761, in parse_section_extras_require
       parsed = self._parse_section_to_dict_with_key(
     File "/tmp/pip-build-env-wgud0th8/overlay/lib/python3.9/site-packages/setuptools/config/setupcfg.py", line 458, in _parse_section_to_dict_with_key
       value[key] = values_parser(key, val)
     File "/tmp/pip-build-env-wgud0th8/overlay/lib/python3.9/site-packages/setuptools/config/setupcfg.py", line 763, in <lambda>
       lambda k, v: self._parse_requirements_list(f"extras_require[{k}]", v)
     File "/tmp/pip-build-env-wgud0th8/overlay/lib/python3.9/site-packages/setuptools/config/setupcfg.py", line 642, in _parse_requirements_list
       _warn_accidental_env_marker_misconfig(label, value, parsed)
     File "/tmp/pip-build-env-wgud0th8/overlay/lib/python3.9/site-packages/setuptools/config/setupcfg.py", line 217, in _warn_accidental_env_marker_misconfig
       raise InvalidRequirement(msg) from ex
   setuptools.extern.packaging.requirements.InvalidRequirement: One of the parsed requirements in `extras_require[gstreamer]` looks like a valid environment marker: 'sys_platform == "win32"'
   Make sure that the config is correct and check https://setuptools.pypa.io/en/latest/userguide/declarative_config.html#opt-2
  [end of output]

note: This error originates from a subprocess, and is likely not a problem with pip.
error: subprocess-exited-with-error

× Getting requirements to build wheel did not run successfully.
│ exit code: 1
╰─> See above for output.

note: This error originates from a subprocess, and is likely not a problem with pip.

wfpiconsole@weatherstation:~ $

Looks like the same error as above.

I then downloaded both the first and second installation files, told the first to use the local copy of the second, and ran the first installation script. It failed with the same error as above.

I then modified the second installation file in just one place:

KIVY_VERSION=“2.1.0” (was 2.0.0)

Then re-ran the first installation script again and…

wfpiconsole@weatherstation:/tmp $ ./wfpiconsole-1.sh

[✓] Root user check passed
[✓] Hardware check passed (aarch64)
[✓] OS check passed (Debian GNU/Linux 11 (bullseye))

================================
Installing WeatherFlow PiConsole

[✓] Checking for updated packages
[i] 109 updated packages available. Use ‘sudo apt upgrade’ to install

[i] WeatherFlow PiConsole dependency checks…
[✓] Checking for git
[✓] Checking for curl
[✓] Checking for rng-tools
[✓] Checking for build-essential
[✓] Checking for python3-dev
[✓] Checking for python3-pip
[✓] Checking for python3-setuptools
[✓] Checking for libssl-dev
[✓] Checking for libffi-dev
[✓] Checking for libatlas-base-dev
[✓] Checking for jq

[i] Installing WeatherFlow PiConsole Python modules…
[✓] Updating Python package manager
[✓] Installing Python module cython
[✓] Installing Python module websockets
[✓] Installing Python module numpy
[✓] Installing Python module pytz
[✓] Installing Python module ephem
[✓] Installing Python module packaging
[✓] Installing Python module cryptography
[✓] Installing Python module pyOpenSSL
[✓] Installing Python module certifi

[i] Kivy Python library dependency checks…
[✓] Checking for ffmpeg
[✓] Checking for libsdl2-dev
[✓] Checking for libsdl2-image-dev
[✓] Checking for libsdl2-mixer-dev
[✓] Checking for libsdl2-ttf-dev
[✓] Checking for libportmidi-dev
[✓] Checking for libswscale-dev
[✓] Checking for libavformat-dev
[✓] Checking for libavcodec-dev
[✓] Checking for zlib1g-dev
[✓] Checking for libgstreamer1.0-dev
[✓] Checking for gstreamer1.0-plugins-base
[✓] Checking for gstreamer1.0-plugins-good

[i] Kivy Python library installation check (will be installed)
[✓] Installing Kivy Python library
[✓] Updating Kivy configuration for touch screen

[✓] Installing latest version of WeatherFlow PiConsole: v22.12.3

============================================
WeatherFlow PiConsole installation complete!
Start the console with: ‘wfpiconsole start’

wfpiconsole@weatherstation:/tmp

I think there are two separate issues:

  1. kivy version seems to need updating at least for the RPI-4 on Bullseye as it appears to fix critical bugs
  2. Installation as root succeeds except for the final chown error - so if that was fixed up it might otherwise work if installed as root.

After installation, I had to set:

[Display]
Fullscreen = 0

Otherwise all I got was a blank screen. But after changing that, it all seems to work fine.

As a feature request, I’d prefer to only have a dark mode when it’s actually dark - ie 30 mins before sunset and 30 mins after sunrise, and the rest of the time on a lighter colour palette. I haven’t looked into if that can be easily done yet though.

Actually after my most recent installation experience I’d suggest that could be a warning or recommendation that is spat out by the installer, rather than a hard blocker to installation. It looks like installation as root does actually work and end up with a functional system, with the exception of the final chown which I suspect could be easily fixed.

If you’re going to enforce a separate non-privileged user do the install, then creating that user as part of the installation script would be another low-touch way you could approach this in this case.

Obviously it’s your call, I’m coming from the perspective of making it the most bulletproof way the installation could work, and trying to help make it an even better experience (the installation process itself is well done, I’m really impressed at what is done inside the script and the one-touch nature of it all). My system is working great now :slight_smile:

Thanks for all your testing, it’s really useful!

I admit I missed this detail at the beginning that you are running the 64 bit version. This is why the Kivy installation with v2.0.0 is failing. The Kivy project maintainers don’t provide a pre-compiled wheel for that version that is compatible with the 64 bit version of Raspberry Pi OS, but they do provide a pre-compile wheel for v2.1.0. You are right that there is some missing dependency when trying to compile v2.0.0 from source on the 64 bit Raspberry Pi OS, although it is not clear what that dependency is. If you run the installer on the brand new install of the 32 bit version of Raspberry Pi OS (which is technically the only version I support, although I do allow the the installer to run on the 64 bit version README), then I am 99% sure the installer will complete with no issues with Kivy v2.0.0.

It’s not so much that I am enforcing a separate non-privileged user, it’s simply that best practice tends to suggest that you shouldn’t constantly be running Linux with elevated privileges. I designed the installer with this practice in mind. I will certainly look at fixing the chown command to make the installer complete if you are running as a root user. Although I will also add a warning to the installer that it is running as root user, meaning any mistake I make might have considerable consequences for the stability of someone’s system.

1 Like

Is this related to what I’m getting here when I try to update? It’s been plugging along fine for a month or more and now I kinda am stumped due to this update:
image
I h

Yes. Unfortunately, there are just too many compatibility issues with 64 bit systems that I have had to remove support from the installer. It’s worth noting that I have never officially supported 64 bit systems, and while it worked for a while on an ad-hoc basis, going forwards it will be best to switch to a 32 bit system

Is there a manual path to update a 64 bit system?

Sure, you can examine the contents of the update function and run the commands contained within the functions manually: WeatherFlow_PiConsole/wfpiconsole.sh at main · peted-davis/WeatherFlow_PiConsole · GitHub