question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

[Feature] `install-deps` should be more friendly to users of other Linux distros

See original GitHub issue

Currently, only Ubuntu 18.04 and 20.04 are officially supported by Playwright.

Out of the box on Manjaro, playwright is able to be installed and run a tests both in headless and headed mode:

  1. npm i -D @playwright/test
  2. npx playwright install
  3. npx playwright test

Code under test:

const { test, expect } = require('@playwright/test');

test('basic test', async ({ page }) => {
  await page.goto('https://foo.loc/');
  const title = page.locator('.site-title a');
  await expect(title).toHaveText('Foo Test');
});

It works.

However, when I try to execute the same test with more browsers after specifying chromium, firefox and webkit on playwright.config.js, playwright prompts me to install dependencies:

image

When running npx playwright install-deps, I get:

Installing Ubuntu dependencies...
sh: line 1: apt-get: command not found

The error is clear, it tries to install some package with apt-get, which does not exist in Arch Linux. However, it doesn’t tell me which one, so that I can install it on my own.

To get around this, I was trying to figure out what I needed to install on my own. The closest I could get was to this list: https://github.com/microsoft/playwright/blob/d34f9972abf3e412c9a73ee7b524e529a89136f8/packages/playwright-core/src/utils/nativeDeps.ts

But surely I don’t need all of that, as the Chromium works out of the box both headless and headed, so there must be some package missing in my environment that I need to install.

My request is that install-deps be specific about what dependencies are missing, so that users of other distros of Linux can have a chance to manually install the dependencies themselves.

Issue Analytics

  • State:closed
  • Created 2 years ago
  • Reactions:14
  • Comments:27 (8 by maintainers)

github_iconTop GitHub Comments

25reactions
thevintercommented, Jan 28, 2022

I’m also using Arch I am unable to run playwright at the moment because I have no clue what deps I should manually install. At least a list would be great…

12reactions
nglgzzcommented, Feb 25, 2022

I finally managed to get playwright to run Chromium, Firefox and Webkit on Arch by installing these packages:

aur/enchant1.6 aur/icu66 aur/libwebp052

As mentioned in this comment https://github.com/microsoft/playwright/issues/2621#issuecomment-931530175

Read more comments on GitHub >

github_iconTop Results From Across the Web

Top 10 Linux Distros Should be Considered in 2022
Top 10 Linux Distros Should be Considered in 2022. Linux is a free open-source operating system like Microsoft Windows, Apple Mac OS, and...
Read more >
EVERY LINUX DISTRO should have THESE FEATURES!
Get 100$ credit for your own Linux and gaming server: https://www.linode.com/linuxexperiment Grab a brand new laptop or desktop running ...
Read more >
Exploring Linux Distributions: Elementary OS - A Beautiful And ...
In this first blog post of what will likely become a series, we explore what makes me choose elementary OS over everything else....
Read more >
10 Linux Distributions and Their Targeted Users - Tecmint
This article aims at briefing why a certain distro exists, who are the targeted user of the distro, and what special features it...
Read more >
The 5 best Linux distros for beginners in 2022 | ZDNET
Features the Cinnamon (Windows-like) interface; Free to use. What's a Windows 10 user to do? They should turn to Linux Mint, in particular,...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found