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

When running tests with the "chrome:latest" browser and VNC port the outdated -debug image is used #317

Open
marinaglancy opened this issue Feb 26, 2025 · 3 comments

Comments

@marinaglancy
Copy link
Member

marinaglancy commented Feb 26, 2025

In this commit cb73fdd we no longer use selenium/standalone-chrome-debug image for the newer versions of chrome. However we still use it with the "latest" version

Example:

MOODLE_DOCKER_BROWSER="chrome:latest"
MOODLE_DOCKER_SELENIUM_VNC_PORT=""

uses the image selenium/standalone-chrome:latest

However

MOODLE_DOCKER_BROWSER="chrome:latest"
MOODLE_DOCKER_SELENIUM_VNC_PORT=1234

uses the image selenium/standalone-chrome-debug:latest which is some older version :(

@marinaglancy
Copy link
Member Author

ping @NoelDeMartin - I'm not sure which issue this commit is related to and where I should comment about it

@marinaglancy marinaglancy changed the title When running tests with the latest image and VNC port the -debug image is used When running tests with the "chrome:latest" browser and VNC port the outdated -debug image is used Feb 26, 2025
@NoelDeMartin
Copy link
Contributor

I added that in #281, when I realized that starting in version 4 selenium images don't use the -debug suffix anymore. However, looking at the code I don't understand how using a different VNC port changes that if :/. I guess someone would have to debug it, but TLDR the suffix should only be used for selenium versions previous to 4.0. And seeing that the last -debug release came out 3 years ago, maybe you can remove it altogether.

@marinaglancy
Copy link
Member Author

hi @NoelDeMartin , this is the code

if [[ $(echo $MOODLE_DOCKER_BROWSER_TAG | sed 's/[^0-9].*//g') -lt 4 ]]
    then
        export MOODLE_DOCKER_SELENIUM_SUFFIX="-debug"
    fi

this means that if MOODLE_DOCKER_BROWSER_TAG=latest, the -debug suffix is added. It took me half a day to figure out why I can't reproduce the problem that ci.moodle.org finds locally

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

2 participants