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

hwPortUtils.listComPorts: Querying PortName can fail #6015

Closed
jcsteh opened this issue May 30, 2016 · 7 comments
Closed

hwPortUtils.listComPorts: Querying PortName can fail #6015

jcsteh opened this issue May 30, 2016 · 7 comments
Assignees
Milestone

Comments

@jcsteh
Copy link
Contributor

jcsteh commented May 30, 2016

Originally reported by @mohdshara in this nvda-devel thread.

It seems that some com ports don't have a PortName registry value:

ERROR - unhandled exception (15:22:32):
Traceback (most recent call last):
  File "gui\settingsDialogs.pyo", line 1537, in onDisplayNameChanged
  File "gui\settingsDialogs.pyo", line 1544, in updatePossiblePorts
  File "brailleDisplayDrivers\baum.pyo", line 117, in getPossiblePorts
  File "hwPortUtils.pyo", line 192, in listComPorts
WindowsError: [Error 2] The system cannot find the file specified

Unless I'm missing something, this is broken, but clearly, it can happen. I guess we should just catch the error and skip the port.

@jcsteh jcsteh self-assigned this May 30, 2016
jcsteh added a commit that referenced this issue May 30, 2016
…ch made some braille display drivers unusable.

hwPortUtils.listComPorts: In some rare cases, the PortName registry value doesn't exist. Just skip the port if this occurs.
Fixes #6015.
@nvaccessAuto
Copy link

Incubated in 73ee6b2.

@mohdshara
Copy link

Wonderful! thank you very much for looking into it and for fixing the issue. confirmed, I can now connect through USP and bluetooth.

@mohdshara
Copy link

Hi. It may be worth noting here, that this happened to me on 3 different laptops. They are all made by Linovo and all have windows 10 64 bit. of course, this commit fixes the issues on all of them. what I am trying to say is that there maybe a pattern here.

@jcsteh
Copy link
Contributor Author

jcsteh commented May 31, 2016

That would suggest Lenovo are installing something that creates this issue. It'd be interesting to see a log file at level debugWarning covering selecting a Baum display with this new build on one of those computers. The build logs some info when it encounters this issue. There's nothing we can do about it, but seeing the log might give me some idea of what this actually is.

@jcsteh jcsteh added this to the 2016.3 milestone May 31, 2016
@mohdshara
Copy link

attached are the log files with a usp connection and another with a bluetooth connection.

nvda-log-bluetooth-lenovo.txt
nvda-log-usb.txt
|

@jcsteh
Copy link
Contributor Author

jcsteh commented May 31, 2016

Looks like the problematic port is a modem (hardware id: USB\Vid_0bdb&Pid_193e&Cdc_Modem&Mi_03), so it's not important. That's good.

However, I did notice you're connecting via Bluetooth by choosing a specific com port, rather than selecting automatic 'as the port and letting NVDA detect. Is automatic not working for you with Bluetooth?

@mohdshara
Copy link

Hi Jamie.

I was manually selecting a port because that was what Baum suggested. however, I have just tried, and I found out that automatic will now work too.

Thanks for your help and for fixing the issue.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants