Repository: nvaccess/nvda

Issue:
Many errors in log when moving the mouse in Internet explorer
### Steps to reproduce:
* Open IE
* Move the mouse on the page over an edit field (or maybe other form elements) To do this, you can go with virtual cursor on an edit field, e.g. with 'E' letter and then press NVDA+PavNum/ to move the mouse cursor to this edit field.

### Actual behavior:
Many error sounds are heard and many errors can be seen in the log

<details><summary>fragment of log when I am moving the mouse</summary>
<p>

```
WARNING - eventHandler._EventExecuter.next (16:41:44.455) - MainThread (14764):
Could not execute function event_mouseMove defined in NVDAObjects module; kwargs: {'x': 736, 'y': 98}
Traceback (most recent call last):
  File "eventHandler.pyc", line 100, in next
  File "NVDAObjects\__init__.pyc", line 1063, in event_mouseMove
  File "NVDAObjects\IAccessible\MSHTML.pyc", line 427, in makeTextInfo
  File "documentBase.pyc", line 24, in makeTextInfo
  File "NVDAObjects\IAccessible\MSHTML.pyc", line 333, in __init__
TypeError: not all arguments converted during string formatting
ERROR - eventHandler.executeEvent (16:41:44.455) - MainThread (14764):
error executing event: mouseMove on <NVDAObjects.Dynamic_EditableTextWithoutAutoSelectDetectionMSHTMLIAccessible object at 0x07BD5850> with extra args of {'x': 736, 'y': 98}
Traceback (most recent call last):
  File "eventHandler.pyc", line 100, in next
  File "NVDAObjects\__init__.pyc", line 1063, in event_mouseMove
  File "NVDAObjects\IAccessible\MSHTML.pyc", line 427, in makeTextInfo
  File "documentBase.pyc", line 24, in makeTextInfo
  File "NVDAObjects\IAccessible\MSHTML.pyc", line 333, in __init__
TypeError: not all arguments converted during string formatting

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
  File "eventHandler.pyc", line 155, in executeEvent
  File "eventHandler.pyc", line 92, in __init__
  File "eventHandler.pyc", line 107, in next
  File "extensionPoints\util.pyc", line 170, in callWithSupportedKwargs
  File "NVDAObjects\__init__.pyc", line 1063, in event_mouseMove
  File "NVDAObjects\IAccessible\MSHTML.pyc", line 427, in makeTextInfo
  File "documentBase.pyc", line 24, in makeTextInfo
  File "NVDAObjects\IAccessible\MSHTML.pyc", line 333, in __init__
TypeError: not all arguments converted during string formatting
WARNING - eventHandler._EventExecuter.next (16:41:44.539) - MainThread (14764):
Could not execute function event_mouseMove defined in NVDAObjects module; kwargs: {'x': 736, 'y': 100}
Traceback (most recent call last):
  File "eventHandler.pyc", line 100, in next
  File "NVDAObjects\__init__.pyc", line 1063, in event_mouseMove
  File "NVDAObjects\IAccessible\MSHTML.pyc", line 427, in makeTextInfo
  File "documentBase.pyc", line 24, in makeTextInfo
  File "NVDAObjects\IAccessible\MSHTML.pyc", line 333, in __init__
TypeError: not all arguments converted during string formatting
ERROR - eventHandler.executeEvent (16:41:44.539) - MainThread (14764):
error executing event: mouseMove on <NVDAObjects.Dynamic_EditableTextWithoutAutoSelectDetectionMSHTMLIAccessible object at 0x07BD5850> with extra args of {'x': 736, 'y': 100}
Traceback (most recent call last):
  File "eventHandler.pyc", line 100, in next
  File "NVDAObjects\__init__.pyc", line 1063, in event_mouseMove
  File "NVDAObjects\IAccessible\MSHTML.pyc", line 427, in makeTextInfo
  File "documentBase.pyc", line 24, in makeTextInfo
  File "NVDAObjects\IAccessible\MSHTML.pyc", line 333, in __init__
TypeError: not all arguments converted during string formatting

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
  File "eventHandler.pyc", line 155, in executeEvent
  File "eventHandler.pyc", line 92, in __init__
  File "eventHandler.pyc", line 107, in next
  File "extensionPoints\util.pyc", line 170, in callWithSupportedKwargs
  File "NVDAObjects\__init__.pyc", line 1063, in event_mouseMove
  File "NVDAObjects\IAccessible\MSHTML.pyc", line 427, in makeTextInfo
  File "documentBase.pyc", line 24, in makeTextInfo
  File "NVDAObjects\IAccessible\MSHTML.pyc", line 333, in __init__
TypeError: not all arguments converted during string formatting
WARNING - eventHandler._EventExecuter.next (16:41:44.779) - MainThread (14764):
Could not execute function event_mouseMove defined in NVDAObjects module; kwargs: {'x': 736, 'y': 102}
Traceback (most recent call last):
  File "eventHandler.pyc", line 100, in next
  File "NVDAObjects\__init__.pyc", line 1063, in event_mouseMove
  File "NVDAObjects\IAccessible\MSHTML.pyc", line 427, in makeTextInfo
  File "documentBase.pyc", line 24, in makeTextInfo
  File "NVDAObjects\IAccessible\MSHTML.pyc", line 333, in __init__
TypeError: not all arguments converted during string formatting
ERROR - eventHandler.executeEvent (16:41:44.789) - MainThread (14764):
error executing event: mouseMove on <NVDAObjects.Dynamic_EditableTextWithoutAutoSelectDetectionMSHTMLIAccessible object at 0x07BD5850> with extra args of {'x': 736, 'y': 102}
Traceback (most recent call last):
  File "eventHandler.pyc", line 100, in next
  File "NVDAObjects\__init__.pyc", line 1063, in event_mouseMove
  File "NVDAObjects\IAccessible\MSHTML.pyc", line 427, in makeTextInfo
  File "documentBase.pyc", line 24, in makeTextInfo
  File "NVDAObjects\IAccessible\MSHTML.pyc", line 333, in __init__
TypeError: not all arguments converted during string formatting

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
  File "eventHandler.pyc", line 155, in executeEvent
  File "eventHandler.pyc", line 92, in __init__
  File "eventHandler.pyc", line 107, in next
  File "extensionPoints\util.pyc", line 170, in callWithSupportedKwargs
  File "NVDAObjects\__init__.pyc", line 1063, in event_mouseMove
  File "NVDAObjects\IAccessible\MSHTML.pyc", line 427, in makeTextInfo
  File "documentBase.pyc", line 24, in makeTextInfo
  File "NVDAObjects\IAccessible\MSHTML.pyc", line 333, in __init__
TypeError: not all arguments converted during string formatting
WARNING - eventHandler._EventExecuter.next (16:41:44.879) - MainThread (14764):
Could not execute function event_mouseMove defined in NVDAObjects module; kwargs: {'x': 736, 'y': 105}
Traceback (most recent call last):
  File "eventHandler.pyc", line 100, in next
  File "NVDAObjects\__init__.pyc", line 1063, in event_mouseMove
  File "NVDAObjects\IAccessible\MSHTML.pyc", line 427, in makeTextInfo
  File "documentBase.pyc", line 24, in makeTextInfo
  File "NVDAObjects\IAccessible\MSHTML.pyc", line 333, in __init__
TypeError: not all arguments converted during string formatting
ERROR - eventHandler.executeEvent (16:41:44.879) - MainThread (14764):
error executing event: mouseMove on <NVDAObjects.Dynamic_EditableTextWithoutAutoSelectDetectionMSHTMLIAccessible object at 0x07BD5850> with extra args of {'x': 736, 'y': 105}
Traceback (most recent call last):
  File "eventHandler.pyc", line 100, in next
  File "NVDAObjects\__init__.pyc", line 1063, in event_mouseMove
  File "NVDAObjects\IAccessible\MSHTML.pyc", line 427, in makeTextInfo
  File "documentBase.pyc", line 24, in makeTextInfo
  File "NVDAObjects\IAccessible\MSHTML.pyc", line 333, in __init__
TypeError: not all arguments converted during string formatting

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
  File "eventHandler.pyc", line 155, in executeEvent
  File "eventHandler.pyc", line 92, in __init__
  File "eventHandler.pyc", line 107, in next
  File "extensionPoints\util.pyc", line 170, in callWithSupportedKwargs
  File "NVDAObjects\__init__.pyc", line 1063, in event_mouseMove
  File "NVDAObjects\IAccessible\MSHTML.pyc", line 427, in makeTextInfo
  File "documentBase.pyc", line 24, in makeTextInfo
  File "NVDAObjects\IAccessible\MSHTML.pyc", line 333, in __init__
TypeError: not all arguments converted during string formatting
IO - inputCore.executeGesture (16:41:46.821) - winInputHook (4484):
Input: kb(desktop):NVDA+f1
```

