Assigned variables and keyword run results are printed outside keyword in log file

I have been facing some odd issues related to logging. In our project setup we have mix of keywords defined in resource file level and in custom libraries. We have also few keywords implemented in custom libraries that run keywords from resource files. The last case seems to cause that values assigned to variables are not logged under correct keyword. See screenshot from log file below and also steps to reproduce this issue.

Is there a solution to get logging in this case to work correctly?
It is not a blocker issuer for us but it does make log file readability worse.


  • create first keyword that returns value in resource file
  • create second keyword under custom library
  • use BuiltIn().run_keyword() to run first keyword inside second keyword

Steps to reproduce:

  • create a test case that runs first and second keyword
  • open create log file

Expected result:

  • assigned variable value is logged correctly under each keyword

Actual result:

  • assigned variable value is logged inside second keyword which is somewhat confusing