KinematicBody2D collision detection not acurate in every frame?

:information_source: Attention Topic was automatically imported from the old Question2Answer platform.
:bust_in_silhouette: Asked By websterek

Hi, I have problem with detecting collision using KinematicBody2D, for many reason in my project this node seems to works the best but when I’m rotating it (around anchor) most of the time collision detection is perfect, object is stopping when another is colliding, like on this picture:
enter image description here

But sometimes object is stopping inside of the another like here:
enter image description here

How can I solve this problem?