micronaut-data icon indicating copy to clipboard operation
micronaut-data copied to clipboard

bugfix/issue-3619-kotlin-coroutine-null-value into 4.14.x

Open stevenlmcgraw opened this issue 1 month ago • 2 comments

Issue #3619:

Only convert new NullValue() when target is kotlinx.coroutines.flow.Flow in DataIntroductionAdvice::interceptCompletionStage to resolve issue with returning non-null string of NullValue[]

stevenlmcgraw avatar Nov 26 '25 01:11 stevenlmcgraw

I'm uncertain if this is a naive fix for this scenario, but it does seem a simple way to resolve the problem in the reproducer example in https://github.com/micronaut-projects/micronaut-data/issues/3619 .

It's the only other place that NullValue is used anywhere and it aligns to the check for Flow performed in io.micronaut.data.runtime.intercept.async.AbstractAsyncInterceptor, so I think it would do the trick and preserve the behavior that prompted introducing NullValue in the first place.

I'm happy to adjust the commit on any feedback and add unit tests for the change, however, I am uncertain of where to place any unit tests for this adjustment.

Let me know, thanks!

stevenlmcgraw avatar Nov 26 '25 01:11 stevenlmcgraw

Pls target 5.x

dstepanov avatar Dec 12 '25 09:12 dstepanov