Generating code with openapi generator plugin

I somehow gets the wrong version of jackson for the plugin. I get a NoSuchMethodException on a YAMLFactory method. I think get this error because of the build script is updating the jackson dependency.

How do I see what is upgrading the jackson dependency?
Is there a way to look at the build script classpath?

I can’t figure out how I have missed the buildEnvironment task. That answers my question.

I had a similar issue with Google’s Plugin for the GCP Artifacts repo. I had to explicitly add the version of Jackson that I needed in settings.gradle:

buildscript {
    repositories {
        mavenCentral()
        gradlePluginPortal()
        mavenLocal()
    }
    dependencies {
        classpath("gradle.plugin.com.google.cloud.artifactregistry:artifactregistry-gradle-plugin:2.2.2")
        // The Google Gradle Plugin pulls in some old jackson dependency which causes the OpenAPI code generator
        // to fail. The solution is to explicitly add the correct version to the class path.
        classpath("com.fasterxml.jackson.core:jackson-core:2.17.2")
    }
}

That is the solution. I just applied it to a build.gradle file.

It turned out that I didn’t need the dependencies that pulled in the old versions any more.