I got this error message when compiling code generated from the OpenAPI generator:
package com.google.gson.internal.bind.util is declared in module com.google.gson, which does not export it
In my build.gradle I used this dependency:
implementation 'com.google.code.gson:gson:2.10.1'
and in my module-info.java I included:
requires com.google.gson;