PyCharm is giving an unused import error for routes, and models

I am trying to build a basic Flask project. Here is the app.py file. from flask import Flask from flask_sqlalchemy import SQLAlchemy from flask_login import LoginManager app = Flask(…

How to link static folder in Google app engine with a storage bucket

Created a new python Flask app-engine python project and want to use the static files from Google cloud storage. I am using this yaml.file: runtime: python env: flex entrypoint: gunicorn -b :$PORT …

Contained submit button validating other forms

I have two forms on my page, each with its own fields and submit button, but whenever I use any of them, they always check the overall page fields instead of just the form they’re contained in… The …

Python | Flask, using request.form in a class to POST data and update Jinja Template

I am building a small app using a forex converter api, it’s function is to take one currency, and convert a value into the new currency. I seem to be getting caught when accessing my class “…

Can i have two different sets of app configurations?

I have made a flask server REST API that does an upload to a specific folder. The upload must comply to a specific file extension, and must be in a specific folder. So i made these two app.configs: …

werkzeug.routing.BuildError: Could not build url for endpoint ‘profile’. Did you mean ‘index’ instead?

I’m new to programming and I’m following this tutorial: https://www.youtube.com/watch?v=SUC1aTu092w&ab_channel=edureka%21 | I’m trying to make a login system using flask and MySQLdb and I’ve run …

More elegant way to call arbitrary Python functions from Flask

Setting up a Flask REST API is easy. I use the following approach: from flask import Flask from flask_cors import CORS from utility import * app = Flask(__name__) cors = CORS(app, resources={r”/…

Working outside of application context Flask JWT decorator issue

I am fairly new to Flask applications. While my application works for all the endpoints as expected when I tried to add jwt authorization I encountered this issue. I have tried this solution app….

Reading a docx file from s3 bucket with flask results in an AttributeError

I got so many different errors, I don’t even know which is pertinent to mention but it’s not about the credentials because I can upload files already and I can read a txt file. Now I want to read a …

Blueprints in Flask vs Apps in Django [closed]

I am new to Flask and noticed something called Blueprint in Flask. I searched it and now I am using it in my Flask project. I had already worked in Django and I guess Blueprints are the Flask’s …