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

Elements list freezes on huge pages or with slower browse mode implementations #7197

Closed
LeonarddeR opened this issue May 23, 2017 · 17 comments
Closed
Labels
bug/freeze close/worksforme p3 https://github.com/nvaccess/nvda/blob/master/projectDocs/issues/triage.md#priority

Comments

@LeonarddeR
Copy link
Collaborator

Steps to reproduce:

  1. Start MS Edge
  2. Go to babbage.com
  3. Go to the elements list with nvda+f7
  4. Press alt+h to focus headings

Expected behavior:

Headings are shown instandly

Actual behavior:

NVDA freezes entirely

Suggested fix

Use watchdog.cancellableExecute for list refreshing, or something similar to this? At least, NVDA should be able to cancel a request for elements.

System configuration:

NVDA version: next-14051,e102a7e0

Windows version: Windows 10 version 1703 (build 15063.296)

Other questions:

Does the issue still occur after restarting your PC?
yes

Have you tried any other versions of NVDA?
Yes, NVDA from source with my i588 branch (#6131)

@jcsteh jcsteh added the z app/edge (archived) use app/edge/anaheim label May 23, 2017
@jcsteh
Copy link
Contributor

jcsteh commented May 23, 2017

There's no way to "cancel" UIA calls. cancellableExecute runs the call in a background thread and simply abandons the thread if it takes too long (since you can't safely kill a thread). Aside from leaving pointless stuff running consuming resources, the Edge process would still be busy handling requests from the background thread, so it wouldn't serve any purpose. Setting timeouts for UIA calls (#6533) might help with this.

One question is whether it's a single UIA call that is taking a long time or whether it's multiple calls. The latter is more likely. If so, UIA timeouts alone won't help; we'd need to explicitly check the watchdog after each request, which is going to be rather ugly. I wonder if we can do something with a profile or trace function to avoid the need to manually check this.

@jcsteh jcsteh added bug/freeze p3 https://github.com/nvaccess/nvda/blob/master/projectDocs/issues/triage.md#priority labels May 23, 2017
@bhavyashah
Copy link

Is this ticket specific to Edge, or can its scope be expanded to include other web browsers (particularly Firefox)? On babbage.com, since there are a fairly low number of headings, pressing Alt+H took only about 3-5 seconds using Firefox 54.0.1 and NVDA 2017.2, which is a relatively minor lag. However, when on a lengthy article in Wikipedia, Alt+H, Alt+K and Alt+D results in major freezes. Has this issue already been covered by an existing ticket, or should I file a new one?

@LeonarddeR
Copy link
Collaborator Author

@bhavyashah: I think your issue fits into the scope of this ticket (i.e. it is not Edge specific). I belief we should aim onto a method that will allow the elements list to break out of a frozen quicknav iterator. However, as @jcsteh mentioned, this will be hard for UIA as UIA calls can't be cancelled.
@jcsteh commented on 24 mei 2017 00:58 CEST:

I wonder if we can do something with a profile or trace function to avoid the need to manually check this.

Could you elaborate a bit more on this?

@jcsteh
Copy link
Contributor

jcsteh commented Jul 27, 2017

I haven't really put much thought into it. The problem is that even if we set UIA timeouts, they only apply to a single call, but perhaps we're actually making multiple calls and the single calls never exceed the timeout and thus don't throw an exception. We really don't want to have to manually check the watchdog after every single UIA call. A profile or trace function runs for every call, so you could set one up with a context manager or something and have it check the watchdog after each call. That might be too expensive and ugly, though.

@bhavyashah
Copy link

bhavyashah commented Jul 27, 2017 via email

@LeonarddeR
Copy link
Collaborator Author

I agree that we shouldn't check the watchdog for every single call, but how about ten calls, for example? Or, even better, allow setting an interval?

@jcsteh
Copy link
Contributor

jcsteh commented Jul 27, 2017 via email

@bhavyashah
Copy link

bhavyashah commented Jul 27, 2017 via email

@bhavyashah
Copy link

