Skip to content

Missing screenshot in log file when using Browser library from custom python library #4741

@MarvKler

Description

@MarvKler

Describe the bug
I've been using Browser library from python directly instead of using it through .robot / .resource files. I have activated & configured the highlight_on_failure andrun_on_failure library arguments and i would expect to see a screenshot in the robot log file when any keyword of the Browser library fails.

To Reproduce
Steps to reproduce the behavior:

  1. Create your own python library for robot framework
  2. Use Browser library keywords within your custom python keywords
  3. For testing purposes, use any invalid locator or change something else to run into an error
  4. Open the log file
  5. Error is raised & shown in the log file but the screenshot is missing at all.

Expected behavior
The error gets logged into the log file and additionally the Browser library adds the screenshot which should get taken due to the run_on_failure configuration.

Screenshots

Desktop (please complete the following information):

  • OS: WSL (Linux)
  • Browser chrome
  • Version [e.g. 22]

Additional context
Using browser library version 19.12.4

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions