MCPcopy Index your code
hub / github.com/python/cpython / path_return_ok

Method path_return_ok

Lib/http/cookiejar.py:1215–1226  ·  view source on GitHub ↗
(self, path, request)

Source from the content-addressed store, hash-verified

1213 return True
1214
1215 def path_return_ok(self, path, request):
1216 _debug("- checking cookie path=%s", path)
1217 req_path = request_path(request)
1218 pathlen = len(path)
1219 if req_path == path:
1220 return True
1221 elif (req_path.startswith(path) and
1222 (path.endswith("/") or req_path[pathlen:pathlen+1] == "/")):
1223 return True
1224
1225 _debug(" %s does not path-match %s", req_path, path)
1226 return False
1227
1228def deepvalues(mapping):
1229 """Iterates over nested mapping, depth-first"""

Callers 1

set_ok_pathMethod · 0.95

Calls 4

_debugFunction · 0.85
request_pathFunction · 0.85
startswithMethod · 0.45
endswithMethod · 0.45

Tested by

no test coverage detected