dgtlmoon / dgtlmoon/changedetection.io
[feature] Abiilty to set window size with Playwright
- Dominant language
- Python
- Stars
- 34.1k
- Forks
- 2k
- Avg merge
- 23h 38m
- Merged PRs (30d)
- 67
Description
**Describe the bug**
When Playwright is enabled and screen size is set as env variables these values are ignored.
```
- SCREEN_WIDTH=1920
- SCREEN_HEIGHT=1024
```
Also by adding them as launch options with `--window-size=1920,1080` doesn't solve the issue, because each time the fetcher runs it manually set page size to 1280 x 720 [here](https://github.com/dgtlmoon/changedetection.io/blob/6e71088cde5f6e8c8fd24909a931877d9e032e56/changedetectionio/content_fetcher.py#L476)
**Version**
Docker compose
**To Reproduce**
Steps to reproduce the behavior:
1. Enable PLAYWRIGHT_DRIVER_URL and playwright-chrome service from the docker compose
2. Enable SCREEN_WIDTH or height to a custom value
3. Set a new job with Playwright fetch method to a website that checks webpage size, for example: https://browsersize.com/
4. See screenshot with 1280 x 720 size
**Expected behavior**
Custom set windows size
**Screenshots**

**Additional context**
The implementation should be configured here:
https://github.com/dgtlmoon/changedetection.io/blob/6e71088cde5f6e8c8fd24909a931877d9e032e56/changedetectionio/content_fetcher.py#L476
Contributor guide
Assessment
This issue has not been assessed yet.