slawekjaranowski commented on code in PR #1891:
URL: https://github.com/apache/maven-resolver/pull/1891#discussion_r3310350433
##########
maven-resolver-transport-apache/src/main/java/org/eclipse/aether/transport/apache/ApacheTransporter.java:
##########
@@ -523,10 +530,23 @@ private <T extends HttpUriRequest> void resume(T request,
GetTask task) throws I
private void handleStatus(CloseableHttpResponse response) throws Exception
{
int status = response.getStatusLine().getStatusCode();
if (status >= 300) {
- ApacheRFC9457Reporter.INSTANCE.generateException(response,
(statusCode, reasonPhrase) -> {
- throw new HttpResponseException(statusCode, reasonPhrase + "
(" + statusCode + ")");
- });
+ if (supportRfc9457) {
+ ApacheRFC9457Reporter.INSTANCE.generateException(response,
(statusCode, reasonPhrase) -> {
+ throw new HttpResponseException(statusCode, reasonPhrase +
" (" + statusCode + ")");
+ });
Review Comment:
maybe we can always parse response?
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]