Merge branch 'stable'
This commit is contained in:
commit
5880befcd2
6 changed files with 19 additions and 8 deletions
|
|
@ -358,7 +358,7 @@ class Flask(App):
|
|||
f"{self.static_url_path}/<path:filename>",
|
||||
endpoint="static",
|
||||
host=static_host,
|
||||
view_func=lambda **kw: self_ref().send_static_file(**kw), # type: ignore # noqa: B950
|
||||
view_func=lambda **kw: self_ref().send_static_file(**kw), # type: ignore
|
||||
)
|
||||
|
||||
def get_send_file_max_age(self, filename: str | None) -> int | None:
|
||||
|
|
@ -1568,7 +1568,7 @@ class Flask(App):
|
|||
except Exception as e:
|
||||
error = e
|
||||
response = self.handle_exception(ctx, e)
|
||||
except: # noqa: B001
|
||||
except:
|
||||
error = sys.exc_info()[1]
|
||||
raise
|
||||
return response(environ, start_response)
|
||||
|
|
|
|||
|
|
@ -530,7 +530,7 @@ class App(Scaffold):
|
|||
"""
|
||||
return DispatchingJinjaLoader(self)
|
||||
|
||||
def select_jinja_autoescape(self, filename: str) -> bool:
|
||||
def select_jinja_autoescape(self, filename: str | None) -> bool:
|
||||
"""Returns ``True`` if autoescaping should be active for the given
|
||||
template name. If no template name is given, returns `True`.
|
||||
|
||||
|
|
|
|||
|
|
@ -107,7 +107,7 @@ class NullSession(SecureCookieSession):
|
|||
"application to something unique and secret."
|
||||
)
|
||||
|
||||
__setitem__ = __delitem__ = clear = pop = popitem = update = setdefault = _fail # noqa: B950
|
||||
__setitem__ = __delitem__ = clear = pop = popitem = update = setdefault = _fail
|
||||
del _fail
|
||||
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue