diff --git a/internal/command/command.go b/internal/command/command.go index ea8ff954c..d798af234 100644 --- a/internal/command/command.go +++ b/internal/command/command.go @@ -394,7 +394,12 @@ func checkVersion(logger output.Logger) { body, _ := ioutil.ReadAll(resp.Body) latestVersion := strings.TrimSpace(string(body)) - if latestVersion != build.Semver() { + currentVersion := build.Semver() + if currentVersion == "undefined" { + return // avoid warning in local development + } + + if currentVersion != latestVersion { logger.Info(fmt.Sprintf( "\n⚠️ Version warning: a new version of Flow CLI is available (%s).\n"+ "Read the installation guide for upgrade instructions: https://docs.onflow.org/flow-cli/install",