MCPcopy Create free account
hub / github.com/datapane/datapane / wrapper

Function wrapper

python-client/src/datapane/_vendor/bottle.py:3161–3167  ·  view source on GitHub ↗
(*a, **ka)

Source from the content-addressed store, hash-verified

3159
3160 @functools.wraps(func)
3161 def wrapper(*a, **ka):
3162 user, password = request.auth or (None, None)
3163 if user is None or not check(user, password):
3164 err = HTTPError(401, text)
3165 err.add_header('WWW-Authenticate', 'Basic realm="%s"' % realm)
3166 return err
3167 return func(*a, **ka)
3168
3169 return wrapper
3170

Callers

nothing calls this directly

Calls 5

HTTPErrorClass · 0.85
templateFunction · 0.85
add_headerMethod · 0.80
updateMethod · 0.80
copyMethod · 0.45

Tested by

no test coverage detected