gauge: Unable to view screenshots in the html reports

The screenshots are not getting displayed in the reports html page and the screenshots are getting generated under the folder-images with the screenshot address as (/reports/html-report/images/screenshot-*.png) and but for my friend he gets the screenshots images displayed on the reports html without any issues and the when we do a right click we get the address as “data:image/png;base64,” and for screenshots we are using the below code and with the below addons.

Please help me to fix this issue. TIA!

gauge.screenshotFn = async function () { return await screenshot({ encoding: "base64" });

gauge -v
Gauge version: 1.2.1
Commit Hash: fa7918b
Plugins
-------
html-report (4.0.12)
js (2.3.16)
json-report (0.3.5)
reportportal (1.12.0)
screenshot (0.0.1)
xml-report (0.2.3)

taiko -v
Version: 1.0.3 (Chromium: 81.0.3994.0) RELEASE

About this issue

  • Original URL
  • State: closed
  • Created 3 years ago
  • Comments: 16 (6 by maintainers)

Most upvoted comments

Looks like the report html is looking for screenahot images relative to it’s path rather than the root folder. Can you try without setting gauge_screenshots_dir? It ahould pick defaults

  • Please upgrade gauge and html report plugin to the latest versions
  • Refer taking screenshots to update you code to use the right way of taking screenshots.