livekit/python-sdks

livekit-api requires Python >= 3.9

ryerson opened this issue · 0 comments

When attempting to import livekit-api (version 0.4.2) in python 3.8.17, the following exception is raised:

Traceback (most recent call last):
  File "app.py", line 3, in <module>
    from livekit import api
  File "/usr/local/lib/python3.8/site-packages/livekit/__init__.py", line 31, in <module>
    from .audio_frame import AudioFrame
  File "/usr/local/lib/python3.8/site-packages/livekit/audio_frame.py", line 17, in <module>
    from ._ffi_client import FfiHandle, ffi_client
  File "/usr/local/lib/python3.8/site-packages/livekit/_ffi_client.py", line 25, in <module>
    from ._utils import Queue
  File "/usr/local/lib/python3.8/site-packages/livekit/_utils.py", line 27, in <module>
    class Queue(asyncio.Queue[T]):
TypeError: 'type' object is not subscriptable

Is it possible to fix this so that the module can be used with Python 3.8 (or if not, adjust the python_requires value to be >=3.9.0)?

https://docs.python.org/3/whatsnew/3.9.html#type-hinting-generics-in-standard-collections