simonw / simonw/shot-scraper

Some elements not properly loading

Open
#175 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
Python
Stars
2.6k
Forks
128
Avg merge
9d 15h
Merged PRs (30d)
2

Description

Description

I’m using shot‑scraper from the command line to capture a PDF screenshot a web application dashboard(Thingsboard). Although the page displays the legend with colored indicators in the browser, the generated PDF is missing the color indicator next to the legend.

the code i use:

shot-scraper pdf https://demo.thingsboard.io/dashboard/e8e409c0-f2b5-11e6-a6ee-bb0136cc33d0?publicId=963ab470-34c9-11e7-a7ce-bb0136cc33d0 --wait 10000 --width 1288 --height 1000 --media-screen -o /home/user/Desktop/example.pdf

How said widget appear normally at dashboard:
Image

How it appears at generated pdf:
Image

Problem being legend section's coloring not appearing.(if you try example code same problem will appear)

I tried to resize the widget, change the legends placement to side from bottom.
I tried adding the --media-screen flag. However, this did not resolve the problem as well.

Environments used

Shot-scraper version 1.8
OS: Ubuntu 24.04

Not sure how to go about solving this any help appreciated.

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start by reproducing the provided shot-scraper pdf command against the ThingsBoard dashboard URL and compare the browser rendering with the generated PDF. Investigate the missing legend color indicators in PDF output; done means the indicators appear in the generated PDF while preserving the existing command options.

Written by the indexing model from the issue text.

Assessment

Tech stack
playwright, python
Domain
cli
Issue type
Bug
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Needs clarification
Newbie friendliness
25/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.