Category "flask"

non-iterable ellipsis in Flask_Restful parser.parse_args()

I've come back to a project I worked on previously, utilising flask RESTful, though whenever I attempt a post request the line args = parser.parse_args() breaks

Flask application displaying list of items from SQL database as text

I am trying to display a list of my items from the database in my flask application. Unfortunately, the list elements are placed into the HTML as text, instead

AttributeError: Could not locate column in row for column '_sa_instance_state' Flask-sqlAlchemy

im developing a new project, im building a small CRM web app using Flask. Im very new using this technology. Im getting this error: AttributeError: Could not lo

How to override flask_admin ModelView.get_list to get custom amount of entries

Now i get all entries in admin when i open page of MyView(ModelView). I want to manage this behaviour and get only, for example, 10 entries. I tried to override

Flask:XMLHttpRequest at '...' from origin has been blocked by CORS policy No 'Access-Control-Allow-Origin' header is present on the requested resource

I am currently trying to get a small server running on my RaspberryPi and accessing it from my PC within the LAN. I get the following error when accessing the R

AJAX: Can I POST an array/data from my GET request? (Flask)

question similar to AJAX/FLASK/JS: How to POST existing array into endpoint?, a new question I've posted but this doesn't specifically help with the new issue,

unable to send post request in dio - flutter

I'm trying to send Post request from Flutter(dio) to my Flask Restful API and I want to give the request body in form-data because an image file needs to be sen

How to solve google chrome "Failed to load resource: net::ERR_CONNECTION_REFUSED" issue in windows 10 when server is running on Ubuntu 18.04?

I am trying to run this project on Ubuntu 18.04 server. I am running both server and client on this machine. Then from windows 10 with port 9000 I am getting ac

Cross Origin Problem with Flask Api (Access-Control-Allow-Origin)

Hello all good people. I have tested everything that I can find on internet and nothing is working to fix this problem. I'm really hoping that someone here can

Display wtforms SelectMultipleField display as drop-down and not list

I am using wtforms SelectMultipleField to render a form with a list of choices. Using a plain vanilla SelectField renders the choices as a drop-down (dropdown).

How can I set Beautify for VSCODE to indent Jinja2 and Flask?

Beautify indentation is ignoring Jinja2. I am using Beautify - HookyQR to help with formatting and indentation. HTML, Python, CSS ... everything works fine. But

Digitalocean Apps platform run time error - "workspace" directory is getting added

I could successfully deploy python/flask app on Digitalocean's Apps Platform. Now its giving runtime error app runtime log error: FileNotFoundError: [Errno 2] N

Flask-login pytest how to test logout

I am building a test suite for a flask app's auth blueprint. I've successfully built tests for user registering and login in, but I am having some trouble to te

Flask-SocketIo always using Polling

I have made an web app with flask and implemented socket-io in it using Flask-SocketIO but it is continuously using Polling method instead of Web Sockets. My JS

Error testing flask-socketio server emitted events with pytest

I'm building the test suite for a recently deployed webapp. It was built using flask-socketio and uses pytest for the testing suite. The big issue here is the l

Error while popping out Flask app context

I am trying to create an async API using threading (Celery is an overkill in my case). To achieve the same, I subclassed the Thread class in following manner. S

Get Paypal server side subscription with Flask

I'd like to have a simple solution to get the subscription ID after a payment approval in a Flask app. Paypal provides this code only for client side: <div i

How to delete or modify a database table using Flask-SQLAlchemy?

Is there a way to delete or modify a table using flask-sqlalchemy? I am working on a Flask-based web app. I switched to flask-sqlalchemy as my project is on Her

Error: While importing 'wsgi', an ImportError was raised. Python Flask Ubuntu 20.04

I am building a backend using Python and Flask, everything worked fine, but after some updates on the Pipfile (updated some packages) I got this error when I tr

"The CSRF session token is missing" when CSRF token is present in request

I am using Flask-WTF to use its CSRF security feature for my API. As the title suggests, the response I get from the API says that the "CSRF session token is mi