SQL-alchemy: ValueError too many values to unpack?

后端 未结 2 1126
温柔的废话
温柔的废话 2020-12-16 08:33

I have a website running with a mysql database using the sql-alchemy package that has suddenly broken. I have done some research and found that the expected issue is that th

2条回答
  •  臣服心动
    2020-12-16 09:13

    I was also having this issue. I got the hacks (as described above) to work, but looking at the discussions on https://github.com/wtforms/wtforms/issues/373 and https://github.com/flask-admin/flask-admin/issues/1588, it looked like support for wtforms_sqlalchemy is not as good as wtforms_alchemy.

    So, I installed wtforms_alchemy

    pip install wtforms_alchemy 
    

    and replaced wtforms_sqlalchemy with wtform_alchemy in my project

    from wtforms_alchemy.fields import QuerySelectField 
    

    and my project worked the same.

提交回复
热议问题