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

DeprecationWarning: asyncio.async() function is deprecated, use ensure_future() #50

Closed
adamrothman opened this issue May 22, 2017 · 3 comments

Comments

@adamrothman
Copy link

I am getting a ton of these warnings during test runs:

.tox/py36/lib/python3.6/site-packages/pytest_asyncio/plugin.py:77: DeprecationWarning: asyncio.async() function is deprecated, use ensure_future()
    asyncio.async(pyfuncitem.obj(**testargs), loop=event_loop))

Environment:

  • Python 3.6.1
  • pytest 3.1.0
  • pytest-asyncio 0.5.0
@lelit
Copy link

lelit commented May 23, 2017

This is because pytest 3.1 integrates the pytest-warnings.

@lelit
Copy link

lelit commented May 23, 2017

As a quick workaround (specific for pytest-asyncio 0.5.0), I added the option -Wignore:::pytest_asyncio.plugin:77 to the pytest command line.

@Tinche
Copy link
Member

Tinche commented May 24, 2017

Acknowledged, thanks for the report.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants