Questions tagged [werkzeug]

Werkzeug is a WSGI utility library for Python. It's widely used and BSD licensed.

Werkzeug is a WSGI utility library for Python. It includes a debugger and fully featured request response headers. Also included is a set of HTTP utilities.

624 questions
0
votes
1 answer

Changing values on a werkzeug request object

I have a request object that comes from werkzeug. I want to change a value on this request object. This is not possible because werkzeug request objects are immutable. I understand this design decision, but I need to change a value. How do I do…
priestc
  • 33,060
  • 24
  • 83
  • 117
0
votes
1 answer

How to implement private/public apikey with werkzeug/bottle?

I am developing a RESTful web service with Bottle, probably soon to migrate to Werkzeug. I'd like to implement an auth scheme that works based on a private/public key pair where the server only has to store the public part while the user keeps the…
hpk42
  • 21,501
  • 4
  • 47
  • 53
0
votes
1 answer

Listing specific category first in Python

I have a list of categories from DB as following and it works fine + sorted by ID. {% for category in menu_categories|sort(attribute="id"): %}
{{ category.name }}
{% endfor %} I just need one exception if category='Pizza'…
Fi3n1k
  • 863
  • 3
  • 12
  • 20
0
votes
3 answers

Websocket for wsgi, which compatible with werkzeug

Need websocket wsgi library, which is compatible with werkzeug.
Tima Ospanov
  • 199
  • 2
  • 13
0
votes
1 answer

CNAME value instead of HOST value

If we have a customer with a cname record, sub1.notourserver.com, pointing to something like abcdefg.ourserver.com, we read the host as sub1.notoursever.com. Is it possible for us to somehow get the value abcdefg.ourserver.com from this request? We…
captDaylight
  • 2,224
  • 4
  • 31
  • 42
-1
votes
0 answers

cannot import name 'secure_filename' from 'flask'

When I execute app.py I am getting this error File "C:\Users\DELL\Desktop\Coding playground\pdf summariser\app.py", line 2, in from flask import Flask, request, jsonify,secure_filename ImportError: cannot import name 'secure_filename'…
-1
votes
1 answer

check_password_hash ever return False

I am creating a flask api with login auth but the check_password_hash ever return false and I get a error in my app.py i'm trying this from werkzeug.security import generate_password_hash, check_password_hash @app.route("/signup", methods=["GET",…
-1
votes
1 answer

spyne with DispatcherMiddleware modifying request header

My application is getting messages from different clients and sending information to different flask and spyne servers. In some cases method in ctx.method_request_string is different than the method in the request header and we use…
-1
votes
1 answer

Werkzeug crashes with "No module named run" when debugging

I have a flask app that runs well until I try debugging it, then it always crashes with No module named run I narrowed it down to exit_code = subprocess.call(args, env=new_environ, close_fds=False) in werkzeug What could be the issue here?
waldelb
  • 705
  • 6
  • 11
-1
votes
1 answer

Flask - Error werkzeug.exceptions.BadRequestKeyError -

I am trying to run my first flask app, but I am getting the following error after sending the POST request on Postman. Error: werkzeug.exceptions.BadRequestKeyError: 400 Bad Request: The browser (or proxy) sent a request that this server could not…
SKuan
  • 37
  • 7
-1
votes
1 answer

Avoiding application reload through Gunicorn and Flask

My application is reloading due to Werkseug's reload on code change feature. I would like to disable this, in production I am running Gunicorn. gunicorn -b 0.0.0.0:5000 \ --workers 12 \ --log-level "${LOGGING_LEVEL}" \ --preload…
dirtyw0lf
  • 1,899
  • 5
  • 35
  • 63
-1
votes
2 answers

How to secure a server-side session in flask?

The issue I am facing is that Werkzeug 1.0.0 has removed deprecated code, including all of Werkzeug.contrib so when I use flask-sessions I get from werkzeug.contrib.cache import FileSystemCache ModuleNotFoundError: No module named…
Derik002
  • 145
  • 13
-1
votes
1 answer

Dash multiple app server set Flask session

Let's say I have 2 apps running, and served by DispatcherMiddleware like the following: utils.py import uuid from flask import session def set_session(): if 'uid ' not in session: uid = str(uuid.uuid4()) session['uid'] =…
Nicolas Rey
  • 431
  • 2
  • 6
  • 19
-1
votes
2 answers

Why is check_password_hash function returning false? Using Flask, SQLite3 and Werkzeug

I am trying to create a basic login function using Flask, Werkzeug and SQLite. The users are able to register and a hash of their password is stored in a SQLite database, though when I try to login using the correct password the check_password_hash…
Ambassador Kosh
  • 459
  • 5
  • 19
-1
votes
1 answer

Flask app is not destroyed when server exits?

I have the following, seemingly easy, issue which I cannot figure out. I made a short, self-containing example below: from flask import Flask class MyFlask(Flask): def __init__(self, name): super().__init__(name) …
George
  • 93
  • 5
1 2 3
41
42