Releases: uber-go/dig
Releases · uber-go/dig
v1.18.0
v1.17.1
Added
- Suggestions for value vs. pointer elements for slice and array types.
Fixed
- An issue where value group values were not getting decorated
by decorators within the same module when using dig.Export(true). - A typo in docs.
- An issue where false positives in cycle detection were occurring
when providing to a child scope.
Thanks to @paullen and @lcarilla for their contributions to this release.
v1.17.0
Added
- Allow using
dig.As
withdig.Group
. - Add
FillInvokeInfo
Option andInvokeInfo
struct to help
extract the types requested by anInvoke
statement. - To get visibility into constructor and decorator calls, introduce
WithProviderCallback
andWithDecoratorCallback
Options to provide callback functions.
v1.16.1
v1.16.0
v1.15.0
v1.14.1
Fixed
- Fix an issue where a dependency for a decoration supplied by another decorator in the
same scope is ignored. - Fix a panic when submitting a single value as a value group in
Scope.Decorate
. - Upon a provide error, make the error message contain the function named specified
by LocationForPC Option.
v1.14.0
Added
- Introduce
dig.Scope
which creates a scoped dependency injection
container to scope dependencies. - Introduce
Scope.Decorate
andContainer.Decorate
which allows a
decorator to modify a dependency already provided in the dependency graph. - Add
FillDecorateInfo
Option andDecorateInfo
struct which exposes
information on what Dig was able to understand from the decorator provided
withScope.Decorate
orContainer.Decorate
.
Changed
- The error message that appears when a cycle is detected in the dependency graph
has been changed slightly.
Fixed
- A stack overflow bug that happens when cycles are introduced via self-pointing
dependencies with DeferAcyclicVerification.