Comments (9)
@hassanmojab, I just released an attempt to a fix for WSL in 0.30.1
.
In the best scenario wslview
works as expected and the browser will be automatically opened.
In the worst scenario, wslview
does not work but now the error is properly managed so the process won't crash and you'll be able to access the application manually. If you have any suggestion to properly use wslview
or an alternative as I'm not familiar at all with it, feel free to re-open the issue and keep the discussion going on.
Thanks
from skott.
Now it fully works!
from skott.
Hello @hassanmojab, thanks for the heads up!
It seems that it comes from an upstream problem on WSL microsoft/WSL#8892.
As I'm using a fork of openurl I will do two things:
-
Try to find a workaround for WSL to be able to keep that auto open behavior (some workarounds are discussed here). The thing is I'm not running WSL myself, so will be hard for me to reproduce and be sure to fix the problem.
-
Fix the uncaught exception in the library I'm using that should be handled properly and not make the process crash (upstream, not in skott). This would have for consequence to not open the browser automatically but would allow the application to be accessible anyway.
from skott.
The wslview
is not installed on wsl by default. I've found this command for opening a URL on the Windows default browser from wsl:
cmd.exe /C start "http://127.0.0.1:40000" > /dev/null 2>&1
from skott.
Ah fml I was too confident about it 😅 I'll add your cmd.exe in another PR as a primary target when being in WSL. Thanks for the hint! I reopen the issue
from skott.
Hey again @hassanmojab,
Just released 0.30.2
switching for cmd.exe
instead of wslview
. Could you please confirm me that it now works well please? I'll wait until then to close the issue.
Thanks!
from skott.
It works! the browser opens with the given URL 127.0.0.1:<port>
But unfortunately, there is still an issue :( 127.0.0.1 is considered as localhost in linux, but not in windows. So the ports of wsl are forwarded to the localhost of the windows and can be accessed by localhost:<port>
but not by 127.0.0.1:<port>
.
I think you simply can use localhost instead of 127.0.0.1 in the code like other cross-platform applications, and it should solve this problem.
from skott.
Glad to hear that the auto opening is working as expected on WSL :)
About localhost, I was not aware of that and I thought WSL would manage this transparently. Thanks for the hint! I just changed 127.0.0.1
to localhost
on all platforms in 0.30.3
.
Could you please test it and confirm me that it now fully works? Thanks again for your reactivity and contribution, highly appreciate it
from skott.
Thanks again for confirming that @hassanmojab!
from skott.
Related Issues (20)
- Allow "import { type X }" to be part of the "typeOnly" tracking process
- skott installation adds 544 MB to node_modules HOT 9
- Failed to Resolve with index.tsx files HOT 3
- Support imports map in package.json HOT 1
- Feature request: group modules in visualizaton using project structure HOT 28
- Refresh application HOT 5
- Resolving paths using path aliases HOT 10
- It's so useful, just to express my gratitude. HOT 1
- Feature request: call graph HOT 1
- Feature Request: Allow path grouping to visualize relationships between monorepo packages as a whole HOT 6
- Introduce diagnostics collection to monitor performance
- fs-tree-structure is using a lodash.set that has high severity vulnerability! HOT 2
- Issue installing `[email protected]` with pnpm HOT 2
- Can support for vue projects be added? HOT 1
- provde option to ignore barrel files HOT 7
- Ship a bundled and standalone version of skott's cli
- process.chdir does not affect working directory used by skott for creating node id paths HOT 21
- Resolving "import type" statements HOT 3
- Watch mode not always working HOT 5
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from skott.