Testcontainers-java: NullPointerException in DockerClientFactory.dockerHostIpAddress with localstack container on 1.12.4

Created on 30 Nov 2019  路  4Comments  路  Source: testcontainers/testcontainers-java

We use static init and catching NPE on 1.12.4 release

Caused by: java.lang.NullPointerException
    at org.testcontainers.DockerClientFactory.dockerHostIpAddress(DockerClientFactory.java:240)
    at org.testcontainers.containers.ContainerState.getContainerIpAddress(ContainerState.java:29)
    at org.testcontainers.containers.localstack.LocalStackContainer.configure(LocalStackContainer.java:64)
    at org.testcontainers.containers.GenericContainer.doStart(GenericContainer.java:307)
typbug

Most helpful comment

As a workaround, you can call DockerClientFactory.instance().client() before starting the container.

We will fix the bug ASAP and cut another release, sorry for the inconvenience!

All 4 comments

As a workaround, you can call DockerClientFactory.instance().client() before starting the container.

We will fix the bug ASAP and cut another release, sorry for the inconvenience!

Looks like the PR with the fix was merged. Can this be closed yet? Any ETA on when the next release will be cut?

@dparrella fixed in 1.12.5

Was this page helpful?
0 / 5 - 0 ratings