The swagger generated JAVA client ApiClient.setDebugging() function is always throwing an exception because it tries to insert an interceptor into a list of interceptor of the OkHttpClient that is immutable once built.
A workaround is to convert the OkHttpClient into a builder before updating it, as proposed in this pull request #4793