51 lines
1.4 KiB
Markdown
51 lines
1.4 KiB
Markdown
---
|
||
title: playwright报错Host system is missing dependencies
|
||
tags: exception
|
||
categories: 异常处理
|
||
date: 2022-04-12 13:59:34
|
||
---
|
||
|
||
在使用playwright的过程中,在linux中运行总是会出现各种依赖问题,今天尝试解决。
|
||
# playwright
|
||
|
||
## 报错 **Host system is missing dependencies**
|
||
|
||
+ 系统:centos7
|
||
+ playwright: 使用go-playwright@v1.14
|
||
+ 浏览器: firefox
|
||
+ 具体报错
|
||
<details>
|
||
<summary>展开查看</summary>
|
||
<pre><code>
|
||
could not send message: could not send message to server: Host system is missing dependencies!
|
||
Missing libraries are:
|
||
libgtk-3.so.0
|
||
libgdk-3.so.0
|
||
libX11.so.6
|
||
libX11-xcb.so.1
|
||
libxcb.so.1
|
||
libXcomposite.so.1
|
||
libXcursor.so.1
|
||
libXdamage.so.1
|
||
libXext.so.6
|
||
libXfixes.so.3
|
||
libXi.so.6
|
||
libXrender.so.1
|
||
libfontconfig.so.1
|
||
libpangocairo-1.0.so.0
|
||
libpango-1.0.so.0
|
||
libharfbuzz.so.0
|
||
libatk-1.0.so.0
|
||
libcairo-gobject.so.2
|
||
libcairo.so.2
|
||
libgdk_pixbuf-2.0.so.0
|
||
libxcb-shm.so.0
|
||
libpangoft2-1.0.so.0
|
||
libXt.so.6
|
||
</code></pre>
|
||
</details>
|
||
|
||
### 解决方式,先查询playwright的[issue](https://github.com/microsoft/playwright/issues/5893)
|
||
```shell
|
||
yum -y install libappindicator-gtk3 && yum -y install liberation-fonts && yum install libXt
|
||
``` |