diff --git a/changelog.md b/changelog.md index 10ab393b35..2f4dc4ae66 100644 --- a/changelog.md +++ b/changelog.md @@ -6,6 +6,12 @@ The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/), and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html). +## 0.46.1 + +### Fixed + +* Fixed regression in `state refresh` where it would exit with a non-zero code when there were no changes. + ## 0.46.0 ### Added diff --git a/internal/runners/refresh/refresh.go b/internal/runners/refresh/refresh.go index 1a25a6b594..41a3e3c352 100644 --- a/internal/runners/refresh/refresh.go +++ b/internal/runners/refresh/refresh.go @@ -92,7 +92,8 @@ func (r *Refresh) Run(params *Params) error { } if !needsUpdate { - return locale.NewInputError("refresh_runtime_uptodate") + r.out.Notice(locale.T("refresh_runtime_uptodate")) + return nil } rti, err := runtime_runbit.Update(r.prime, trigger.TriggerRefresh, runtime_runbit.WithoutHeaders(), runtime_runbit.WithIgnoreAsync()) diff --git a/test/integration/refresh_int_test.go b/test/integration/refresh_int_test.go index 7b2863ba4f..d71dfd1c0b 100644 --- a/test/integration/refresh_int_test.go +++ b/test/integration/refresh_int_test.go @@ -39,7 +39,7 @@ func (suite *RefreshIntegrationTestSuite) TestRefresh() { cp = ts.Spawn("refresh") cp.Expect("already up to date") - cp.ExpectExitCode(1) + cp.ExpectExitCode(0) } func (suite *RefreshIntegrationTestSuite) TestJSON() { diff --git a/version.txt b/version.txt index 4c8c50fc8d..582463bf16 100644 --- a/version.txt +++ b/version.txt @@ -1 +1 @@ -0.46.0-RC3 \ No newline at end of file +0.46.1-RC1 \ No newline at end of file