robertmrk / aiosfstream

Salesforce Streaming API client for asyncio
MIT License
47 stars 30 forks source link

aiosfstream is throwing TypeError when used with Python 3.7 #1

Closed jacekglebocki closed 6 years ago

jacekglebocki commented 6 years ago

When i use aiosfstream with my script, it is throwing an error:

my_SF_Script0.py:61: RuntimeWarning: coroutine 'Client.__aiter__' was never awaited async for message in client: INFO: Closing client... INFO: Client closed. Traceback (most recent call last): File "my_SF_Script0.py", line 77, in <module> loop.run_until_complete(task) File "C:\Users\MY.Name\AppData\Local\Programs\Python\Python37-32\lib\asyncio\base_events.py", line 568, in run_until_complete return future.result() File "my_SF_Script0.py", line 61, in stream_events async for message in client: TypeError: 'async for' received an object from __aiter__ that does not implement __anext__: coroutine

Ill be happy to add the code from my script if necessary. My script works on Python 3.6.4.

robertmrk commented 6 years ago

Thank you very much for reporting this problem!

A fix is on the way. I'll create a new release tomorrow.

robertmrk commented 6 years ago

@jacekglebocki The issue has been fixed in version 0.2.3. It's available on pypi.