Incorrect step assignments with custom step function

Does seems like a bug, @ricardoV94 any idea?