-
Notifications
You must be signed in to change notification settings - Fork 23
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Stop using deprecated _app_ctx_stack
from Flask
#58
Comments
To remove the usage of _app_ctx_stack and address the deprecation warning, you'll need to modify the request_id.py file in the flask_log_request_id package. Here's how you can update the code:
Please note that modifying third-party packages is generally not recommended, as it may introduce compatibility issues or make it difficult to update the package in the future. It's better to reach out to the maintainer of the flask_log_request_id package and ask them to update it to use the recommended approach with g or app_ctx instead of _app_ctx_stack. |
The comment above reads like something ChatGPT would generate... |
@yangdanny97 That it exactly what it looks like. |
Dies with an error in Flask 3. This repo appears to be orphaned. |
For someone who using this lib and flask > 2.2. |
Thank you @saggit for sharing the changes. However, there were some bugs .
I fixed those bugs in my repo. It supports older Flask versions too. In case anyone needs this library for Flaskv2 or v3. PR: #65 Edit: I released a new package with the fixes. More details here #65 (comment) |
Hello everyone |
This is my fix code
|
I released a new package with the fixes. More details here #65 (comment) |
Upon using the latest version of this package (0.10.2) in conjunction with the latest version of Flask (2.2), I'm getting the following warnings:
Could you please have a look at removing the use of this now deprecated construct?
Thanks
The text was updated successfully, but these errors were encountered: