setup-chrome icon indicating copy to clipboard operation
setup-chrome copied to clipboard

`libasound2` has no installation candidate on `ubuntu-latest` or `ubuntu-24.04`

Open stephanschielke opened this issue 1 year ago • 2 comments

jobs:
  ui-test:
    runs-on: ubuntu-24.04
    steps:
      - name: "Install Chrome Browser"
        uses: browser-actions/setup-chrome@v1
        with:
          chrome-version: latest
          install-dependencies: true

fails with:

/usr/bin/sudo apt-get install --yes --no-install-recommends libglib2.0-0 libgconf-2-4 libatk1.0-0 libatk-bridge2.0-0 libgdk-pixbuf2.0-0 libgtk-3-0 libgbm-dev libnss3-dev libxss-dev libasound2 xvfb fonts-liberation libu2f-udev xdg-utils
Reading package lists...
Building dependency tree...
Reading state information...
Package libasound2 is a virtual package provided by:
  liboss4-salsa-asound2 4.2-build2020-1ubuntu3
  libasound2t64 1.2.11-1build2 (= 1.2.11-1build2)

E: Unable to locate package libgconf-2-4
E: Package 'libasound2' has no installation candidate
Error: The process '/usr/bin/sudo' failed with exit code 100

Can be hotfixed by pinning the ubuntu version to ubuntu-22.04

stephanschielke avatar Oct 14 '24 12:10 stephanschielke

Same problem here

chloe5685 avatar Oct 14 '24 16:10 chloe5685

Logs:

Operating System
  Ubuntu
  24.04.1
  LTS
  
Runner Image
  Image: ubuntu-24.04
  Version: 20241006.1.0

Run browser-actions/setup-chrome@v1
  with:
    chrome-version: 130.0.6690.0
    install-dependencies: true
    install-chromedriver: true
    no-sudo: false

Fails with:

Reading package lists...
/usr/bin/sudo apt-get install --yes --no-install-recommends libglib2.0-0 libgconf-2-4 libatk1.0-0 libatk-bridge2.0-0 libgdk-pixbuf2.0-0 libgtk-3-0 libgbm-dev libnss3-dev libxss-dev libasound2 xvfb fonts-liberation libu2f-udev xdg-utils
Reading package lists...
Building dependency tree...
Reading state information...
Package libasound2 is a virtual package provided by:
  liboss4-salsa-asound2 4.2-build2020-1ubuntu3
  libasound2t64 1.2.11-1build2 (= 1.2.11-1build2)

E: Unable to locate package libgconf-2-4
E: Package 'libasound2' has no installation candidate
Error: The process '/usr/bin/sudo' failed with exit code 100

lykmapipo avatar Oct 15 '24 05:10 lykmapipo

This issue needs an enhancement to the action, so that it differentiates according to the version of Debian / Ubuntu in use.

The Ubuntu 24.04 (Noble Numbat) Release Notes explain in the section "Year 2038 support for the armhf architecture":

Ubuntu 24.04 LTS solves the Year 2038 problem 2.0k that existed on armhf. More than a thousand packages have been updated to handle time using a 64-bit value rather than a 32-bit one, making it possible to handle times up to 292 billion years in the future.

That is the reason for the new name libasound2t64 with t64 at the end.

MikeMcC399 avatar Nov 19 '24 11:11 MikeMcC399

I hit this same issue on Ubuntu 24.04 and Ubuntu 24.10. I recently updated my C# project to DotNet 9.0 which currently requires 24.10 so if I want to use the same build machine for that project I HAVE TO run 24.10.

For me the work around was to set install-dependencies: false and manually install the dependencies on the machine. You could probably also run this as a build step before setup-chrome.

I found this list of dependencies from some other issues about running chrome on 24.10 and a little trial and error. I'm not 100% sure that all of these dependencies are required, but adding them made it work. So I'm happy for now. Hope this helps someone else.

