Can install HASS on Picoreplayer (tinycore) linux

Hi I am running picoreplayer on my rpi5.
Now I am trying to install home assistant to run in the background.

hass --version
\2024.3.3

uname -a
Linux STREAMER 6.6.67-pcpCore-v8-16k #23 SMP PREEMPT Sat Dec 28 11:07:07 EST 2024 aarch64 GNU/Linux

I tried using this guide Home Assistant setup on Raspberry Pi with TinyCore Linux (RAM only OS) · GitHub
And am able to work it all the way through. With some version modifications.

But once I start the HASS binary, I see some errors coming by on installation of packages and also when the guide says I should access the GUI website I an unable to.

In the attachment 1 I added a log of the startup and then in attachment 2 I posted log of error message when acessing from http, in attachment 3 I posted log from acessing https.

Attachment 1: startup log (JustPaste.it - Share Text & Images the Easy Way)

Attachment 2: error log http

2025-04-04 12:23:51.210 INFO (MainThread) [homeassistant.core] Starting Home Ass                                                                          istant
2025-04-04 12:28:33.883 ERROR (MainThread) [aiohttp.server] Error handling request
Traceback (most recent call last):
  File "/usr/local/lib/python3.11/site-packages/aiohttp/web_protocol.py", line 452, in _handle_request
    resp = await request_handler(request)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/local/lib/python3.11/site-packages/aiohttp/web_app.py", line 543, in _handle
    resp = await handler(request)
           ^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/local/lib/python3.11/site-packages/aiohttp/web_middlewares.py", line 114, in impl
    return await handler(request)
           ^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/local/lib/python3.11/site-packages/homeassistant/components/http/security_filter.py", line 91, in security_filter_middleware
    return await handler(request)
           ^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/local/lib/python3.11/site-packages/homeassistant/components/http/forwarded.py", line 82, in forwarded_middleware
    from hass_nabucasa import (  # pylint: disable=import-outside-toplevel
  File "/usr/local/lib/python3.11/site-packages/hass_nabucasa/__init__.py", line 29, in <module>
    from .remote import RemoteUI
  File "/usr/local/lib/python3.11/site-packages/hass_nabucasa/remote.py", line 21, in <module>
    from .acme import AcmeClientError, AcmeHandler
  File "/usr/local/lib/python3.11/site-packages/hass_nabucasa/acme.py", line 13, in <module>
    from acme import challenges, client, crypto_util, errors, messages
  File "/usr/local/lib/python3.11/site-packages/acme/challenges.py", line 24, in <module>
    from acme import crypto_util
  File "/usr/local/lib/python3.11/site-packages/acme/crypto_util.py", line 435, in <module>
    def dump_pyopenssl_chain(chain: Union[List[jose.ComparableX509], List[crypto.X509]],
                                               ^^^^^^^^^^^^^^^^^^^
AttributeError: module 'josepy' has no attribute 'ComparableX509'
2025-04-04 12:28:33.979 ERROR (MainThread) [aiohttp.server] Error handling request
Traceback (most recent call last):
  File "/usr/local/lib/python3.11/site-packages/aiohttp/web_protocol.py", line 452, in _handle_request
    resp = await request_handler(request)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/local/lib/python3.11/site-packages/aiohttp/web_app.py", line 543, in _handle
    resp = await handler(request)
           ^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/local/lib/python3.11/site-packages/aiohttp/web_middlewares.py", line 114, in impl
    return await handler(request)
           ^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/local/lib/python3.11/site-packages/homeassistant/components/http/security_filter.py", line 91, in security_filter_middleware
    return await handler(request)
           ^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/local/lib/python3.11/site-packages/homeassistant/components/http/forwarded.py", line 82, in forwarded_middleware
    from hass_nabucasa import (  # pylint: disable=import-outside-toplevel
  File "/usr/local/lib/python3.11/site-packages/hass_nabucasa/__init__.py", line 29, in <module>
    from .remote import RemoteUI
  File "/usr/local/lib/python3.11/site-packages/hass_nabucasa/remote.py", line 21, in <module>
    from .acme import AcmeClientError, AcmeHandler
  File "/usr/local/lib/python3.11/site-packages/hass_nabucasa/acme.py", line 13, in <module>
    from acme import challenges, client, crypto_util, errors, messages
  File "/usr/local/lib/python3.11/site-packages/acme/challenges.py", line 24, in <module>
    from acme import crypto_util
  File "/usr/local/lib/python3.11/site-packages/acme/crypto_util.py", line 435, in <module>
    def dump_pyopenssl_chain(chain: Union[List[jose.ComparableX509], List[crypto.X509]],
                                               ^^^^^^^^^^^^^^^^^^^
AttributeError: module 'josepy' has no attribute 'ComparableX509'

Attachment 3: https error

2025-04-04 12:28:33.979 ERROR (MainThread) [aiohttp.server] Error handling request
Traceback (most recent call last):
  File "/usr/local/lib/python3.11/site-packages/aiohttp/web_protocol.py", line 452, in _handle_request
    resp = await request_handler(request)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/local/lib/python3.11/site-packages/aiohttp/web_app.py", line 543, in _handle
    resp = await handler(request)
           ^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/local/lib/python3.11/site-packages/aiohttp/web_middlewares.py", line 114, in impl
    return await handler(request)
           ^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/local/lib/python3.11/site-packages/homeassistant/components/http/security_filter.py", line 91, in security_filter_middleware
    return await handler(request)
           ^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/local/lib/python3.11/site-packages/homeassistant/components/http/forwarded.py", line 82, in forwarded_middleware
    from hass_nabucasa import (  # pylint: disable=import-outside-toplevel
  File "/usr/local/lib/python3.11/site-packages/hass_nabucasa/__init__.py", line 29, in <module>
    from .remote import RemoteUI
  File "/usr/local/lib/python3.11/site-packages/hass_nabucasa/remote.py", line 21, in <module>
    from .acme import AcmeClientError, AcmeHandler
  File "/usr/local/lib/python3.11/site-packages/hass_nabucasa/acme.py", line 13, in <module>
    from acme import challenges, client, crypto_util, errors, messages
  File "/usr/local/lib/python3.11/site-packages/acme/challenges.py", line 24, in <module>
    from acme import crypto_util
  File "/usr/local/lib/python3.11/site-packages/acme/crypto_util.py", line 435, in <module>
    def dump_pyopenssl_chain(chain: Union[List[jose.ComparableX509], List[crypto.X509]],
                                               ^^^^^^^^^^^^^^^^^^^
AttributeError: module 'josepy' has no attribute 'ComparableX509'
2025-04-04 12:30:30.178 ERROR (MainThread) [aiohttp.server] Error handling request
Traceback (most recent call last):
  File "/usr/local/lib/python3.11/site-packages/aiohttp/web_protocol.py", line 350, in data_received
    messages, upgraded, tail = self._request_parser.feed_data(data)
                               ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "aiohttp/_http_parser.pyx", line 557, in aiohttp._http_parser.HttpParser.feed_data
aiohttp.http_exceptions.BadStatusLine: 400, message:
  Invalid method encountered:

    b'\x16\x03\x01\x06\xa0\x01'
      ^
2025-04-04 12:30:30.181 ERROR (MainThread) [aiohttp.server] Error handling request
Traceback (most recent call last):
  File "/usr/local/lib/python3.11/site-packages/aiohttp/web_protocol.py", line 350, in data_received
    messages, upgraded, tail = self._request_parser.feed_data(data)
                               ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "aiohttp/_http_parser.pyx", line 557, in aiohttp._http_parser.HttpParser.feed_data
aiohttp.http_exceptions.BadStatusLine: 400, message:
  Invalid method encountered:

    b'\x16\x03\x01\x06\xa0\x01'
      ^
2025-04-04 12:30:30.232 ERROR (MainThread) [aiohttp.server] Error handling request
Traceback (most recent call last):
  File "/usr/local/lib/python3.11/site-packages/aiohttp/web_protocol.py", line 350, in data_received
    messages, upgraded, tail = self._request_parser.feed_data(data)
                               ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "aiohttp/_http_parser.pyx", line 557, in aiohttp._http_parser.HttpParser.feed_data
aiohttp.http_exceptions.BadStatusLine: 400, message:
  Invalid method encountered:

    b'\x16\x03\x01\x06\xe0\x01'
      ^
2025-04-04 12:30:30.235 ERROR (MainThread) [aiohttp.server] Error handling request
Traceback (most recent call last):
  File "/usr/local/lib/python3.11/site-packages/aiohttp/web_protocol.py", line 350, in data_received
    messages, upgraded, tail = self._request_parser.feed_data(data)
                               ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "aiohttp/_http_parser.pyx", line 557, in aiohttp._http_parser.HttpParser.feed_data
aiohttp.http_exceptions.BadStatusLine: 400, message:
  Invalid method encountered:

    b'\x16\x03\x01\x06\xc0\x01'
      ^

BUMP, nobody?

You are probably the only one that wants to run HA on Picoreplayer. But current HA versions need python 3.12 (can’t say if that is the problem or not)

I tried updating to python 3.12 but there I found there was no pip package included. So I got stuck after that

might have to look at installing a normal distro on the rpi and leveraging all picoreplayer software and hass in there. perhaps a better idea since I alos want to run docker, nas and webserver

Yes, I don’t think this is the right way around. Tinycore is by design… well … tiny. It’s great for PCP, but not the right platform for HA IMHO. You can certainly do things the other way around - use HAOS as you base and run squeezelite as an addon . Or, since you’re clearly up for tinkering, why not run something like proxmox or portainer on your pi, run HAOS in one VM and then you can run a lightweight container with squeezelite, or probably run a VM for pcp/tinycore if you wanted.

1 Like

Your last option sounds pretty good, but will it be able to output and switch between displaying one or the other VM gui on the display (I have attached DSI screen). Currently Im using the dsi screen to display jivelite interface. Ideal would be a way to toggle between jivelite and hom assistant on the screen and be able to use the screen to control it as well.

I’d have to go with … don’t know … on that one I’m afraid - I run all of my proxmox stuff headless. I did have a really old pi2 on which I just ran jivelite connecting to squeezelite running in a container on my proxmox cluster, but I just don’t bother with it anymore. Probably something to ask over on the proxmox reddit perhaps.

I also hit the josepy issue.

homeassistant, at least version 2024.10.0, and perhaps transitively, is too permissive in it’s requirement on a dependency. josepy introduced a breaking change in the latest major version 2.0.0:

Breaking Change: PyOpenSSL has been fully removed. - Dropped objects:

josepy.util.ComparableX509

If you restrict josepy to an earlier version you might have more luck.

I’m using uv, so I did uv add "josepy<2.0.0"

1 Like

Hello.
Thanks for the tip:

I’m discovering my OrangePi4 Pro and I installed HA as I already use it on my dev-station.
I searched for → AttributeError: module 'josepy' has no attribute 'ComparableX509'
and fortunately landed here. BIg Time Saver :smile:

The fix for the Ubuntu22.04LTS provided by OrangePi.org is
pip3 install "josepy<2.0.0"