robinhood / faust

Python Stream Processing
Other
6.7k stars 538 forks source link

Support for python3.10 #762

Open meysam81 opened 2 years ago

meysam81 commented 2 years ago

Checklist

Steps to reproduce

When trying to run the faust worker inside a python3.10 environment, the traceback shows that python3.10 is not still supported by faust.

This behaviour is the same for all the loops (aio, eventlet and uvloop)

Expected behavior

As it is working up until python3.9, I expect a support for python3.10

Actual behavior

The traceback shows that there is still no support for python3.10

Full traceback

Traceback (most recent call last):
  File "/private/var/folders/kq/q3dl_4s94bs8mht98sylb7vr0000gn/T/tmp.kER1fue1/venv/lib/python3.10/site-packages/mode/worker.py", line 273, in execute_from_commandline
    self.loop.run_until_complete(self._starting_fut)
  File "uvloop/loop.pyx", line 1501, in uvloop.loop.Loop.run_until_complete
  File "/private/var/folders/kq/q3dl_4s94bs8mht98sylb7vr0000gn/T/tmp.kER1fue1/venv/lib/python3.10/site-packages/mode/services.py", line 736, in start
    await self._default_start()
  File "/private/var/folders/kq/q3dl_4s94bs8mht98sylb7vr0000gn/T/tmp.kER1fue1/venv/lib/python3.10/site-packages/mode/services.py", line 743, in _default_start
    await self._actually_start()
  File "/private/var/folders/kq/q3dl_4s94bs8mht98sylb7vr0000gn/T/tmp.kER1fue1/venv/lib/python3.10/site-packages/mode/services.py", line 767, in _actually_start
    await child.maybe_start()
  File "/private/var/folders/kq/q3dl_4s94bs8mht98sylb7vr0000gn/T/tmp.kER1fue1/venv/lib/python3.10/site-packages/mode/services.py", line 795, in maybe_start
    await self.start()
  File "/private/var/folders/kq/q3dl_4s94bs8mht98sylb7vr0000gn/T/tmp.kER1fue1/venv/lib/python3.10/site-packages/mode/services.py", line 736, in start
    await self._default_start()
  File "/private/var/folders/kq/q3dl_4s94bs8mht98sylb7vr0000gn/T/tmp.kER1fue1/venv/lib/python3.10/site-packages/mode/services.py", line 743, in _default_start
    await self._actually_start()
  File "/private/var/folders/kq/q3dl_4s94bs8mht98sylb7vr0000gn/T/tmp.kER1fue1/venv/lib/python3.10/site-packages/mode/services.py", line 749, in _actually_start
    for dep in self.on_init_dependencies():
  File "/private/var/folders/kq/q3dl_4s94bs8mht98sylb7vr0000gn/T/tmp.kER1fue1/venv/lib/python3.10/site-packages/faust/app/base.py", line 567, in on_init_dependencies
    return self.boot_strategy.server()
  File "/private/var/folders/kq/q3dl_4s94bs8mht98sylb7vr0000gn/T/tmp.kER1fue1/venv/lib/python3.10/site-packages/faust/app/base.py", line 277, in server
    self.kafka_consumer(),
  File "/private/var/folders/kq/q3dl_4s94bs8mht98sylb7vr0000gn/T/tmp.kER1fue1/venv/lib/python3.10/site-packages/faust/app/base.py", line 328, in kafka_consumer
    self.app.consumer,
  File "/private/var/folders/kq/q3dl_4s94bs8mht98sylb7vr0000gn/T/tmp.kER1fue1/venv/lib/python3.10/site-packages/faust/app/base.py", line 1818, in consumer
    self._consumer = self._new_consumer()
  File "/private/var/folders/kq/q3dl_4s94bs8mht98sylb7vr0000gn/T/tmp.kER1fue1/venv/lib/python3.10/site-packages/faust/app/base.py", line 1674, in _new_consumer
    return self.transport.create_consumer(
  File "/private/var/folders/kq/q3dl_4s94bs8mht98sylb7vr0000gn/T/tmp.kER1fue1/venv/lib/python3.10/site-packages/faust/transport/base.py", line 68, in create_consumer
    return self.Consumer(self, callback=callback,
  File "/private/var/folders/kq/q3dl_4s94bs8mht98sylb7vr0000gn/T/tmp.kER1fue1/venv/lib/python3.10/site-packages/faust/transport/consumer.py", line 1231, in __init__
    self._method_queue = MethodQueue(loop=self.loop, beacon=self.beacon)
  File "/private/var/folders/kq/q3dl_4s94bs8mht98sylb7vr0000gn/T/tmp.kER1fue1/venv/lib/python3.10/site-packages/mode/threads.py", line 331, in __init__
    self._queue = asyncio.Queue(loop=self.loop)
  File "/Library/Frameworks/Python.framework/Versions/3.10/lib/python3.10/asyncio/queues.py", line 33, in __init__
    super().__init__(loop=loop)
  File "/Library/Frameworks/Python.framework/Versions/3.10/lib/python3.10/asyncio/mixins.py", line 17, in __init__
    raise TypeError(
TypeError: As of 3.10, the *loop* parameter was removed from Queue() since it is no longer necessary

Versions

austinnichols101 commented 1 year ago

@meysam81 - check the faust-streaming fork https://github.com/faust-streaming/faust