Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Python 3.12 seems to break websockify #575

Closed
LeBirlante opened this issue May 13, 2024 · 3 comments
Closed

Python 3.12 seems to break websockify #575

LeBirlante opened this issue May 13, 2024 · 3 comments

Comments

@LeBirlante
Copy link

LeBirlante commented May 13, 2024

Hi there,

upgrading to python 3.12 on a Raspberry Pi Zero 2 W seems to have broken websockify:

_websockify[446]: Traceback (most recent call last):
   File "/usr/lib/python3.12/importlib/metadata/__init__.py", line 397, in from_name
    return next(cls.discover(name=name))
            ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
 StopIteration
 During handling of the above exception, another exception occurred:
 Traceback (most recent call last):
   File "/usr/bin/websockify", line 33, in <module>
    sys.exit(load_entry_point('websockify==0.11.0', 'console_scripts', 'websockify')(>
        ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
   File "/usr/bin/websockify", line 22, in importlib_load_entry_point
     for entry_point in distribution(dist_name).entry_points
                        ^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/lib/python3.12/importlib/metadata/__init__.py", line 862, in distribution
     return Distribution.from_name(distribution_name)
            ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
   File "/usr/lib/python3.12/importlib/metadata/__init__.py", line 399, in from_name
     raise PackageNotFoundError(name)
 importlib.metadata.PackageNotFoundError: No package metadata was found for websockify_

I tried to revert to 3.11, but that proved to be problematic, since several other applications have already been upgraded in order to work with python3.12, and they were complaining about not being able to link to python3.12.so when I reverted to 3.11

thanks and keep up the good work,

@LeBirlante LeBirlante changed the title Python 3.12 seems to break websociky Python 3.12 seems to break websockify May 13, 2024
@CendioOssman
Copy link
Member

I'm afraid I'm not seeing any issues using Python 3.12 here. What distribution is this? What version of websockify? And how is it deployed?

@LeBirlante
Copy link
Author

Sorry, you're absolutely right, there's no problem with 3.12: I was cloning the git and using makepkg on an Arch Linux distro, so the only thing that was needed - if you installed a new python version - was to re-makepkg the websockify package, which in turn runs pysetup and then websockify becomes aware of the new python libraries.

What you can't do, it seems, is upgrading python without re-makepkg'ing websockify. That's what broke it.

thanks for your time and help!

@LeBirlante
Copy link
Author

Solved: after installing a new python version, I needed to re-install the websockify package.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants