Error in SonarLint for IntelliJ IllegalArgumentException: port out of range:-1

Environment:

  • Java: JetBrains s.r.o. 17.0.7
  • OS: Windows 11 amd64
  • IDE: IntelliJ IDEA 2023.2
  • SonarLint: 8.5.0.75082
java.lang.IllegalArgumentException: port out of range:-1
	at java.base/java.net.InetSocketAddress.checkPort(InetSocketAddress.java:152)
	at java.base/java.net.InetSocketAddress.<init>(InetSocketAddress.java:233)
	at o.ss.sl.core.http.ClientProxySelector.lambda$select$0(ClientProxySelector.java:54)
	at java.base/java.util.stream.ReferencePipeline$3$1.accept(ReferencePipeline.java:197)
	at java.base/java.util.ArrayList$ArrayListSpliterator.forEachRemaining(ArrayList.java:1625)
	at java.base/java.util.stream.AbstractPipeline.copyInto(AbstractPipeline.java:509)
	at java.base/java.util.stream.AbstractPipeline.wrapAndCopyInto(AbstractPipeline.java:499)
	at java.base/java.util.stream.ReduceOps$ReduceOp.evaluateSequential(ReduceOps.java:921)
	at java.base/java.util.stream.AbstractPipeline.evaluate(AbstractPipeline.java:234)
	at java.base/java.util.stream.ReferencePipeline.collect(ReferencePipeline.java:682)
	at o.ss.sl.core.http.ClientProxySelector.select(ClientProxySelector.java:55)
	at org.apache.hc.client5.http.impl.routing.SystemDefaultRoutePlanner.determineProxy(SystemDefaultRoutePlanner.java:90)
	at org.apache.hc.client5.http.impl.routing.DefaultRoutePlanner.determineRoute(DefaultRoutePlanner.java:73)
	at org.apache.hc.client5.http.impl.async.InternalHttpAsyncClient.determineRoute(InternalHttpAsyncClient.java:104)
	at org.apache.hc.client5.http.impl.async.InternalAbstractHttpAsyncClient.lambda$doExecute$0(InternalAbstractHttpAsyncClient.java:190)

Hi @mblascht, thank you for your report!

I suspect you use a Proxy within IntelliJ and your URI does not provide a port number. If that’s the root cause, it’s an issue on our side.

Edit: It seems that I identified an issue on our side regarding the proxy selector. I created those tickets 1 and 2 as a result. It should be part of the next release at the end of the month or within a patch depending on the impact.

Same error here

Note that if that’s a blocker, we invite you to downgrade to the previous 8.4 version by following the steps to directly install the plugin from disk while we work on it.

Is there a roadmap, when the fix is pubilshed?

We will proceed to create a patch today containing the fixes. I will keep you updated whenever this is ready.

2 Likes

Patch, version 8.5.1, was released today, could you please update and see if the issue is resolved? Thank you!