manager.command, deprecation warning
rbw opened this issue · 1 comments
rbw commented
Hello,
I'm getting the following deprecation warning when decorating a function with manager.command in Python 3.6:
/usr/local/lib/python3.6/dist-packages/flask_script/commands.py:118: DeprecationWarning: inspect.getargspec() is deprecated, use inspect.signature() or inspect.getfullargspec()
args, varargs, keywords, defaults = inspect.getargspec(func)
from flask_script import Manager
manager = Manager(app)
@manager.command
def hello():
print('hello')
pip3 freeze | grep -i flask-script
Flask-Script==2.0.6
Btw - where do you store version info in flask_script
? I noticed __version__
isn't available.
sybrenstuvel commented
I see the same, changing that line to this fixes the warning:
args, varargs, keywords, defaults, _, _, _ = inspect.getfullargspec(func)