</p>
</details>



### Expected behavior:
No error

### System configuration
#### NVDA installed/portable/running from source:
Installed

#### NVDA version:
NVDA 2019.3beta3

#### Windows version:
Win 10

#### Name and version of other software in use when reproducing the issue:
IE 11

#### Other information about your system:

### Other questions
#### Does the issue still occur after restarting your PC?
Yes

#### Have you tried any other versions of NVDA? If so, please report their behaviors.
NVDA 2019.2.1 portable: no error

### Note
This issue was originally reported in a French mailing list in IE, Windows Live mail and also sometimes in Edge. I have only checked in IE; I cannot guarantee that problems in WLM and Ege are the same.



Discussion:

Resolving patch:
diff --git a/source/NVDAObjects/IAccessible/MSHTML.py b/source/NVDAObjects/IAccessible/MSHTML.py
--- a/source/NVDAObjects/IAccessible/MSHTML.py
+++ b/source/NVDAObjects/IAccessible/MSHTML.py
@@ -330,7 +330,7 @@ def __init__(self,obj,position,_rangeObj=None):
 			else:
 				raise TypeError("Bookmark was for %s type, not for %s type"%(position.infoClass.__name__,self.__class__.__name__))
 		else:
-			raise NotImplementedError("position: %s"%position)
+			raise NotImplementedError("position: %s" % (position,))
 
 	def expand(self,unit):
 		if unit==textInfos.UNIT_PARAGRAPH:


Test patch: