Fix linting error and cleanup error messages
This commit is contained in:
parent
1e75a74d18
commit
faabdc247b
1 changed files with 5 additions and 1 deletions
|
|
@ -35,12 +35,16 @@ func StartSSHServerWithOptions(ctx context.Context, session *liveshare.Session,
|
|||
|
||||
func StartJupyterServer(ctx context.Context, session *liveshare.Session) (int, string, error) {
|
||||
client, err := connectToGRPCServer(ctx, session, "")
|
||||
if err != nil {
|
||||
return 0, "", err
|
||||
}
|
||||
|
||||
ctx, cancel := context.WithTimeout(ctx, grpc.RequestTimeout)
|
||||
defer cancel()
|
||||
|
||||
serverPort, serverUrl, err := client.StartJupyterServer(ctx)
|
||||
if err != nil {
|
||||
return 0, "", fmt.Errorf("failed to start JupyterLab server: %w", err)
|
||||
return 0, "", err
|
||||
}
|
||||
|
||||
return serverPort, serverUrl, nil
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue