-
-
Notifications
You must be signed in to change notification settings - Fork 109
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
Failed to list readers: The Smart Card Resource Manager is not running #153
Comments
Yeah it is irritating they changed this behavior in Windows. I read through your blog article about this issue and testing workarounds sleeping for a second and rechecking the readers list. I was thinking if the platform is Windows and the The Smart Card Resource Manager is not running exception happens possibly a polling function starts running every second until the exception clears. Not horrible but not great. |
In your case you get the error Microsoft changed Windows to return |
I only get 0x8010001D SCARD_E_NO_SERVICE. I have the latest Windows service pack. Possibly they changed it. Can it be added as an additional exception to look for? Now that I know where the code is I will try and modify it and see if I can patch it to work on my system. |
Can you try the version from https://github.com/LudovicRousseau/pyscard-debug and confirm it fixes the issue? |
Confirming your fix worked. I saw it capture the no service exception and restart the context. I made a pull request here I added more exception handling so I could see the no service exception for debugging in my project #154 |
Problem fixed in 5fd9a76 included in PySCard 2.0.6 |
Your system information
Please describe your issue in as much detail as possible:
Describe what you expected should happen.
Removing the smart card reader and plugging it back in should pickup the readers list change
Describe what did happen.
The app fails to connect to a Yubikey NFC reader after the user unplugs and reconnects the NFC reader. I have seen in previous bugs this problem is related to Windows sub optimal decision to stop the smart card driver when the last NFC reader is removed. The same app works perfectly on Linux. Was hoping there is a way to add a watcher for the The Smart Card Resource Manager is not running event so I can reinitialize the app. The workaround I gave to users was to restart the app when disconnecting the NFC reader and avoid unplugging the NFC reader.
Steps for reproducing this issue:
The text was updated successfully, but these errors were encountered: