-
-
Notifications
You must be signed in to change notification settings - Fork 50
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
Windows: doesn't render files in WSL$ #504
Comments
Hey @thoni56, which browser are you using? and are you using the latest version of the extension? version 2.6.1? I will try to reproduce this issue but it's most likely a browser restriction... 😞 |
Thanks for looking into this. I'm using latest version of extension on Chrome and Vivaldi on Windows. Neither can render a file-url that references a file on the WSL-side. (Edge does not render correctly no matter if the file is on Windows or WSL-side.) Firefox on WSL works fine, of course, as does actually Firefox on Windows (rendering a single AsciiDoc-file on WSL-side correctly). As a slightly different, but maybe related, note, Firefox on Windows does not render a docbook correctly, it fails with "Unresolved directive" on the The files I'm using can be found here. |
I can reproduce this issue, the root cause is:
This is a security limitation imposed by the browser. As a workaround, you can create a symlink.
|
I feels strange that that should affect only files in WSL storage... Probably the But anyway, good to know, and thanks again for looking into it! |
I think it's a bug (or at least a limitation) of Chromium. You should open an issue at https://bugs.chromium.org/p/chromium/issues/list with a simple reproduction case. To reproduce this issue you can try to load a file from JavScript using const url = 'file://wsl$/Ubuntu-20.04/home/user/file.txt'
const request = new XMLHttpRequest()
request.open('GET', url, true)
request.send(null) |
You should probably mention that this issue happens in a WebExtension with "Access to local files" enabled. |
On Windows with WSL2, a loaded valid file, does not render if that file is from the "WSL side".
NOTE: A file path to a WSL2 file is something like
file://wsl$/Ubuntu/home/...
and the dollar sign is converted to "%24" so the file path in the address field looks likefile://wsl%24/Ubuntu/home/...
maybe that is a clue.How to repeat:
explorer.exe .
to open a Windows Explorer window in that directoryThe text was updated successfully, but these errors were encountered: