pylance-release
pylance-release copied to clipboard
Accessibility: HTML entities are not escaped when pressing control+shift+space
Does this issue occur when all extensions are disabled?: Yes
- VS Code Version: 1.69.2
- OS Version: Windows 10 21H2 (x64) build 19044.1766
Steps to Reproduce:
- Open a Python file.
- Type "dict()" without the quotes.
- Start Narrator, NVDA, or another Windows screen reader.
- press control+shift+space while inside the ().
- I hear:
__map: SupportsKeysAndGetItem[_KT@dict, _VT@dict], dict() -> new empty dictionary dict(mapping) -> new dictionary initialized from a mapping object's\ (key, value) pairs\ dict(iterable) -> new dictionary initialized as if via:\ d = {} for k, v in iterable:\ d\[k\] = v\ dict(\*\*kwargs) -> new dictionary initialized with the name=value pairs\ in the keyword argument list. For example: dict(one=1, two=2), hint
This is extremely hard to read to say the least, with all the HTML entities being spoken. It would be great if these could be escaped, and turned into standard symbols.
Thanks for creating this issue! It looks like you may be using an old version of VS Code, the latest stable release is 1.69.2. Please try upgrading to the latest version and checking whether this issue remains.
Happy Coding!
@luabud this issue is about python parameter hints. Are you escaping those? Or is this wrongly read by nvda?
great question! I don't think we're doing anything different from what TypeScript does with type hints, but I could be wrong. @bschnurr -- do you know if we're escaping the variable type hints?
Friendly reminder to unassign issues before transferring otherwise it breaks our triaging flow.
I'm not escaping anything in the hint, but the hint should just be the type. Maybe its reading the onHover text?
hmm. NVDA seems to handle it fine.
Just tested again, and it doesn't on my side. Would an audio recording possibly help?
dict(|)
cursor at |
correct?
video would help
I wasn't able to reproduce it either, unfortunately. I'm wondering if there may be an extension other than Pylance that is providing these parameter hints. Perhaps it may help if all extensions but the Pylance and Python ones are disabled, and seeing if the problem still occurs?
Disabling all extensions that aren't Python fixed it. Weird, and going to be a pain to trace, but not related to Pylance, so closing it.