Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Unable to resolve KspTaskJvm task #1623

Open
chirdeeptomar opened this issue Nov 27, 2023 · 1 comment
Open

Unable to resolve KspTaskJvm task #1623

chirdeeptomar opened this issue Nov 27, 2023 · 1 comment

Comments

@chirdeeptomar
Copy link

I am using Kotlin 1.9.20 with Gradle 8.4 with id("com.google.devtools.ksp") version "1.9.20-1.0.14" in a gradle multimodule project and I am unable to build the project. Getting the errors below:

  • What went wrong:
    Some problems were found with the configuration of task ':xxxxx:kspKotlin' (type 'KspTaskJvm').
    • Gradle detected a problem with the following location: 'C:\Users...\ServiceGrpc.java'.

      Reason: Task ':xxxxx-rest:kspKotlin' uses this output of task ':xxxxx-rest:generateProto' without declaring an explici
      t or implicit dependency. This can lead to incorrect results being produced, depending on what order the tasks are executed.

      Possible solutions:

      1. Declare task ':xxxxx-rest:generateProto' as an input of ':xxxxx-rest:kspKotlin'.
      2. Declare an explicit dependency on ':xxxxx-rest:generateProto' from ':xxxxx-rest:kspKotlin' using Task#dependsOn.
      3. Declare an explicit dependency on ':xxxxx-rest:generateProto' from ':xxxxx-rest:kspKotlin' using Task#mustRunAfte
        r.

When setting explicit dependency as suggest, gradle is unable to find the task kspKotlin.

Thanks

@Lysander
Copy link

Have a look to my comment here: #963 (comment)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants