Cannot open a file from WSL2 share with Notepad++



  • Hi,

    I have a WSL 2 drive mounted in Windows 10:

    b844c038-9c2b-4645-a022-8077e3476963-image.png

    Te problem is that if i try to open any file with Npp then i get the following error:
    0af3723c-2ec9-450b-908b-3ae8447bc101-image.png

    The same file opens just fine with other editors. Is there a way to make this work with Npp?

    Regards



  • @Raigo-Tingas ,

    I don’t know the specific WSL2 technology for network drives.

    However, I use Notepad++ on a daily basis to edit files throughout my network at work, including mounts from other windows machines and mounts from Linux samba servers. I usually use the full UNC path (\machine\path\to\file.txt) rather than mapping to a drive letter (like your Z:), but I can also use a mapped network drive without difficulty.

    As far as I know, if Windows can see then file, then Notepad++ should be able to see the file.



  • @PeterJones

    I also have no problems with regular network drives. This only seems to occur with WSL2 mounts.

    A colleague of mine is having the exact same problem on his setup so its not just me. Strange thing is that this only affects Npp, regular Notepad and all other editors are able to open and edit the files just fine.



  • Note that the message refers to Folder and not File. I tried to lookup it up in the code. Didn’t reverse engineer the entire mess but it seems to be related to snapshot and/or backups.

    Try disable them both and see if the file opens.
    If so try to find the which setting exactly cause the failure.



  • same problem - notepad don’t found wsl disc and files. windows notepad open wsl files without any problems

    On screen explorer and npp file > open.
    e8c616a3-6b7d-4b3d-9cfa-884b3ce9272e-изображение.png



  • @WinterSilence
    @Raigo-Tingas

    Works fine for me with Notepad++ 8.1.4 64-bit using the network drive approach:

    b4a241a3-9164-40e7-9e58-cfb0e6832881-image.png

    as well as the net use drive letter approach:

    1bf7ab3c-31fd-498c-8ba9-bfd7ba26c3fd-image.png

    Cheers.



  • @Michael-Vincent i found problem - i open NPP before add disc and it’s not displayed


Log in to reply