Skip to content

build(deps): bump golang to 1.27.0 - #644

Merged
zimeg merged 4 commits into
mainfrom
chore-bump-golang
Aug 31, 2026
Merged

build(deps): bump golang to 1.27.0#644
zimeg merged 4 commits into
mainfrom
chore-bump-golang

Conversation

@slack-cli-releaser

Copy link
Copy Markdown
Contributor

Automatic update to the latest release of Go

@slack-cli-releaser
slack-cli-releaser Bot requested a review from a team as a code owner August 21, 2026 00:20
@slack-cli-releaser slack-cli-releaser Bot added this to the Next Release milestone Aug 21, 2026
@slack-cli-releaser slack-cli-releaser Bot added code health M-T: Test improvements and anything that improves code health semver:patch Use on pull requests to describe the release version increment labels Aug 21, 2026
@zimeg zimeg modified the milestones: v4.7.0, Next Release Aug 28, 2026
Bring the Go 1.27 bump current with main after the goreleaser/registry
fix landed (#659): go.mod/go.sum re-tidied under Go 1.27, keeping
goreleaser v2.17.1 + registry v1.8.0. Verified: go build ./..., full
test suite, and make build-snapshot (goreleaser compile-from-source)
all green under 1.27.

❤️
Co-Authored-By: Claude <svc-devxp-claude@slack-corp.com>
@codecov

codecov Bot commented Aug 30, 2026

Copy link
Copy Markdown

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 78.19%. Comparing base (b589377) to head (e210cca).
⚠️ Report is 7 commits behind head on main.

Additional details and impacted files
@@            Coverage Diff             @@
##             main     #644      +/-   ##
==========================================
+ Coverage   72.59%   78.19%   +5.60%     
==========================================
  Files         239      239              
  Lines       20228    18135    -2093     
==========================================
- Hits        14684    14181     -503     
+ Misses       4274     3954     -320     
+ Partials     1270        0    -1270     

☔ View full report in Codecov by Harness.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

@zimeg

zimeg commented Aug 31, 2026

Copy link
Copy Markdown
Member

The "Unmarshal Error" case in Test_HookScript_UnmarshalJSON now expecting three blank commands is fallout from Go 1.27 rewiring encoding/json onto the v2 implementation. From the Go 1.27 release notes, under "New encoding/json/v2 and encoding/json/jsontext packages":

The encoding/json package is now backed by the v2 implementation. Marshaling and unmarshaling behavior is preserved, but the exact text of error messages may differ. The package also gains a number of new Options that can configure v2 to operate with v1 semantics to avoid requiring a full migration to the new API. The v1 API will continue to be supported and users are not required to migrate.

For json.Unmarshal([]byte("[1, 2, 3]"), &hookScripts): the decoder walks the JSON array and grows the []HookScript slice one element at a time, calling HookScript.UnmarshalJSON per element. Each element (1, 2, 3) is a number, so the inner json.Unmarshal(data, &cmd) into a string returns a *json.UnmarshalTypeError before s.Command is assigned — leaving each element at its zero value {Command: ""}. The v2 decoder leaves the slice grown to all three positions when it errors, so the residual state is three blank entries, not one. Hence the expectation change from {{Command: ""}}{{Command: ""}, {Command: ""}, {Command: ""}}. The returned error type (*json.UnmarshalTypeError) is unchanged.

Unrelated nit, pre-existing (not from this PR): require.IsType(t, err, tc.expectedErrorType) has the args reversed — testify's signature is IsType(t, expectedType, object), so it should be require.IsType(t, tc.expectedErrorType, err). Passes either way when they match, but a mismatch would print an inverted message.

@zimeg zimeg self-assigned this Aug 31, 2026

@zimeg zimeg left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🚀 LGTM! Thanks @dependabot!

Comment thread go.mod
Comment on lines -516 to -529
require (
github.com/fatih/color v1.19.0 // indirect
github.com/go-git/go-git/v5 v5.19.2
github.com/inconshreveable/mousetrap v1.1.0 // indirect
github.com/kubescape/go-git-url v0.0.33
github.com/mattn/go-colorable v0.1.14 // indirect
github.com/mattn/go-isatty v0.0.20 // indirect
github.com/spf13/pflag v1.0.10
github.com/stretchr/objx v0.5.3 // indirect
github.com/uber/jaeger-lib v2.4.1+incompatible // indirect
go.uber.org/atomic v1.11.0 // indirect
golang.org/x/term v0.45.0 // indirect
gopkg.in/yaml.v3 v3.0.1 // indirect
)

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

⭐ praise: Nice to find this included with the above dependencies!

blob: `[1, 2, 3]`,
expectedErrorType: &json.UnmarshalTypeError{},
expectedHookScripts: []HookScript{{Command: ""}},
expectedHookScripts: []HookScript{{Command: ""}, {Command: ""}, {Command: ""}},

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🗃️ note: Here's the aforementioned change to tests.

🔗 https://go.dev/doc/go1.27

@zimeg
zimeg enabled auto-merge (squash) August 31, 2026 20:58
@zimeg
zimeg merged commit c6b3a21 into main Aug 31, 2026
13 checks passed
@zimeg
zimeg deleted the chore-bump-golang branch August 31, 2026 22:05
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

code health M-T: Test improvements and anything that improves code health semver:patch Use on pull requests to describe the release version increment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant