Skip to content
This repository was archived by the owner on Jan 23, 2026. It is now read-only.
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 3 additions & 0 deletions cmd/dev.go
Original file line number Diff line number Diff line change
Expand Up @@ -207,14 +207,17 @@ Examples:
}
defer watcher.Close(tuiLogger)

tuiLogger.Trace("starting project server")
if err := projectServerCmd.Start(); err != nil {
errsystem.New(errsystem.ErrInvalidConfiguration, err, errsystem.WithContextMessage(fmt.Sprintf("Failed to start project: %s", err))).ShowErrorAndExit()
}

pid = projectServerCmd.Process.Pid
tuiLogger.Trace("started project server with pid: %d", pid)

if err := server.HealthCheck(devModeUrl); err != nil {
tuiLogger.Error("failed to health check connection: %s", err)
dev.KillProjectServer(tuiLogger, projectServerCmd, pid)
ui.Close(true)
return
}
Expand Down
4 changes: 2 additions & 2 deletions internal/dev/server.go
Original file line number Diff line number Diff line change
Expand Up @@ -458,9 +458,9 @@ func (s *Server) getWelcome(ctx context.Context, port int) (map[string]Welcome,
func (s *Server) HealthCheck(devModeUrl string) error {
started := time.Now()
var i int
for time.Since(started) < 15*time.Second {
for time.Since(started) < 30*time.Second {
i++
s.logger.Trace("health check request: %s", fmt.Sprintf("%s/_health", devModeUrl))
s.logger.Trace("health check request [#%d (%s)]: %s", i, time.Since(started), fmt.Sprintf("%s/_health", devModeUrl))
req, err := http.NewRequestWithContext(s.ctx, "GET", fmt.Sprintf("%s/_health", devModeUrl), nil)
if err != nil {
return fmt.Errorf("failed to create health check request: %w", err)
Expand Down
Loading