flask之全局对象
from flask import current_app, ggis a special object that is unique for each request. It is used to store data that might be accessed by multiple functions during the request.
The connection is stored and reused instead of creating a new connection ifget_dbis called a second time in the same requestis another special object that points to the Flask application handling the request.
current_app

浙公网安备 33010602011771号