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

Scabbard applies itself even when dagger is not present/used #49

Open
ZacSweers opened this issue May 21, 2020 · 4 comments
Open

Scabbard applies itself even when dagger is not present/used #49

ZacSweers opened this issue May 21, 2020 · 4 comments
Assignees
Labels
bug Something isn't working module:gradle-plugin Label to mark all discussions about gradle plugin needs investigation Needs investigation to determine course of action
Milestone

Comments

@ZacSweers
Copy link
Contributor

This leads to warnings in kapt when it doesn't run

warning: The following options were not recognized by any processor: '[scabbard.failOnError, scabbard.outputFormat, kapt.kotlin.generated, dagger.fullBindingGraphValidation]'
> Task :calendar-api-model:kaptReleaseKotlin
warning: The following options were not recognized by any processor: '[scabbard.failOnError, scabbard.outputFormat, kapt.kotlin.generated, dagger.fullBindingGraphValidation]'

@arunkumar9t2 arunkumar9t2 added the module:gradle-plugin Label to mark all discussions about gradle plugin label May 21, 2020
@arunkumar9t2
Copy link
Owner

Thanks, noted. Will target a fix for 0.3.1.

@arunkumar9t2 arunkumar9t2 added this to the 0.3.1 milestone May 21, 2020
@arunkumar9t2 arunkumar9t2 added the bug Something isn't working label Jun 6, 2020
@arunkumar9t2 arunkumar9t2 self-assigned this Jun 6, 2020
@arunkumar9t2
Copy link
Owner

arunkumar9t2 commented Jun 10, 2020

I took at shot at this in #53 but it is not fully fixed yet.

New behaviors

  1. Scabbard will lazily apply its dependencies only when the configuration is resolved and dagger is present in the project.
  2. For Java projects, compiler arguments will be added lazily and only if dagger is there.
  3. Kapt is a different story
    • Kapt eagerly evaluates and applies the kapt arguments during plugin application. This means I have to pass arguments very early but at that time dependencies might not be available. Technically I can do configuration.dependencies.all {} or whenObjectAdded but that cause eager evaluation and I want to avoid it for now. Created https://youtrack.jetbrains.com/issue/KT-39521
    • I thought The following options were not recognized by any processor warning was spit out based on supported options alone but it seems to check for supportedTypes as well. Checking for dagger presence alone might not be sufficient to avoid this error. Failing functional test.

I will keep this open and look for any workaround.

@arunkumar9t2 arunkumar9t2 added the needs investigation Needs investigation to determine course of action label Jun 10, 2020
@arunkumar9t2
Copy link
Owner

Update: I saw this JetBrains/kotlin@19708cf and also now Kapt options are using provider instead of evaluating eagerly. I will investigate if this can be fixed soon,

@ruieduardosoares
Copy link

@arunkumar9t2 i also have this issue an nothing is being generated in kapt3/classes/ folder.
image

@arunkumar9t2 arunkumar9t2 modified the milestones: 0.4.0, 0.5.1 Jun 20, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working module:gradle-plugin Label to mark all discussions about gradle plugin needs investigation Needs investigation to determine course of action
Projects
None yet
Development

No branches or pull requests

3 participants