Traceback (most recent call last):
File "D:\Projects\Technothon 2022\HelpR\app.py", line 9, in <module>
from forms import *
File "D:\Projects\Technothon 2022\HelpR\forms.py", line 2, in <module>
from wtforms import TextField, PasswordField
ImportError: cannot import name 'TextField' from 'wtforms' (D:\Projects\Technothon 2022\HelpR\venv\lib\site-packages\wtforms\__init__.py)
This is caused in python==3.10.1 and WTForms 3.0.1 having deprecated the TextField method
This can be resolved by either pinning WTForms==2.3.3 in requirements.txt or updating from TextField to StringField in forms.py
Please advice which method we would like to use, I can perform the necessary change to rectify this issue.
There is an error when running app.py:-
This is caused in python==3.10.1 and WTForms 3.0.1 having deprecated the TextField method This can be resolved by either pinning WTForms==2.3.3 in
requirements.txt
or updating fromTextField
toStringField
in forms.py Please advice which method we would like to use, I can perform the necessary change to rectify this issue.