@LeonarddeR Do you have any thoughts on @jcsteh's #7197 (comment)? Considering this ticket has P2, we might want to try to - (1) revive technical discussion about solving this issue or (2) ascertain that the implementation cost is too significant and consequently deprioritize this ticket. Just saying...

@Adriani90
Copy link
Collaborator

This is not occuring in Edge Chromium 81. Closing as works for me since Edge Chromium will be distributed to most users via Windows 10 20 H1 update.

@feerrenrut feerrenrut added the z app/edge/spartan (archived) MS browser, replaced in 2019 by Anaheim. NVDA access via UIA. label Apr 30, 2020
@gregjozk
Copy link
Contributor

Hello,

@Adriani90 and others, I think, that unresolved issues/tickets have been closing too agressively. Certainly, this issue has not been solved yet. here are some browsers like firefox and many on chromeum platform and also IE. compare a huge webpage on all that browsers and try to change, which element would be listed in elements list. when changing it there is still a big delay.
it is just my opinion about closing issues.

@Adriani90
Copy link
Collaborator

Adriani90 commented May 26, 2020 via email

@gregjozk
Copy link
Contributor

Hello,

try some books on wikibooks.org e.g. books about python or about latex, especially print versions. there you would see, why I thought, that this issue was closed too fast.
Oh, I use last published alpha of NVDA and FF 76.0.1.
Again, delay of 5 to 10 seconds is understandable, but when delay is huge, user wants to cancel operation and manually skip to chosen heading/link etc.
excuse me, if issue does not cover this example.
if it is acceptable, one more example from word or other office products, where browse mode is also possible. there are possibilities like editor's revisions, spelling errors etc.

best regards

@Adriani90
Copy link
Collaborator

Ups sorry yes this seems not browser specific. I am reopening.

@bhavyashah
Copy link

I do not presently have the technical knowhow to comment on the feasibility or implementation of this suggestion. However, I was wondering if it might be wiser to gradually populate the Elements List dialog when it is first opened, when a different element type is selected, or when a search string is entered in the Filter by dialog. This would be similar to how Start Menu and File Explorer searches work, wherein preliminary results show up almost instantly and the next few seconds are spent on completing the search. My understanding is that currently, NVDA goes quiet and forces the user to wait until the entire list has been populated, making those few seconds of lag prominently felt. This may reduce the load on NVDA at any single point in time thereby reducing the likelihood of freezes, give the user something to get started with, and make the experience smoother overall and in sync with the way searches work elsewhere in Windows. In large documents with hundreds of instances of a certain element type, the Elements List dialog is quite laggy making it very inefficient to use. Personally, I would be very grateful if the performance of the Elements List dialog were a subject that received more attention.

@seanbudd seanbudd removed z app/edge (archived) use app/edge/anaheim z app/edge/spartan (archived) MS browser, replaced in 2019 by Anaheim. NVDA access via UIA. labels Apr 11, 2023
seanbudd added a commit that referenced this issue Jun 20, 2023
… response (#10308)

Related to #7197, but does not solve it.

Summary of the issue:
In browse mode, in the Elements List dialog, speed typing a filter string leads to slow responsiveness from the UI and NVDA itself.

Description of how this pull request fixes the issue:
lightly delay the refresh of the elements list by 300 ms. (same technique as PR #10307)

---------

Co-authored-by: Leonard de Ruijter <leonardder@users.noreply.github.com>
Co-authored-by: Sean Budd <sean@nvaccess.org>
@Adriani90
Copy link
Collaborator

Does anyone have this issue still with the last NVDA alpha version and the newest updates of different browsers? #14888 might have also brought some benefits for this issue if I am not wrong.

@Adriani90
Copy link
Collaborator

I cannot reproduce this issue with NVDA 2024.1 Beta and last Firefox or Chromium browser versions. I am closing as works for me also because we don't have any updates from other users since almost 3 years. If this is still occuring, please comment and we can reopen.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug/freeze close/worksforme p3 https://github.com/nvaccess/nvda/blob/master/projectDocs/issues/triage.md#priority
Projects
None yet
Development

No branches or pull requests

7 participants