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

4.7.3 version is not running #816

Closed
1 task done
anagritsay opened this issue Sep 6, 2023 · 8 comments
Closed
1 task done

4.7.3 version is not running #816

anagritsay opened this issue Sep 6, 2023 · 8 comments

Comments

@anagritsay
Copy link

Product

cli

Product Version

4.7.3

Latest Version

  • I have tested the issue with the latest version of the product

Issue Description

Hello, I installed the last version of axe-core/cli 4.7.3. Instead of the last version, it is running the version 4.7.2, which cause the error, related with the chrome driver.

@Zidious
Copy link
Contributor

Zidious commented Sep 6, 2023

Hey @anagritsay,

Would you be able to provide the error message / stacktrace?

@anagritsay
Copy link
Author

anagritsay commented Sep 6, 2023

image

As I understood this issue was solved in the version 4.7.3 which is not running

@Zidious
Copy link
Contributor

Zidious commented Sep 6, 2023

This was recently fixed in #796 we haven't published a stable version just yet. If install the @next (npm install @axe-core/cli@next -g) version that should resolve your issues.

@anagritsay
Copy link
Author

anagritsay commented Sep 6, 2023

Unfortunately, even after npm install @axe-core/cli@next -g, it is still running 4.7.2 version

When are you planning to publish a stable version?

@straker
Copy link
Contributor

straker commented Sep 6, 2023

A newer version of the cli won't necessarily fix the chromedriver issue, but will help push it to the next version. A better solve can be found in #680 wherein we provide a new error message about how to handle chromedriver version mismatches. You'll need to install chromedriver to the same location as the cli was installed (which is typically globally). Since your chrome version is listed as 115, you'll want that same version of chromedriver.

npm i -g chromedriver@115

After that you can use the --chromedriver-path option to pass the path to chromedriver

axe --chromedriver-path $(npm root -g)/chromedriver/bin/chromedriver <url...>

That should fix the issue and allow cli to run again.

@anagritsay
Copy link
Author

Thank you for your answer.

I have set up the chromedriver@115 version
Regarding the --chromedriver-path <url...> - can be anywhere? Or in the specific folder?

Seems that now, using @axe-core/cli@next solved the problem.

@straker
Copy link
Contributor

straker commented Sep 6, 2023

Glad the problem is solved.

--chromedriver-path $(npm root -g)/chromedriver/bin/chromedriver

Technically the chromedriver path can be anywhere, you just need to supply the path to it.

@padmavemulapati
Copy link

Verified with the latest version of @axe-core/cli_4.7.4-62fd241.0, chromedriver when ever version compatibility error showing, we can have a solution uisng--chromedriver-path` option.

Steps to validate:

  1. To get a updated chromedriver version at the global location
    npm install chromedriver --update -g

  2. To Find out where chromedriver is we can use a command at the terminal in MAC - which chromedriver and in windows - Where chromedriver

    Which gives you something like this
    /usr/local/bin/chromedriver From a mac

  3. Run axe cli with the following flag. Based on above step
    Flag: --chromedriver-path /usr/local/bin/chromedriver

Example:

axe  --chromedriver-path /usr/local/bin/chromedriver  https://google.com

Getting more comfortable

axe --chromedriver-path $(npm root -g)/chromedriver/bin/chromedriver http://google.com

We can see the output successfully, even we have non-compatible version saved in our machine and trying to run axe-cli . This above process will update the compatibility version of chromdriver and pick the path from where the compatible version of chromedriver located and working as expected.

Output:

axe --chromedriver-path $(npm root -g)/chromedriver/bin/chromedriver http://google.com
Running axe-core 4.8.2 in chrome-headless

Testing http://google.com ... please wait, this may take a minute.

  Violation of "aria-allowed-role" with 1 occurrences!
    Ensures role attribute has an appropriate value for the element. Correct invalid elements at:
     - #APjFqb
    For details, see: https://dequeuniversity.com/rules/axe/4.8/aria-allowed-role

  Violation of "aria-valid-attr-value" with 2 occurrences!
    Ensures all ARIA attributes have valid values. Correct invalid elements at:
     - #APjFqb
     - .ayzqOc
    For details, see: https://dequeuniversity.com/rules/axe/4.8/aria-valid-attr-value

  Violation of "color-contrast" with 8 occurrences!
    Ensures the contrast between foreground and background colors meets WCAG 2 AA minimum contrast ratio thresholds. Correct invalid elements at:
     - .uU7dJb
     - a[data-usg="AOvVaw33zjaJZ_ogw8iPEm4kPGYh"]
     - a[data-usg="AOvVaw3Oj62V1xNd5oAI6Vxou5Lx"]
     - a[data-usg="AOvVaw2SJ4zwRVXKyZr53qG9dm4K"]
     - .pHiOh:nth-child(4)
     - a[data-usg="AOvVaw2y-DJehqHRQuhUzwsARmol"]
     - a[data-usg="AOvVaw25sheD5OGrPUyBw_FdCQOy"]
     - .ayzqOc
    For details, see: https://dequeuniversity.com/rules/axe/4.8/color-contrast

  Violation of "region" with 8 occurrences!
    Ensures all page content is contained by landmarks. Correct invalid elements at:
     - .gb_yd > div:nth-child(1)
     - .gb_za
     - .lnXdpd
     - #SIvCob
     - .uU7dJb
     - .AghGtd
     - a[data-usg="AOvVaw2y-DJehqHRQuhUzwsARmol"]
     - a[data-usg="AOvVaw25sheD5OGrPUyBw_FdCQOy"]
    For details, see: https://dequeuniversity.com/rules/axe/4.8/region

19 Accessibility issues detected.
Testing complete of 1 pages

Please note that only 20% to 50% of all accessibility issues can automatically be detected. 
Manual testing is always required. For more information see:
https://dequeuniversity.com/curriculum/courses/testingmethods

Screenshot:

image

Environment:

Label Value
Product axe-core-npm/react
Version 4.7.4-62fd241.0
OS-Details _MAC- Intel Core i7 - 11.6.8 & Windows11 _
BrowserDetails Chrome Version 117.0.5938.88 (Official Build) (64-bit) & Firefox 117.0

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

4 participants