Skip to content

Skip network-backed mounts when enumerating UF2 drives - #107

Open
Tudor (tudorjnu) wants to merge 1 commit into
microsoft:masterfrom
tudorjnu:fix/skip-network-mounts
Open

Skip network-backed mounts when enumerating UF2 drives#107
Tudor (tudorjnu) wants to merge 1 commit into
microsoft:masterfrom
tudorjnu:fix/skip-network-mounts

Conversation

@tudorjnu

Copy link
Copy Markdown

When searching /media, /mnt, and similar paths for UF2-capable drives, os.listdir and os.path.isdir can hang indefinitely on network-backed filesystems (NFS, CIFS, SSHFS, autofs, network FUSE). Parse /proc/self/mountinfo to identify these mount points and skip them during enumeration. Local FUSE filesystems (exFAT, NTFS) are excluded from the skip list since they are not slow.

When searching /media, /mnt, and similar paths for UF2-capable drives,
os.listdir and os.path.isdir can hang indefinitely on network-backed
filesystems (NFS, CIFS, SSHFS, autofs, network FUSE). Parse
/proc/self/mountinfo to identify these mount points and skip them
during enumeration. Local FUSE filesystems (exFAT, NTFS) are excluded
from the skip list since they are not slow.
@tudorjnu

Copy link
Copy Markdown
Author

Tudor (Tudor (@tudorjnu)) please read the following Contributor License Agreement(CLA). If you agree with the CLA, please reply with the following information.

@microsoft-github-policy-service agree [company="{your company}"]

Options:

  • (default - no company specified) I have sole ownership of intellectual property rights to my Submissions and I am not making Submissions in the course of work for my employer.
@microsoft-github-policy-service agree
  • (when company given) I am making Submissions in the course of work for my employer (or my employer has intellectual property rights in my Submissions by contract or applicable law). I have permission from my employer to make Submissions and enter into this Agreement on behalf of my employer. By signing below, the defined term “You” includes me and my employer.
@microsoft-github-policy-service agree company="Microsoft"

Contributor License Agreement

@microsoft-github-policy-service agree

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

Successfully merging this pull request may close these issues.

1 participant