-
Notifications
You must be signed in to change notification settings - Fork 1.4k
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
feat(client/electron): propagate structured errors from Go to TypeScript #2033
Conversation
@@ -47,6 +47,7 @@ const DNS_RESOLVERS = ['1.1.1.1', '9.9.9.9']; | |||
// about the others. | |||
export class GoVpnTunnel implements VpnTunnel { | |||
private readonly tun2socks: GoTun2socks; | |||
private readonly connectivityChecker: GoTun2socks; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Why is this type GoTun2socks
? Why do we need two?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Because we are invoking the same binary with different arguments. And these two processes might run at the same time. For example, we will check connectivity here, and tun2socks is still running until we stop it later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This looks great.
} | ||
return nil | ||
} | ||
|
||
// newIllegalConfigErrorWithDetails creates a TypeScript parsable SSIllegalConfig error with detailed information. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Should this be IllegalConfig
?
Added detailed error propagation from Golang to TypeScript for the desktop Outline Client (Windows & Linux).
New Error Details
Empty hostname
Port out-of-range
Current Version (v1.13.1)
Empty hostname
Port out-of-range