Skip to content

Cannot use Kotlin property syntax on ContainerProperties.idleEventInterval since release 2.7.3 #1900

Closed
@psychobaatezu

Description

@psychobaatezu

Since release 2.7.3, it's not possible anymore to use the Kotlin property syntax on ContainerProperties.idleEventInterval field.

image

This is caused by this commit : 0ee2d49

image

Granted, the field is actually nullable. But by adding the annotation on the getter instead of the actual field, it tells the Kotlin interpreter that the getter will return a nullable Long type (Long?) and the setter will apply the given value to a non-nullable Long Type (Long). This discrepancy blocks Kotlin property syntax because the underneath getter/setter are not for the same type.

So to use 2.7.3, existing code need to change to this to continue to work :

image

The solution to solve that is to put @Nullable annotation on the field instead, which by the way is more accurate.

Metadata

Metadata

Assignees

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions