Actions
Feature #92231
closedAdd some more error messages to linkvalidator
Start date:
2020-09-08
Due date:
% Done:
100%
Estimated time:
PHP Version:
Tags:
Complexity:
Sprint Focus:
Description
For some error types, the error messages are too long, verbose and not suited for non technical audience.
The reason is, that not all error types have language strings and in some cases a generic error message and the exception (from Guzzle) is used.
I would propose to add some more error messages.
Also, the "Network error / invalid domain" error message is misleading, because all error reasons listed in https://curl.haxx.se/libcurl/c/libcurl-errors.html return that. In fact, the error code is also returned which could be used to give a more specific error message.
Examples that already have short custom error messages:¶
404:
The requested url was not found (404).
403:
Accessing this address is not allowed (403).
Examples for errors with long and cluttered error message¶
401:
An error occurred (401): "Client error: `GET https://url-which-requires-login/login` resulted in a `401 Unauthorized` response:
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xh (truncated...)
".
wrong domain:
Network error / invalid domain:cURL error 6: Could not resolve host: invalid-domain.de; Unknown error (see https://curl.haxx.se/libcurl/c/libcurl-errors.html)
ssl problem:
Network error / invalid domain:cURL error 51: Unable to communicate securely with peer: requested domain name does not match the server's certificate. (see https://curl.haxx.se/libcurl/c/libcurl-errors.html)
timeout:
Network error / invalid domain:cURL error 28: Connection timed out after 10001 milliseconds (see https://curl.haxx.se/libcurl/c/libcurl-errors.html)
HTTP Status code 500:
Network error / invalid domain:Server error: `GET http://some-domain/` resulted in a `500 Internal Server Error` response:
<!DOCTYPE HTML PUBLIC "-//IETF//DTD HTML 2.0//EN">
<html><head>
<title>500 Internal Server Error</title>
</head><body>
< (truncated...)
wrong protocol:
Network error / invalid domain:cURL error 1: Protocol hhttps not supported or disabled in libcurl (see https://curl.haxx.se/libcurl/c/libcurl-errors.html)
502:
Network error / invalid domain:Server error: `GET http://hochschule-ohne-grenzen.org/` resulted in a `502 Proxy Error` response:
<!DOCTYPE HTML PUBLIC "-//IETF//DTD HTML 2.0//EN">
<html><head>
<title>502 Proxy Error</title>
</head><body>
<h1>Proxy E (truncated...)
07.09.20 16:15
Files
Actions