litnimax / astconfman

Asterisk ConfBridge Manager
GNU Lesser General Public License v3.0
45 stars 36 forks source link

init error again #54

Closed DoM1niC closed 2 years ago

DoM1niC commented 4 years ago
./manage.py ini
/home/asterisk/astconfman/lib/python2.7/site-packages/flask_sqlalchemy/__init__.py:834: FSADeprecationWarning: SQLALCHEMY_TRACK_MODIFICAT                                                                                                    IONS adds significant overhead and will be disabled by default in the future.  Set it to True or False to suppress this warning.
  'SQLALCHEMY_TRACK_MODIFICATIONS adds significant overhead and '
Traceback (most recent call last):
  File "./manage.py", line 8, in <module>
    from app import app, db, migrate, user_datastore
  File "/home/asterisk/astconfman/src/app.py", line 150, in <module>
    from views import asterisk
  File "/home/asterisk/astconfman/src/views.py", line 8, in <module>
    from flask_admin.contrib.sqla.ajax import QueryAjaxModelLoader
  File "/home/asterisk/astconfman/lib/python2.7/site-packages/flask_admin/contrib/sqla/__init__.py", line 1, in <module>
    from .view import ModelView
  File "/home/asterisk/astconfman/lib/python2.7/site-packages/flask_admin/contrib/sqla/view.py", line 15, in <module>
    from flask_admin.model import BaseModelView
  File "/home/asterisk/astconfman/lib/python2.7/site-packages/flask_admin/model/__init__.py", line 1, in <module>
    from .base import BaseModelView
  File "/home/asterisk/astconfman/lib/python2.7/site-packages/flask_admin/model/base.py", line 14, in <module>
    from flask_admin.form import BaseForm, FormOpts, rules
  File "/home/asterisk/astconfman/lib/python2.7/site-packages/flask_admin/form/__init__.py", line 6, in <module>
    from .upload import *
  File "/home/asterisk/astconfman/lib/python2.7/site-packages/flask_admin/form/upload.py", line 4, in <module>
    from werkzeug import secure_filename
ImportError: cannot import name secure_filename
rau-alvin commented 3 years ago

@DoM1niC Hello! I have same problem.

rau-alvin commented 3 years ago

@DoM1niC I found how fix it.

You need in /home/asterisk/astconfman/lib/python2.7/site-packages/flask_admin/form/upload.py

change

from werkzeug import secure_filename,FileStorage

to

from werkzeug.utils import secure_filename