MCPcopy
hub / github.com/django/django / resolve_request

Method resolve_request

django/core/handlers/base.py:302–317  ·  view source on GitHub ↗

Retrieve/set the urlconf for the request. Return the view resolved, with its args and kwargs.

(self, request)

Source from the content-addressed store, hash-verified

300 return response
301
302 def resolve_request(self, request):
303 """
304 Retrieve/set the urlconf for the request. Return the view resolved,
305 with its args and kwargs.
306 """
307 # Work out the resolver.
308 if hasattr(request, "urlconf"):
309 urlconf = request.urlconf
310 set_urlconf(urlconf)
311 resolver = get_resolver(urlconf)
312 else:
313 resolver = get_resolver()
314 # Resolve the view, and assign the match object back to the request.
315 resolver_match = resolver.resolve(request.path_info)
316 request.resolver_match = resolver_match
317 return resolver_match
318
319 def check_response(self, response, callback, name=None):
320 """

Callers 2

_get_responseMethod · 0.95
_get_response_asyncMethod · 0.95

Calls 3

set_urlconfFunction · 0.90
get_resolverFunction · 0.90
resolveMethod · 0.45

Tested by

no test coverage detected