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

Function request_path

Lib/http/cookiejar.py:648–656  ·  view source on GitHub ↗

Path component of request-URI, as defined by RFC 2965.

(request)

Source from the content-addressed store, hash-verified

646 return req_host, erhn
647
648def request_path(request):
649 """Path component of request-URI, as defined by RFC 2965."""
650 url = request.get_full_url()
651 parts = urllib.parse.urlsplit(url)
652 path = escape_path(parts.path)
653 if not path.startswith("/"):
654 # fix bad RFC 2396 absoluteURI
655 path = "/" + path
656 return path
657
658def request_port(request):
659 host = request.host

Callers 4

test_request_pathMethod · 0.90
set_ok_pathMethod · 0.85
path_return_okMethod · 0.85

Calls 3

escape_pathFunction · 0.85
get_full_urlMethod · 0.80
startswithMethod · 0.45

Tested by 1

test_request_pathMethod · 0.72

Used in the wild real call sites across dependent graphs

searching dependent graphs…