Open SeanLixu23445997 opened 6 months ago
For the first dot point, we don't need the app.py
file as we have the app
directory to better manage each component of our app. Will remove when I create pr for branch I'm working on. The db config should only happen in the config.py
.
Both of these have been fixed. App.py was removed as it was being used as our main file but init.py is now main.
validate_on_submit() is a function of the class FlaskForm in flask_wtf/recaptcha/form.py
note: ill be adding more to this issue as I read further, please dont close this.
noticed that config.py will assign value to the SQALCHEMY_DATABASE_URI upon instantialisation. app.py will also initialise a value to the same variable. It appears to me that they're both going to be the same, so would it be necessary to have the value initialised to the same thing in two separate files? if so, what would be the correct order of initialisation?
in login.py the function .validate_on_submit() doesnt seem to have a definition, it appears to be a function from the forms.py's loginForm() function, but i dont see a function under the class.
ive noticed there are some naming inconsistencies with the flask endpoints, id like to suggest that all the endpoints to be named the same as the url link for simplicity. for example: /login will have endpoint login() and /register will have endpoint register()?