Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Jj #747

Closed
rahul-adpushup opened this issue Sep 19, 2022 · 31 comments
Closed

Jj #747

rahul-adpushup opened this issue Sep 19, 2022 · 31 comments

Comments

@rahul-adpushup
Copy link

Getting the following error when running the cypress docker container.
Screenshot 2022-09-19 at 11 32 57 PM

@omgaz
Copy link

omgaz commented Sep 20, 2022

Same, some of our CI specs are failing today.

FROM public.ecr.aws/cypress-io/cypress/base:16.17.0 and 14.18.1

All tests pass when running locally but consistently fail inside the container. I think our failures are unrelated but have been seeing the same error - maybe a coincidence?

@ericcmmi
Copy link

ericcmmi commented Oct 3, 2022

Getting a similar error. We've been using the cypress/included:10.8.0 image to build but the stack trace is showing errors in /root/.cache/Cypress/10.9.0. Tried updating Cypress in our project to 10.9.0 but no change in the error.

libva error: vaGetDriverNameByIndex() failed with unknown libva error, driver_name = (null)
[329:1003/160222.553673:ERROR:gpu_memory_buffer_support_x11.cc(44)] dri3 extension not supported.

@laurentsd
Copy link

Getting the same error in our Jenkins pipeline. Cypress 10.6.

libva error: vaGetDriverNameByIndex() failed with unknown libva error, driver_name = (null)
[1113631:1029/200143.976854:ERROR:gpu_memory_buffer_support_x11.cc(44)] dri3 extension not supported.

@mschaefer-gresham
Copy link

Same issue using cypress/included:10.11.0. Is there an update on this issue?

@milmarqtan
Copy link

I was also getting the same issue in MacOS running cypress/included:10.11.0.

The issue doesn't happen if you have xquartz setup. After xquartz is setup, you need to add a DISPLAY environment variable mapped to the ip/screen xquartz is listening on (e.g. export DISPLAY=192.168.1.8:0) then also pass that to the docker container as an environment variable when you run it. (e.g. docker run -e DISPLAY ...)

@dqiubread
Copy link

is there any update on this? Or a workaround, Currently this is causing our tests on cypress 11 to hang for a very long time after running the ocmmand.

@poponuts
Copy link

same issue. this should be looked at. latest one that worked was prior to 10.11

@laurentsd
Copy link

same problem for our app :-(

@DesaiHimani
Copy link

+1

@dqiubread
Copy link

dqiubread commented Nov 29, 2022

Same, some of our CI specs are failing today.

FROM public.ecr.aws/cypress-io/cypress/base:16.17.0 and 14.18.1

All tests pass when running locally but consistently fail inside the container. I think our failures are unrelated but have been seeing the same error - maybe a coincidence?

After doing some research, it seems those messages dont really mean much. I had to log out all the errors by running the following command and it showing me where it was erroring/hanging in the logs DEBUG=cypress:* cypress run --config-file cypress.config.js --spec "cypress/e2e/start.spec.js"

@vai0
Copy link

vai0 commented Dec 1, 2022

Found this solution which makes the errors go away: https://repo1.dso.mil/platform-one/big-bang/apps/library-charts/gluon/-/issues/7

# Start virtual monitor
export DISPLAY=:1
Xvfb :1 -screen 0 1024x768x16 2>/dev/null &

# After running test, stop virtual monitor
# We probably don't need this since the container will be killed after we run anyways
unset DISPLAY
kill %1

@abdulflorez
Copy link

@vai0 Hi!! Could you tell me where to find this file "Xvfb"?

This extract is from the web that you shared on that link.
"To fix this, you can add a virtual monitor with Xvfb (which is a dependency of Cypress):"

Thanks

@vai0
Copy link

vai0 commented Dec 13, 2022

@vai0 Hi!! Could you tell me where to find this file "Xvfb"?

This extract is from the web that you shared on that link. "To fix this, you can add a virtual monitor with Xvfb (which is a dependency of Cypress):"

Thanks

If you’re using the cypress’ docker image it should already exist

@Githiora
Copy link

Getting the same error when loading the metamask extension in a docker container. Works locally.

@praveentata
Copy link

praveentata commented Feb 6, 2023

Any update on this issue?
I am using cypress/included:12.3.0 docker image and getting the same error.
All my specs are being reported as Pending

====================================================================================================

  (Run Finished)


       Spec                                              Tests  Passing  Failing  Pending  Skipped  
  ┌────────────────────────────────────────────────────────────────────────────────────────────────┐
  │ ✔           sanity_spec.js                  393ms       76        -        -       76        - │
  └────────────────────────────────────────────────────────────────────────────────────────────────┘
    ✔  All specs passed!                        393ms       76        -        -       76        -  

I am not sure if this is related to the actual issue but I don't see any other helpful log which I can use to debug this issue.

Note: I am upgrading from Cypress 8 to Cypress 12. Everything works fine on Cypress 8

Thanks

@MikeMcC399
Copy link
Collaborator

@mkruisman2
Copy link

We're also often getting the same error here, running in CircleCI with Cypress 12.3.0. Is there any update on this?

@MikeMcC399
Copy link
Collaborator

@mkruisman2

We're also often getting the same error here, running in CircleCI with Cypress 12.3.0. Is there any update on this?

Could you confirm exactly which error message you are getting?

@mkruisman2
Copy link

@mkruisman2

We're also often getting the same error here, running in CircleCI with Cypress 12.3.0. Is there any update on this?

Could you confirm exactly which error message you are getting?

@MikeMcC399 This is the exact error that I see:

libva error: va_getDriverName() failed with unknown libva error,driver_name=(null)
[187:0214/151525.172753:ERROR:gpu_memory_buffer_support_x11.cc(44)] dri3 extension not supported.
Can't run because you've entered an invalid browser name.

Browser: chrome was not found on your system or is not supported by Cypress.

Cypress supports the following browsers:
 - electron
 - chrome
 - chromium
 - chrome:canary
 - edge
 - firefox

You can also use a custom browser: https://on.cypress.io/customize-browsers

Available browsers found on your system are:
 - firefox
 - electron
Can't run because you've entered an invalid browser name.

Browser: chrome was not found on your system or is not supported by Cypress.

Cypress supports the following browsers:
 - electron
 - chrome
 - chromium
 - chrome:canary
 - edge
 - firefox

You can also use a custom browser: https://on.cypress.io/customize-browsers

Available browsers found on your system are:
 - firefox
 - electron

Exited with code exit status 1

@MikeMcC399
Copy link
Collaborator

@mkruisman2

Can't run because you've entered an invalid browser name.

You should probably look at why this is happening. It seems you have chosen to use Chrome, but it is not found.

Generally errors like

libva error: va_getDriverName() failed with unknown libva error,driver_name=(null)
[187:0214/151525.172753:ERROR:gpu_memory_buffer_support_x11.cc(44)] dri3 extension not supported.

don't stop tests from running.

For the error message

[187:0214/151525.172753:ERROR:gpu_memory_buffer_support_x11.cc(44)] dri3 extension not supported.

I posted a workaround in cypress-io/cypress#25357 to add the environment variable
ELECTRON_EXTRA_LAUNCH_ARGS: '--disable-gpu'
for GitHub Actions. I'm not familiar with CircleCI, so I don't know if that would be the same syntax there.

@MaksuCode
Copy link

I am also getting the same error with cypress/included:12.6.0 while running the pipeline on circleci. But this does not fail my tests.

image

@AJMcKane
Copy link

We're also seeing this whilst using cypress/browsers:node-18.14.1-chrome-110.0.5481.96-1-ff-109.0-edge-110.0.1587.41-1

image

@tester-at-bmi
Copy link

@AJMcKane OT: Where did you get these images cypress/browsers:node-18.14.1-chrome-110.0.5481.96-1-ff-109.0-edge-110.0.1587.41-1 from? Searching this repo i can't find more recent ones?

@MikeMcC399
Copy link
Collaborator

@tester-at-bmi

Where did you get these images cypress/browsers:node-18.14.1-chrome-110.0.5481.96-1-ff-109.0-edge-110.0.1587.41-1 from? Searching this repo i can't find more recent ones?

Check https://hub.docker.com/r/cypress/browsers/tags

image

If you want to follow up about why you can't find it under https://github.com/cypress-io/cypress-docker-images/tree/master/browsers then I suggest you open a new issue.

@ceddlyburge
Copy link

# Start virtual monitor
export DISPLAY=:1
Xvfb :1 -screen 0 1024x768x16 2>/dev/null &

# After running test, stop virtual monitor
# We probably don't need this since the container will be killed after we run anyways
unset DISPLAY
kill %1

I've not been able to get this workaround to work, does anyone have an example they can point me to?

@MikeMcC399
Copy link
Collaborator

@ceddlyburge

Have you tried the workaround from #747 (comment)?

ELECTRON_EXTRA_LAUNCH_ARGS: '--disable-gpu'

@ceddlyburge
Copy link

I have, it also didn't work for me. It's just a snippet though, so I'm wondering if I'm applying it in the right place?

Also, the xvfb solution mentioned (link below) states that disabling the gpu doesn't work, as the error happens before the browser is started:
https://repo1.dso.mil/big-bang/product/packages/gluon/-/issues/7

It would be good to look at the config for something that has used a workaround successfully

@MikeMcC399
Copy link
Collaborator

@ceddlyburge

It would be good to look at the config for something that has used a workaround successfully

Which version of Cypress are you using? What environment are you running in?

@ceddlyburge
Copy link

HI Mike, I'm using cypress/included:12.4.1.
And the tests are written for cypress 12.3.0
Cheers, Cedd

@MikeMcC399
Copy link
Collaborator

@ceddlyburge

cypress/included:12.4.1.

Sorry I don't have that online, but maybe somebody else can contribute?

ceddlyburge added a commit to ceddlyburge/elm-league-tables-from-google-sheets that referenced this issue May 2, 2023
ceddlyburge added a commit to ceddlyburge/elm-league-tables-from-google-sheets that referenced this issue May 6, 2023
ceddlyburge added a commit to ceddlyburge/elm-league-tables-from-google-sheets that referenced this issue May 17, 2023
@rahul-adpushup rahul-adpushup changed the title ERROR:gpu_memory_buffer_support_x11.cc and vaGetDriverNameByIndex() failed with unknown libva error, driver_name = (null) Jj Jun 6, 2023
@ngohuytrieu
Copy link

I have the same issue with cypress in docker
Version: cypress/included:12.14.0

I tried ENV ELECTRON_EXTRA_LAUNCH_ARGS='--disable-gpu' but still no luck. Anyone has any solution?

cypress:
    image: cypress/included:12.14.0
    working_dir: /e2e
    volumes:
      - ./:/e2e
    environment:
      - ELECTRON_EXTRA_LAUNCH_ARGS='--disable-gpu'
    restart: unless-stopped
    depends_on:
      - app
    networks:
      - test

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests