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

ia2TextMozilla: exception: AttributeError: 'NoneType' object has no attribute 'obj' #5454

Closed
nvaccessAuto opened this issue Nov 2, 2015 · 7 comments · Fixed by #11426
Closed
Labels
bug p4 https://github.com/nvaccess/nvda/blob/master/projectDocs/issues/triage.md#priority
Milestone

Comments

@nvaccessAuto
Copy link

Reported by parham on 2015-11-02 17:13
When using the Telegram web application at http://web.telegram.org, I get the error sound. I'm using NVDA version master-11546,170b139. Below are the steps to reproduce:

  1. Login to Telegram.
  2. Use the search or recent conversations to find someone to chat with.
  3. Focus on the edit box, just above the "Send" button, and type something, then press enter.
  4. You will hear the error sound.

The log is pasted below:

ERROR - scriptHandler.executeScript (20:38:17):
error executing script: <bound method Dynamic_EditableTextWithAutoSelectDetectionEditorMozillaIAccessible.script_caret_newLine of <NVDAObjects.Dynamic_EditableTextWithAutoSelectDetectionEditorMozillaIAccessible object at 0x02ABF190>> with gesture u'enter'
Traceback (most recent call last):
  File "scriptHandler.pyc", line 186, in executeScript
  File "editableText.pyc", line 128, in script_caret_newLine
  File "speech.pyc", line 673, in speakTextInfo
  File "NVDAObjects\IAccessible\ia2TextMozilla.pyc", line 291, in getTextWithFields
  File "NVDAObjects\IAccessible\ia2TextMozilla.pyc", line 240, in _getText
AttributeError: 'NoneType' object has no attribute 'obj'
DEBUGWARNING - NVDAObjects.IAccessible.Dynamic_EditableTextWithAutoSelectDetectionEditorMozillaIAccessible._get_IA2Attributes (20:38:17):
IAccessibleObject.attributes COMError (-2147220995, 'Object is not connected to server', (None, None, None, 0, None))
DEBUGWARNING - NVDAObjects.IAccessible.IA2TextTextInfo._getCaretOffset (20:38:17):
IAccessibleText::caretOffset failed
Traceback (most recent call last):
  File "NVDAObjects\IAccessible\__init__.pyc", line 151, in _getCaretOffset
COMError: (-2147220995, 'Object is not connected to server', (None, None, None, 0, None))
@nvaccessAuto
Copy link
Author

Comment 1 by jteh on 2015-11-05 01:20
Does this actually have any noticeable effect aside from the error sound and the logged exception?

@nvaccessAuto
Copy link
Author

Comment 2 by parham (in reply to comment 1) on 2015-11-05 15:56
Replying to jteh:

Does this actually have any noticeable effect aside from the error sound and the logged exception?

Not knowing what is actually supposed to happen, I'm not quite sure. However, NVDA doesn't lose focus or anything, if that's what you mean.

The thing is, until the very latest revisions, NVDA didn't report this field as "Section editable", but now it does. Also, the editable section already contains a placeholder when you don't have anything written in it.

@ehollig
Copy link
Collaborator

ehollig commented Jul 13, 2017

It sounds from the comments that NVDA doesn't lose focus and there is no noticeable effect aside from the error sound. This problem probably does not exist anymore. I would suggest a close, unless the author continues to have issues with this.

@LeonarddeR
Copy link
Collaborator

LeonarddeR commented Jul 13, 2017

It is quite likely that Telegram has changed since the initial report, but I've seen those "AttributeError: 'NoneType' object has no attribute 'obj'" messages myself as well. I wonder whether exception handling should be improved at some point.

@jcsteh jcsteh added the p4 https://github.com/nvaccess/nvda/blob/master/projectDocs/issues/triage.md#priority label Jul 14, 2017
@jcsteh
Copy link
Contributor

jcsteh commented Jul 14, 2017

I think this occurs when an editable text control dies just before (or during) NVDA's attempt to query information from it. P3 to investigate and hopefully find a way to handle these exceptions gracefully. Not p2 because we haven't found a case where it actually breaks functionality.

@jcsteh jcsteh changed the title Error While Using the Telegram Web Application ia2TextMozilla: exception: AttributeError: 'NoneType' object has no attribute 'obj' Jul 14, 2017
@Adriani90
Copy link
Collaborator

This gradually improved after #8479 has been merged. Has anybody seen this error recently still?

@jcsteh
Copy link
Contributor

jcsteh commented May 31, 2020 via email

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