Jinja: Warning about importing the ABCs on Python 3.7

Created on 9 May 2019  Â·  2Comments  Â·  Source: pallets/jinja


Expected Behavior

jinja2 should not issue warnings when being used with pytest.

Actual Behavior

jinja2 issues the following warnings when being used with pytest.

Warnings

pyutils(master) ✗: pytest
========================================================================== test session starts ==========================================================================
platform darwin -- Python 3.7.3, pytest-4.4.1, py-1.8.0, pluggy-0.9.0
rootdir: /Users/hulk/src/pyutils
collected 9 items

tests/test_countdown.py .....                                                                                                                                     [ 55%]
tests/test_lookup.py ....                                                                                                                                         [100%]

=========================================================================== warnings summary ============================================================================
/usr/local/lib/python3.7/site-packages/jinja2/utils.py:485
  /usr/local/lib/python3.7/site-packages/jinja2/utils.py:485: DeprecationWarning: Using or importing the ABCs from 'collections' instead of from 'collections.abc' is deprecated, and in 3.8 it will stop working
    from collections import MutableMapping

/usr/local/lib/python3.7/site-packages/jinja2/runtime.py:318
  /usr/local/lib/python3.7/site-packages/jinja2/runtime.py:318: DeprecationWarning: Using or importing the ABCs from 'collections' instead of from 'collections.abc' is deprecated, and in 3.8 it will stop working
    from collections import Mapping

-- Docs: https://docs.pytest.org/en/latest/warnings.html
================================================================= 9 passed, 2 warnings in 0.08 seconds ==================================================================
pyutils(master) ✗:

Your Environment

  • Python version: 3.7.3
  • Jinja version: 2.10.1
  • pytest version: 4.4.1

Most helpful comment

Fixed in master

All 2 comments

Fixed in master

Just caught this one too. Thanks for fixing it.

Was this page helpful?
0 / 5 - 0 ratings