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

ui.browseableMessage(): Fix an Unicode problem when NVDA is installed in a path containing a non-ASCII character #7474

merged 1 commit into from Nov 23, 2017


Copy link

@aaclause aaclause commented Aug 4, 2017

If NVDA is installed in a path containing a non-ASCII character (eg: éè), ui.browseableMessage() fails.

>>> import ui
>>> ui.browseableMessage('test')
Traceback (most recent call last):
  File "<console>", line 1, in <module>
  File "ui.pyo", line 49, in browseableMessage
UnicodeDecodeError: 'ascii' codec can't decode byte 0xe9 in position 7: ordinal not in range(128)

…ed in a path containing a non-ASCII character.
Copy link

@leonardder leonardder commented Aug 4, 2017

Looks great and sensible, only one line of changed code, so I'd suggest merging this directly into master

Copy link

@derekriemer derekriemer commented Aug 11, 2017

This needs code review and should be relatively easy.

@leonardder leonardder requested a review from feerrenrut Oct 12, 2017
Copy link

@leonardder leonardder left a comment

This is a one liner

Copy link

@feerrenrut feerrenrut commented Oct 16, 2017

Overall this looks good. Could you please describe the testing that has been done. In particular I want to see that the following has been tested:

Test the following with and without non-ASCIIcharacters:

  • Standard installation
  • Portable installation
  • Running from launcher (inside a folder with / without non-ASCII characters)

Copy link
Contributor Author

@aaclause aaclause commented Nov 1, 2017

I've just tested. I generated a build with this change.
Everything works for me! :)

1/ I have moved the launcher archive in a folder with non-ASCII characters (C:\André).
2/ I have run the launcher archive and I launched the Python Console.
I typed this input: import ui; ui.browseableMessage(u'éèçtest').
3/ I created a portable installation (in C:\André\çéèâ).
4/ I started the portable copy and I reiterated with the Python Console and with an add-on.

Copy link

@feerrenrut feerrenrut commented Nov 1, 2017

Great, I'll incubate this change.

feerrenrut added a commit that referenced this issue Nov 1, 2017
Merge remote-tracking branch 'origin/pr/7474' into next
@michaelDCurran michaelDCurran merged commit 5b475a8 into nvaccess:master Nov 23, 2017
@nvaccessAuto nvaccessAuto added this to the 2017.4 milestone Nov 23, 2017
@aaclause aaclause deleted the ui_browseableMessage branch Dec 5, 2017
@feerrenrut feerrenrut removed their request for review Feb 6, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
None yet

Successfully merging this pull request may close these issues.

None yet

6 participants