[Regression] Font has been changed inside of Docker from 1.16
See original GitHub issueThe issue: the font has been changed
The reason:
following line has been introduced from 1.16.x . I build my own docker image and install x11vnc, I can also reproduce this issue.
RUN apt-get update && apt-get install -y x11vnc
How to reproduce: Take screenshot in docker 1.15.2 and docker image 1.16.x
Use this locator: xpath=(//body/div)[1]
<!DOCTYPE html>
<html>
<head>
<title>Example Domain</title>
<meta charset="utf-8" />
<meta http-equiv="Content-type" content="text/html; charset=utf-8" />
<meta name="viewport" content="width=device-width, initial-scale=1" />
<style type="text/css">
body {
background-color: #f0f0f2;
margin: 0;
padding: 0;
font-family: -apple-system, system-ui, BlinkMacSystemFont, 'Segoe UI', 'Open Sans', 'Helvetica Neue', Helvetica,
Arial, sans-serif;
}
div {
width: 600px;
margin: 5em auto;
padding: 2em;
background-color: #fdfdff;
border-radius: 0.5em;
box-shadow: 2px 3px 7px 2px rgba(0, 0, 0, 0.02);
}
a:link,
a:visited {
color: #38488f;
text-decoration: none;
}
@media (max-width: 700px) {
div {
margin: 0 auto;
width: auto;
}
}
</style>
</head>
<body>
<div>
<h1>Example Domain</h1>
<p>
This domain is for use in illustrative examples in documents. You may use this domain in literature without
prior coordination or asking for permission.
</p>
<p><a href="https://www.iana.org/domains/example">More information...</a></p>
</div>
</body>
</html>
Issue Analytics
- State:
- Created 2 years ago
- Reactions:1
- Comments:12 (5 by maintainers)
Top Results From Across the Web
[REGRESSION] Change docker from 1.15.x to 1.16.x that all ...
I use v1.16.3 docker image + playwright 1.16.3 + headless chromium 97.0.4666.0 => Screenshot has been changed, tests are failed ...
Read more >Docker Compose release notes | Docker Documentation
Compose v2.9.0 contains changes to the environment variable's precedence that have since been reverted. We recommend using v2.10+ to avoid compatibility issues.
Read more >Docker Desktop for Mac 3.x release notes
Docker Desktop now allows files to be modified inside a host directory which is a nested mountpoint in a container. Fixes docker/for-mac#5748. Fixed...
Read more >How to Fix and Debug Docker Containers Like a Superhero
Container errors are tricky to diagnose, but some investigative magic works wonders. Read along to learn how to debug Docker containers.
Read more >Docker Engine release notes - Docker Documentation
Docker Engine release notes. This document describes the latest changes, additions, known issues, and fixes for Docker Engine.
Read more >
Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free
Top Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Did some more tests with the failing screenshots in my project, installing the package
fonts-dejavu-core
in the 1.17 container before running the tests solves the problem (no other modifications), the snapshot tests succeeded without errors again.When comparing packages installed in the containers, the difference seems to be due to the removal of the
fluxbox
package, which was installed in 1.16.3 but isn’t anymore in 1.17.0. Dependencies of fluxbox (> libfontconfig1 > fontconfig-config > fonts-dejavu-core
) then triggered automatic installation of the font, which apparently is selected when available by Firefox.Maybe consider installing at least the specific font package in the official Dockerfile again to restore the old behavior?
Hi👋, I have the same issue between Docker v1.12.3-focal and github action ubuntu-20.04
When I added this code, the problem was solved.
Font-family and compatibility between Linux, Windows, MacOS X
The problem seems to be that Docker v1.12.3-focal only have Liberation Font
These are github ubuntu font lists:
docker image screenshot:
github action screenshot:
diff: