All Versions
12
Latest Version
Avg Release Cycle
34 days
Latest Release
52 days ago

Changelog History
Page 1

  • v2.25.2

    October 23, 2019

    Known breaking changes

    • The Kotlin change in 2.ii (below) will break users who were passing in object module
      🏗 instances into a Component builder method rather than using @JvmStatic.
      🏗 To fix this issue, remove the call to the builder method -- the module instance is
      🏗 no longer needed and the Component builder method will no longer be generated.

    What's new

    🐛 Bug fixes

    1. Fix duplicate missing binding error messages. (2411074)
    2. Fix dagger-spi pom file from dependency cycle. (3699697)
    3. Fix issue with missing shaded deps from release 2.25 (efe1b00)

    👍 Kotlin support

    1. Qualifier annotations on fields can now be understood without
      The need for @field:MyQualifier (646e033)
    2. @Module object classes no longer need @JvmStatic on the
      provides methods. (0da2180)

    🐎 Performance Improvements

    1. Build performance:
    2. Runtime performance:
      • _Factory proxy methods can now be accessed without
        class loading the factory (a258d37).
  • v2.25

    October 21, 2019
  • v2.24

    July 25, 2019
    • 🗄 Deprecations/removals
      • dagger.android's Has{Activity,Fragment,Service,ContentProvider,BroadcastReceiver} interfaces are now removed in favor of HasAndroidInjector (which can handle any type). HasAndroidInjector was added in 2.23, and is supported together with the old types in that version. (3bd8f70)
    • 🐛 Bug fixes
      • Duplicate keys were erroneously not detected when MapKey.unwrapValue=false which may have resulted in a runtime error (depending on whether fastInit mode was used). This is now detected and failed at compile time. (8b5dbea)
    • 🐎 Build performance
      • Gradle's incremental annotation processing is now enabled for all builds (50bc180)
  • v2.23.2

    June 19, 2019

    🚀 In addition to the 2.23.1 release notes, this release:

    • 🛠 Fixes a bug where an @Inject method has a parameter name that is valid on the JVM but invalid for the Java language (and can come up in some cases in Kotlin: a11605c)
    • ⚠ Suppresses all unchecked/rawtypes warnings in Dagger generated code (ce23333)
  • v2.23.1

    May 30, 2019

    🚀 In addition to the 2.23 release notes, this release fixes support for gradle incremental annotation processing (a91d962)

  • v2.23

    May 28, 2019
    • Validation/strictness
      • Generated components are no longer public unless the component type is public (298dea8)
      • @BindsInstance annotations are now more strictly validated (d3ed46d)
    • 🐎 Build performance
      • Generated code is no longer formatted by default. Use -Adagger.formatGeneratedSource=enabled to turn it on. (fcd069c)
      • General build performance improvements (7e374b5)
    • Android
      • Added dagger.android.HasAndroidInjector, which will soon replace the Has*Injector interfaces. This one interfaces coalesces the others and should be functionally equivalent. (8f01526)
    • Full Binding Graph Validation
      • Rename -Adagger.moduleBindingValidation to -Adagger.fullBindingGraphValidation. The old name continues to work as an alias. (add5a74)
      • Do full binding graph validation for components and subcomponents, not just modules. (15d20f8)
    • 🐛 Bug Fixes
      • Fixed an issue where @BindsInstance on a Builder setter method's parameter caused a failure in codegen if the parameter had a different name than the method itself (#1464). (8051d28)
  • v2.22.1

    April 03, 2019

    🚀 In addition to the 2.22 release notes, this release fixes an issue where @BindsInstance on a @Component.Builder setter method's parameter caused a failure in code generation if the parameter had a different name than the method itself (#1464). (8051d28)

  • v2.22

    April 02, 2019

    🚀 NOTE: A bug in the Dagger compiler was introduced in this release. A fix is available in 2.22.1

    • ➕ Add the ability to create @Component.Factory types for components instead of @Component.Builders. An @Component.Factory is stateless and has a single method, returning the creator type, that takes parameters for anything that a Builder could have setters for. (d340886)
    • 🏗 @BindsInstance can now be applied to the parameter of a setter method on a builder rather than to the setter method itself, for consistency with factory methods. (60dc2a6)
    • 🏗 When a single instance of a component builder with no setter for a particular module that Dagger can instantiate is used to instantiate multiple component instances, provide a new instance of that module to each component rather than caching and reusing a single instance of the module for each component. (fa714e9)
    • Public modules are now allowed to include non-public modules when those included modules do not require an instance: that is, they only have abstract and/or static binding methods. (bfdecad)
    • 🛠 Fix @BindsOptionalOf methods to require that they have a different name than any other binding method in the module; this was already true for all other types of binding methods (@Provides, @Binds etc.) but @BindsOptionalOf wasn't being included. (1ea36ec)
    • 👍 Report an error for scopes on @Multibinds methods. This was never supported, but the scope was previously ignored. (9582bc3)
    • Limit the number of requests and entry points reported explicitly for errors. (1d5d829)
    • 🏗 SPI: Renamed BindingKind.SUBCOMPONENT_BUILDER to SUBCOMPONENT_CREATOR to reflect the fact that it can be a builder or a factory, and renamed the edge type to SubcomponentCreatorBindingEdge. (65e2209)
    • 🐎 Build performance improvements:
  • v2.21

    January 16, 2019
    • 🐎 Build performance improvements (174a7a9)
      • Separately, there may be an increase in build times for opensource users using javac9 or javac10. Neither javac8 or javac11 should be affected. (96fcce8)
    • 🆕 New validation:
      • Installing a module with scoped bindings that an ancestor component has also installed is now an error. (4695ff5)
      • A warning is now reported if an explicit binding conflicts with an @Inject binding in an ancestor component. This was never intended to be supported but never checked. Adds a flag to control whether that is a warning or an error. (7f5500f)
      • Installing a @ProducerModule in a @Subcomponent that is already installed in a parent (or earlier ancestor) component is now an error. It is also an error to repeat a @Module that has a binding in @ProductionScope. (68b2153)
    • SPI
      • New method: ComponentNode.isSubcomponent() (b6b9dca)
    • Producers
      • Deprecated dagger.producers.internal.Producers.immediateProducer() and dagger.producers.internal.Producers.immediateFailedProducer() in favor of newly added methods with the same names in dagger.producers.Producers (a4914c6) (added in 50d7010)
    • Properly generate components when qualifiers are generated (ab9cdbc)
    • Dagger itself now uses more Dagger (97fce1e)
  • v2.20

    December 20, 2018
    • Peformance improvements in annotation processing (8012ab5)
    • Report duplicate bindings only once, not once per request. (623461f)
    • 👉 Make sure all processing steps defer elements properly if they have missing types. (3b0fcc8)
    • 👉 Make @ProductionComponent have runtime retention so tools can interpret it like all of the other component annotations (fff65e3)
    • 325b516:
      • Add module-level validation. When -Adagger.moduleBindingValidation=ERROR or =WARNING is set, then each module is processed as a kind of component (without generating any code) in order to validate the bindings installed by it and all included modules. Any binding graph errors, such as duplicate bindngs (but not including missing bindings), will be reported as errors or warnings depending on the option.
    • Report map multibinding contribution errors once regardless of whether the map is requested as Map<K, V>, Map<K, Provider<V>>, or Map<K, Producer<V>>. (350368e)
    • c7e7c4f:
      • Fixes two bugs related to @ProductionScope bindings:
      • Where modules with @ProductionScope bindings are installed in multiple components in the same component ancestry, the binding is now resolved only once and only in the rootmost component.
      • When @Inject bindings with @ProductionScope are referenced in a binding graph, the binding is now resolved in the rootmost @ProductionScope component.
    • 221f000:
      • dagger.android code can no longer use the AndroidInjector.Factory<? extends Activity> format to bind injector factories. See https://google.github.io/dagger/android and the 2.19 release notes for information on how to migrate.
      • Adds an ErrorProne refactoring for migrating from AndroidSupportInjectionModule (which now is functionless) to AndroidInjectionModule. See these docs for how to apply the refactoring to your codebase if you're on dagger-compiler-2.20.
    • ✂ Removed dagger.releaseablereferences (a72c342)
    • ✂ Removed the -Adagger.floatingBindsMethods flag added in 2.17 (https://github.com/google/dagger/wiki/Dagger-2.17-@Binds-bugs) (bc8dd5b)