RedirectCycleError
The test client has been asked to follow a redirect loop.
Attributes
| Attribute | Type | Description |
|---|---|---|
| last_response | [HttpResponse](../../http/response/httpresponse.md?sid=django_http_response_httpresponse) | The final response object received before the redirect cycle was detected. |
| redirect_chain | list | A list of URLs and status codes representing the sequence of redirects followed prior to the error. |
Constructor
Signature
def RedirectCycleError(
message: string,
last_response: Response
) - > null
Parameters
| Name | Type | Description |
|---|---|---|
| message | string | The error message describing the redirect cycle. |
| last_response | Response | The last response object received before the cycle was detected, containing the redirect chain. |
Signature
def RedirectCycleError(
message: string,
last_response: [HttpResponse](../../http/response/httpresponse.md?sid=django_http_response_httpresponse)
) - > null
Parameters
| Name | Type | Description |
|---|---|---|
| message | string | The error message describing the nature of the redirect cycle. |
| last_response | [HttpResponse](../../http/response/httpresponse.md?sid=django_http_response_httpresponse) | The final response object received before the cycle was detected, used to extract the redirect chain. |