sudo apt install -y --no-install-recommends \
  libnss3 \
  libdbus-1-3 \
  libatk1.0-0 \
  libasound2t64 \
  libxrandr2 \
  libxkbcommon-dev \
  libxfixes3 \
  libxcomposite1 \
  libxdamage1 \
  libgbm-dev \
  libatk-bridge2.0-0 \
  binutils \
  libglib2.0-0 \
  libgdk-pixbuf2.0-0 \
  libgtk-3-0 \
  libnss3-dev \
  libxss-dev \
  xvfb \
  fonts-liberation \
  libu2f-udev \
  xdg-utils

itslenny avatar Nov 20 '24 15:11 itslenny

Hello, folks! I still face the same problem on my GHA workflows with this library. My workflow template is hayat01sh1da/tutorials/.github/workflows/minitest.yml.

Log
Run browser-actions/setup-chrome@v1
Installing dependencies
/usr/bin/sudo apt-get update
Get:1 file:/etc/apt/apt-mirrors.txt Mirrorlist [142 B]
Hit:6 https://packages.microsoft.com/repos/azure-cli noble InRelease
Get:[7](https://github.com/hayat01sh1da/tutorials/actions/runs/12954852562/job/36137698068#step:7:8) https://packages.microsoft.com/ubuntu/24.04/prod noble InRelease [3600 B]
Hit:2 http://azure.archive.ubuntu.com/ubuntu noble InRelease
Get:3 http://azure.archive.ubuntu.com/ubuntu noble-updates InRelease [126 kB]
Get:4 http://azure.archive.ubuntu.com/ubuntu noble-backports InRelease [126 kB]
Get:5 http://azure.archive.ubuntu.com/ubuntu noble-security InRelease [126 kB]
Get:[8](https://github.com/hayat01sh1da/tutorials/actions/runs/12954852562/job/36137698068#step:7:9) https://packages.microsoft.com/ubuntu/24.04/prod noble/main arm64 Packages [12.0 kB]
Get:[9](https://github.com/hayat01sh1da/tutorials/actions/runs/12954852562/job/36137698068#step:7:10) https://packages.microsoft.com/ubuntu/24.04/prod noble/main armhf Packages [6615 B]
Get:[10](https://github.com/hayat01sh1da/tutorials/actions/runs/12954852562/job/36137698068#step:7:11) https://packages.microsoft.com/ubuntu/24.04/prod noble/main amd64 Packages [18.6 kB]
Get:[11](https://github.com/hayat01sh1da/tutorials/actions/runs/12954852562/job/36137698068#step:7:12) http://azure.archive.ubuntu.com/ubuntu noble-updates/main amd64 Packages [783 kB]
Get:[12](https://github.com/hayat01sh1da/tutorials/actions/runs/12954852562/job/36137698068#step:7:13) http://azure.archive.ubuntu.com/ubuntu noble-updates/main Translation-en [178 kB]
Get:13 http://azure.archive.ubuntu.com/ubuntu noble-updates/main amd64 Components [151 kB]
Get:14 http://azure.archive.ubuntu.com/ubuntu noble-updates/universe amd64 Packages [977 kB]
Get:15 http://azure.archive.ubuntu.com/ubuntu noble-updates/universe amd64 Components [3[13](https://github.com/hayat01sh1da/tutorials/actions/runs/12954852562/job/36137698068#step:7:14) kB]
Get:16 http://azure.archive.ubuntu.com/ubuntu noble-updates/restricted amd64 Components [212 B]
Get:17 http://azure.archive.ubuntu.com/ubuntu noble-updates/multiverse amd64 Components [940 B]
Get:18 http://azure.archive.ubuntu.com/ubuntu noble-backports/main amd64 Components [208 B]
Get:19 http://azure.archive.ubuntu.com/ubuntu noble-backports/universe amd64 Components [17.7 kB]
Get:20 http://azure.archive.ubuntu.com/ubuntu noble-backports/restricted amd64 Components [2[16](https://github.com/hayat01sh1da/tutorials/actions/runs/12954852562/job/36137698068#step:7:17) B]
Get:21 http://azure.archive.ubuntu.com/ubuntu noble-backports/multiverse amd64 Components [212 B]
Get:22 http://azure.archive.ubuntu.com/ubuntu noble-security/main amd64 Components [7212 B]
Get:23 http://azure.archive.ubuntu.com/ubuntu noble-security/universe amd64 Components [52.0 kB]
Get:24 http://azure.archive.ubuntu.com/ubuntu noble-security/restricted amd64 Components [212 B]
Get:25 http://azure.archive.ubuntu.com/ubuntu noble-security/multiverse amd64 Components [212 B]
Fetched 2900 kB in 1s (4991 kB/s)
Reading package lists...
/usr/bin/sudo apt-get install --yes --no-install-recommends libglib2.0-0 libgconf-2-4 libatk1.0-0 libatk-bridge2.0-0 libgdk-pixbuf2.0-0 libgtk-3-0 libgbm-dev libnss3-dev libxss-dev libasound2 xvfb fonts-liberation libu2f-udev xdg-utils
Reading package lists...
Building dependency tree...
Reading state information...
Package libasound2 is a virtual package provided by:
  liboss4-salsa-asound2 4.2-build[20](https://github.com/hayat01sh1da/tutorials/actions/runs/12954852562/job/36137698068#step:7:21)20-1ubuntu3
  libasound2t64 1.2.11-1build2 (= 1.2.11-1build2)

E: Unable to locate package libgconf-2-4
E: Package 'libasound2' has no installation candidate
Error: The process '/usr/bin/sudo' failed with exit code 100

hayat01sh1da avatar Jan 24 '25 17:01 hayat01sh1da

@hayat01sh1da

Hello, folks! I still face the same problem on my GHA workflows with this library. My workflow template is hayat01sh1da/tutorials/.github/workflows/minitest.yml.

Have you tried it without the following (delete or comment out)

        with:
          install-dependencies: true

ubuntu-latest has the dependencies which are necessary for Chrome already installed, as it already ships with a default Chrome version.

MikeMcC399 avatar Jan 24 '25 18:01 MikeMcC399

@hayat01sh1da

Hello, folks! I still face the same problem on my GHA workflows with this library. My workflow template is hayat01sh1da/tutorials/.github/workflows/minitest.yml.

Have you tried it without the following (delete or comment out)

        with:
          install-dependencies: true

ubuntu-latest has the dependencies which are necessary for Chrome already installed, as it already ships with a default Chrome version.

@MikeMcC399

Thank you for your reply, Mike san!

No, I haven't tried your suggestion yet. I'll give it a try tonight in the hope that the failure will be solved.

If the problem lingers, I'll contact you here again.

I appreciate your sharing the tips.

hayat01sh1da avatar Jan 25 '25 07:01 hayat01sh1da

@hayat01sh1da

Hello, folks! I still face the same problem on my GHA workflows with this library. My workflow template is hayat01sh1da/tutorials/.github/workflows/minitest.yml.

Have you tried it without the following (delete or comment out)

        with:
          install-dependencies: true

ubuntu-latest has the dependencies which are necessary for Chrome already installed, as it already ships with a default Chrome version.

@MikeMcC399

Thank you for your reply, Mike san!

No, I haven't tried your suggestion yet. I'll give it a try tonight in the hope that the failure will be solved.

If the problem lingers, I'll contact you here again.

I appreciate your sharing the tips.

@MikeMcC399

I confirmed the solution works for me. Thank you for your help, Mike san!

hayat01sh1da avatar Jan 25 '25 08:01 hayat01sh1da

Thanks for reporting. It's now fixed in v1.7.3. Please try it.

ueokande avatar Jan 25 '25 09:01 ueokande