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

Stackoverflow in getNodeHierarchy #2123

Open
3 of 8 tasks
tombrunet opened this issue Dec 10, 2024 · 3 comments · May be fixed by #2164 or #2166
Open
3 of 8 tasks

Stackoverflow in getNodeHierarchy #2123

tombrunet opened this issue Dec 10, 2024 · 3 comments · May be fixed by #2164 or #2166
Assignees
Labels
Bug Something isn't working engine Issues in the accessibility-checker-engine component Ready for QA T64

Comments

@tombrunet
Copy link
Member

tombrunet commented Dec 10, 2024

Describe the bug
Unable to scan https://www.camparigroup.com/it due to stackoverflow in getNodeHierarchy

To Reproduce
Steps to reproduce the behavior:

  1. Go to https://www.camparigroup.com/it
  2. Scan the page
  3. Check the console, and see:
Uncaught RangeError: Maximum call stack size exceeded
    at t.getAriaOwnedBy (VM617 ace.js:2:58469)
    at t.getNodeHierarchy (VM617 ace.js:2:59503)
    at t.getNodeHierarchy (VM617 ace.js:2:59627)
    at t.getNodeHierarchy (VM617 ace.js:2:59627)
    at t.getNodeHierarchy (VM617 ace.js:2:59627)

This maps to ARIAMapper somewhere around lines 155-166.

Expected behavior
Shouldn't trigger since getNodeHierarchy should be using cached values in the parents and should only have to go up one level - not multiple

Desktop (please complete the following information):

  • Chrome

Additional context
Add any other context about the problem here.

Definition of Done

  • Design artifacts reviewed
  • Work item implemented
  • Automated test case created (when applicable)
  • Unit test completed
  • Run Checker (when applicable)
  • Manual and Screen Reader Testing (when applicable)
  • Video recording of user experience walkthrough (if impact to UX)
  • PR created
@tombrunet tombrunet added Bug Something isn't working engine Issues in the accessibility-checker-engine component labels Dec 10, 2024
@shunguoy
Copy link
Contributor

shunguoy commented Dec 10, 2024

The page uses 8 'aria-owns', some of them with the same id and point to the same node. so the CacheUtil.setCache(owned, "aria-owned", owner) may override "owned - owner" relation that was considered as one-on-one. Not sure if this can cause an infinite loop.

<div id="mm-5" class="mm-panel mm-hidden mm-panel_has-navbar" aria-hidden="true"><a class="mm-btn mm-btn_prev mm-navbar__btn" href="#mm-1" aria-owns="mm-1" aria-haspopup="true">.....
<div id="mm-4" class="mm-panel mm-hidden mm-panel_has-navbar" aria-hidden="true"><a class="mm-btn mm-btn_prev mm-navbar__btn" href="#mm-1" aria-owns="mm-1" aria-haspopup="true">......

@tombrunet
Copy link
Member Author

Looks like related to the submenus pointing back to the top menu, so you get mm-2 > mm-1 > mm-2 > mm-1, and so forth.

@philljenkins
Copy link
Contributor

philljenkins commented Jan 30, 2025

Tested PRs using

  1. https://www.camparigroup.com/it
  2. aria_own_circular.html

using artifacts from

  1. PR master 3.x https://github.com/IBMa/equal-access/actions/runs/12943018338
  2. PR main 4.x https://github.com/IBMa/equal-access/actions/runs/12953615990

since no changes to rules, mapping, or help there was no additional verification of PR

Correctly does not trigger na getNodeHierarchy error in Console

Image

Correctly reports the issue on aria_own_circular.html

Image

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Bug Something isn't working engine Issues in the accessibility-checker-engine component Ready for QA T64
Projects
None yet
3 participants