text.getAttributes() can take an extraordinarily long time to return given a sufficiently large text object.
Categories
(Core :: Disability Access APIs, defect, P3)
Tracking
()
People
(Reporter: jdiggs, Unassigned)
References
(Blocks 2 open bugs)
Details
(Keywords: access, perf)
Attachments
(2 files)
Updated•17 years ago
|
Comment 1•17 years ago
|
||
Reporter | ||
Comment 2•17 years ago
|
||
Reporter | ||
Comment 3•17 years ago
|
||
Comment 4•17 years ago
|
||
Comment 5•17 years ago
|
||
Reporter | ||
Comment 6•17 years ago
|
||
Comment 7•17 years ago
|
||
Comment 8•17 years ago
|
||
Comment 9•17 years ago
|
||
Updated•16 years ago
|
Comment 10•16 years ago
|
||
Comment 11•16 years ago
|
||
Comment 12•15 years ago
|
||
Comment 13•14 years ago
|
||
Comment 14•14 years ago
|
||
Comment 15•14 years ago
|
||
Comment 16•14 years ago
|
||
Comment 17•14 years ago
|
||
Comment 18•14 years ago
|
||
Comment 19•4 years ago
|
||
It appears that this Accerciser is no longer a usable application, but I imagine that the original issue would be related to how fast ORCA would take in a very large text page before starting to read it. Am I right?
How do you think it would be best to confirm (or verify) it? Thanks, James!
Comment 20•4 years ago
|
||
Accerciser should still be usable. That said, you could also test this with NVDA by doing the following:
- Load a large document containing only text and
<br>
tags. (The original test case from comment 2 doesn't appear to be available any more, unfortunately.) - Focus the document.
- Press NVDA+control+z to open the NVDA Python console.
- Enter this command:
focus.IAccessibleTextObject.attributes(0)
Earlier comments in this bug suggest that this should have improved as compared to the original state, but it might still be a problem. I can understand why that might be the case; when an Accessible contains a lot of text nodes, we have to scan all the text nodes to figure out where the attributes change. The caching project we're working on (bug 1694563) may improve the responsiveness of these calls, but it might also cause some content process jank during page load.
Comment 21•4 years ago
|
||
(In reply to Joanmarie Diggs from comment #0)
In addition, considering real-world cases, given a line with a single bold
word in the middle, there are three segments of text for which attributes
must be obtained rather than one. Add another bold word somewhere else in
the middle of that line, and now we're up to five segments. If
getAttributes() took only a quarter of a second to return, that's still over
a full second to get the text attributes for one line of text with a couple
of bold words. :-(
This issue would only occur where there are a lot of consecutive text nodes with the exact same formatting. As soon as there is a node with different formatting (e.g. bold), we can stop comparing nodes for formatting equality. A further mitigating factor here is that in most real world cases of formatted text (including bold), the text would usually be split into paragraphs or the like as well. Paragraphs means separate Accessibles, which means attributes won't have to scan text outside the paragraph in question.
Comment 22•4 years ago
|
||
Wouldn't know where to get a "proper" test page from, but fortunately, there's another attachment in comment 14.
On the other hand, it does not seem to cover the same case that you've described because it does not contain <br> tags.
The page is about a 3MB XML document that would take forever to scroll to the bottom.
It contains a lot of objects, like this:
<objects>
<object id="5776">
<name>"In file /lib/libdbus-1.so.3.5.2"</name>
<total>1</total>
<self>0</self>
</object>
And also lots of nodes:
<nodes>
<node id="1">
<object>2</object>
<siblings>0</siblings>
<children>3</children>
<parent>0</parent>
<total>5910</total>
<self>0</self>
<toplevel>1</toplevel>
</node>
If I perform the steps you wrote in comment 20 for the attachment described above:
- Lunch NVDA and the browser.
- Load the large XML file in the browser.
Notice issue: Upon focus, the NVDA will read the local address in the address bar and then say "loading document" and then but the browser becomes unresponsive for a large amount of time (~15 minutes or more!!!). In the same situation but with Ubuntu and ORCA, the browser remains unresponsive for a smaller amount of time (under 1 min). - Press hotkey NVDA + CTRL + Z.
Notice: NVDA Python Console is being opened. - Paste this command ( focus.IAccessibleTextObject.attributes(0) ) into the console;
Notice: It gives out the following response instantly:
(0, 1, None)
In conclusion, assuming that the original issue was that the NVDA python console took a long time to give out a response, it appears that this issue does not occur with NVDA and Nightly v97.0a1 or ESR v91.3esr.
Questions:
- Is the XML file described above valid to test with?
- Do you think the issue with NVDA taking a long time to load is properly addressed already in another bug? Do you know which one that is?
- Is the console response a correct one?
- How can I test the same case for ORCA (Ubuntu) and/or VoiceOver (MacOS)?
- How do you think this bug should be updated?
Sorry for the wall of text, James. Please help.
Comment 23•4 years ago
|
||
(In reply to Bodea Daniel [:danibodea] from comment #22)
Wouldn't know where to get a "proper" test page from, but fortunately, there's another attachment in comment 14.
On the other hand, it does not seem to cover the same case that you've described because it does not contain <br> tags.
...
- Is the XML file described above valid to test with?
I don't believe that document is a valid test case for this bug as described. It may have been once - we might have changed the way we view XML documents - but even if that were true, it isn't any longer.
- Do you think the issue with NVDA taking a long time to load is properly addressed already in another bug? Do you know which one that is?
There's no exact match, but issues like this will hopefully be addressed by our Cache the World project (bug 1694563). Performance bugs that will probably be improved as a result of that work are tracked as blocked by bug 1737192.
- Is the console response a correct one?
For this document, yes.
- How can I test the same case for ORCA (Ubuntu) and/or VoiceOver (MacOS)?
For Orca, you'd need to use Accerciser. I'm not sure why that wasn't usable for you; I haven't tried it in a while, but it did work for me a couple of years ago. For VoiceOver, I'm not sure.
- How do you think this bug should be updated?
Given comment 21, I've dropped the severity and priority of this bug. If there's any impact on real world usage, I think it'd be extremely rare.
Updated•4 years ago
|
Comment 24•3 years ago
|
||
Based on the last comment, I will retire from this thread.
Description
•