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

Cannot run using python 3.9 because of type annotations #35

Closed
GoGIGA opened this issue Jul 25, 2023 · 2 comments
Closed

Cannot run using python 3.9 because of type annotations #35

GoGIGA opened this issue Jul 25, 2023 · 2 comments
Labels
bug Something isn't working

Comments

@GoGIGA
Copy link

GoGIGA commented Jul 25, 2023

Thank your for creating this project. It would be nice to have such a thing for my little office. I have installed pip, git, ... on my pi3 and installed afterwards your webserver. When running the software the foloowing errors are shown:

/usr/local/lib/python3.9/dist-packages/quart_trio/app.py:165: TrioDeprecationWarning: trio.MultiError is deprecated since Trio 0.22.0; use BaseExceptionGroup (on Python 3.11 and later) or exceptiongroup.BaseExceptionGroup (earlier versions) instead (https://github.com/python-trio/trio/issues/2211)
  self, error: Union[Exception, trio.MultiError]
Traceback (most recent call last):
  File "/usr/local/bin/sanescansrv", line 5, in <module>
    from sanescansrv import run
  File "/usr/local/lib/python3.9/dist-packages/sanescansrv/__init__.py", line 1, in <module>
    from sanescansrv.server import (
  File "/usr/local/lib/python3.9/dist-packages/sanescansrv/server.py", line 47, in <module>
    from sanescansrv import htmlgen, logger
  File "/usr/local/lib/python3.9/dist-packages/sanescansrv/htmlgen.py", line 20, in <module>
    TagArg = str | int | float | bool
TypeError: unsupported operand type(s) for |: 'type' and 'type'

Is there a workaround?

Have a nice day

Rainer

@CoolCat467
Copy link
Owner

Ah, I think this is a result of running it with python 3.9. I have only been testing it in python 3.11, but I think I've made a few changes that might make this work properly, otherwise I'll change the install requirements to require newer versions of python.

@CoolCat467 CoolCat467 changed the title Error on pi when trying to run sanescansrv: trio.MultiError is deprecated since Trio Cannot run using python 3.9 because of type annotations Jul 25, 2023
@CoolCat467 CoolCat467 added the bug Something isn't working label Jul 25, 2023
@CoolCat467
Copy link
Owner

This issue should be fixed as of 97b9534, please re-open this issue if any more problems arise.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants