Consider a local drive on a Windows machine that is shared over a network.
The drive is mapped to D:\
locally and it is shared by the local machine over the network with the name data
. Therefore, the network path for this drive would be \\computer-name\data
.
Is it possible to determine the name of the shared network path programatically in Python given the drive letter D
from the host machine?
Expected behavior would be:
drive_letter = "D"
get_network_path(drive_letter)
>>> \\computer-name\data
The only additional constraint is that this should work without admin permissions.