-
Notifications
You must be signed in to change notification settings - Fork 2.3k
Open
Description
Describe the bug
When performing unit tests under pytest
that instantiate a binance.client.Client
the tests throw a warning like the following
/home/donvito/.pyenv/versions/algotrading/lib/python3.12/site-packages/binance/helpers.py:96: DeprecationWarning: There is no current event loop
loop = asyncio.get_event_loop()
To Reproduce
Code snippet to reproduce the behavior:
import pytest
from binance.client import Client
class TestPopulateHelpers:
def test_warning_reproduction(self):
bclient = Client(
api_key = "some_api_key",
api_secret = "some_api_secret",
tld = "com"
)
assert 1 == 1
Expected behavior
No warnings should be shown.
Environment (please complete the following information):
- Python version: 3.12
- Virtual Env: virtualenv
- OS: Ubuntu
- python-binance version: 1.0.29
Metadata
Metadata
Assignees
Labels
No labels