diff --git a/cmd/start.go b/cmd/start.go index ee5bf71..3661d79 100644 --- a/cmd/start.go +++ b/cmd/start.go @@ -263,7 +263,9 @@ func waitForReady(serverURL string, timeout time.Duration) error { for time.Now().Before(deadline) { resp, err := httpClient.Get(url) if err == nil { - resp.Body.Close() + if closeErr := resp.Body.Close(); closeErr != nil { + // G104: error intentionally ignored in health-check polling loop + } if resp.StatusCode == http.StatusOK { return nil } diff --git a/pkg/watcher/watchManager.go b/pkg/watcher/watchManager.go index 82a0ad4..fa205f7 100644 --- a/pkg/watcher/watchManager.go +++ b/pkg/watcher/watchManager.go @@ -73,7 +73,9 @@ func (wm *WatchManager) Reload() error { for file := range wm.watchEntries { if _, exists := newFiles[file]; !exists { - wm.fileWatcher.Remove(file) + if err := wm.fileWatcher.Remove(file); err != nil { + log.Printf("[WARN] Cannot remove watcher for file %s: %v", file, err) + } } }