philipdouglas / r2-d7

A bot for xwingtmg.slack.com
MIT License
13 stars 14 forks source link

Deprecation warnings for python 3.9 #45

Closed danrs closed 2 years ago

danrs commented 3 years ago

When running pytest, we have the following deprecation warnings. I think these are coming from some of our imports, not our own code?

======================================================== warnings summary ========================================================
env/lib/python3.8/site-packages/flask/json/__init__.py:26
  /Users/dan/workspace/xwing/r2-d7/env/lib/python3.8/site-packages/flask/json/__init__.py:26: DeprecationWarning: Importing 'itsdangerous.json' is deprecated and will be removed in ItsDangerous 2.1. Use Python's 'json' module instead.
    _slash_escape = '\\/' not in _json.dumps('/')

env/lib/python3.8/site-packages/flask/json/__init__.py:48
  /Users/dan/workspace/xwing/r2-d7/env/lib/python3.8/site-packages/flask/json/__init__.py:48: DeprecationWarning: Importing 'itsdangerous.json' is deprecated and will be removed in ItsDangerous 2.1. Use Python's 'json' module instead.
    class JSONEncoder(_json.JSONEncoder):

env/lib/python3.8/site-packages/flask/json/__init__.py:84
  /Users/dan/workspace/xwing/r2-d7/env/lib/python3.8/site-packages/flask/json/__init__.py:84: DeprecationWarning: Importing 'itsdangerous.json' is deprecated and will be removed in ItsDangerous 2.1. Use Python's 'json' module instead.
    class JSONDecoder(_json.JSONDecoder):

env/lib/python3.8/site-packages/flask/sessions.py:14
  /Users/dan/workspace/xwing/r2-d7/env/lib/python3.8/site-packages/flask/sessions.py:14: DeprecationWarning: Using or importing the ABCs from 'collections' instead of from 'collections.abc' is deprecated since Python 3.3, and in 3.9 it will stop working
    from collections import MutableMapping
philipdouglas commented 3 years ago

They all seem to be coming from Flask, so I suspect we just need to upgrade Flask to a newer verison.

danrs commented 2 years ago

Fixed in #61 (I think) as Flask had to be updated for some other deps to work