-
Notifications
You must be signed in to change notification settings - Fork 48
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
getVolumes hangs when drive is no longer available #155
Comments
Thanks for reporting @see24. I made a change to the commands on Windows that scan for drives (see link below). My hope is that this will skip drives that do not respond within 3 seconds and then move on to other drives. I don't have any network drives on Windows to fully test this out so could you try it and let me know? To install the development version of shinyFiles please use the command below:
f875ad1#diff-03e4b0fc41a86a656bef22b0ca136edf24dc52190ba342aafd7eca8ede337e30R82-R86 |
While connected to the VPN I got this warning message: |
Thanks for testing this out! I made a change that will (1) hopefully avoid the warning being printed and (2) fail faster if VPN is not on. See commit linked below. Can you try again? Also, feel free to make edits to |
Minor update. Use the code below to install the latest version.
https://github.com/thomasp85/shinyFiles/blob/master/R/aaa.R#L82-L86 |
@see24 Can you try this out? Use the code below to install the latest version.
https://github.com/thomasp85/shinyFiles/blob/master/R/aaa.R#L82-L86 |
Works well now! The first time connecting after disconnecting from VPN it takes a little while for the file selector to load but works well and it is not too long. |
Thanks @see24 ! |
This is a very specific issue that might not come up for many people but it was really annoying for me so thought I would put it out there.
getVolumes was working fine in my app and then the app stopped working completely which I eventually traced to
getVolumes()()
hanging for a long time. I eventually figured out that this was happening because I had disconnected from my VPN to connect to my work network. This meant that network drives that were mapped when I logged in to the VPN and still to show up in the file explorer(but they never load and hang in the windows explorer too) were being looked for by getVolumes and that is what made it hang.I added
R.utils::withTimeout
around the getVolumes call so that I don't do this to myself again, but wondering if it would make sense to add a timeout with in getVolumes?The text was updated successfully, but these errors were encountered: