uber-go / nilaway

Static analysis tool to detect potential nil panics in Go code
Apache License 2.0
3.06k stars 60 forks source link

Upgrade minimum version of Go to 1.22 #275

Open yuxincs opened 1 month ago

yuxincs commented 1 month ago

Go 1.23 is recently released and this PR bumps our minimum version to Go 1.22, along with a few other house keeping changes.

codecov[bot] commented 1 month ago

Codecov Report

All modified and coverable lines are covered by tests :white_check_mark:

Project coverage is 87.85%. Comparing base (c91e71c) to head (5aa0785).

Additional details and impacted files ```diff @@ Coverage Diff @@ ## main #275 +/- ## ========================================== + Coverage 87.60% 87.85% +0.24% ========================================== Files 63 63 Lines 7916 7912 -4 ========================================== + Hits 6935 6951 +16 + Misses 799 787 -12 + Partials 182 174 -8 ```

:umbrella: View full report in Codecov by Sentry.
:loudspeaker: Have feedback on the report? Share it here.

github-actions[bot] commented 1 month ago

Golden Test

[!WARNING]
❌ NilAway errors reported on stdlib are different.

3220 errors on base branch (main, c91e71c) 3220 errors on test branch (428d6a1)

Diffs ```diff + /opt/hostedtoolcache/go/1.23.0/x64/src/internal/godebugs/table.go:1:1: INTERNAL ERROR(s): + nilaway_assertion_analyzer: nilaway_function_analyzer: analyzing function AppendSeq at /opt/hostedtoolcache/go/1.23.0/x64/src/slices/iter.go:49.1: backpropagation across node (/opt/hostedtoolcache/go/1.23.0/x64/src/slices/iter.go:50:6) of type *ast.AssignStmt failed for reason: unrecognized type of rhs in range statement: iter.Seq[E] + /opt/hostedtoolcache/go/1.23.0/x64/src/internal/godebugs/table.go:1:1: INTERNAL ERROR(s): + nilaway_assertion_analyzer: nilaway_function_analyzer: analyzing function ExampleChunk at /opt/hostedtoolcache/go/1.23.0/x64/src/slices/example_test.go:388.1: backpropagation across node (/opt/hostedtoolcache/go/1.23.0/x64/src/slices/example_test.go:405:6) of type *ast.AssignStmt failed for reason: unrecognized type of rhs in range statement: iter.Seq[slices_test.People] + analyzing function TestValues at /opt/hostedtoolcache/go/1.23.0/x64/src/slices/iter_test.go:58.1: backpropagation across node (/opt/hostedtoolcache/go/1.23.0/x64/src/slices/iter_test.go:66:7) of type *ast.AssignStmt failed for reason: unrecognized type of rhs in range statement: iter.Seq[int] + analyzing function TestChunkRange at /opt/hostedtoolcache/go/1.23.0/x64/src/slices/iter_test.go:275.1: backpropagation across node (/opt/hostedtoolcache/go/1.23.0/x64/src/slices/iter_test.go:278:6) of type *ast.AssignStmt failed for reason: unrecognized type of rhs in range statement: iter.Seq[[]int] + /opt/hostedtoolcache/go/1.23.0/x64/src/internal/godebugs/table.go:1:1: INTERNAL ERROR(s): + nilaway_assertion_analyzer: nilaway_function_analyzer: analyzing function ExamplePreorder at /opt/hostedtoolcache/go/1.23.0/x64/src/go/ast/example_test.go:143.1: backpropagation across node (/opt/hostedtoolcache/go/1.23.0/x64/src/go/ast/example_test.go:159:6) of type *ast.AssignStmt failed for reason: unrecognized type of rhs in range statement: iter.Seq[go/ast.Node] + analyzing function TestPreorderBreak at /opt/hostedtoolcache/go/1.23.0/x64/src/go/ast/walk_test.go:14.1: backpropagation across node (/opt/hostedtoolcache/go/1.23.0/x64/src/go/ast/walk_test.go:28:6) of type *ast.AssignStmt failed for reason: unrecognized type of rhs in range statement: iter.Seq[go/ast.Node] + /opt/hostedtoolcache/go/1.23.0/x64/src/internal/godebugs/table.go:1:1: INTERNAL ERROR(s): + nilaway_assertion_analyzer: nilaway_function_analyzer: analyzing function TestKeys at /opt/hostedtoolcache/go/1.23.0/x64/src/maps/iter_test.go:32.1: backpropagation across node (/opt/hostedtoolcache/go/1.23.0/x64/src/maps/iter_test.go:42:7) of type *ast.AssignStmt failed for reason: unrecognized type of rhs in range statement: iter.Seq[int] + analyzing function TestValues at /opt/hostedtoolcache/go/1.23.0/x64/src/maps/iter_test.go:52.1: backpropagation across node (/opt/hostedtoolcache/go/1.23.0/x64/src/maps/iter_test.go:62:7) of type *ast.AssignStmt failed for reason: unrecognized type of rhs in range statement: iter.Seq[int] - /opt/hostedtoolcache/go/1.23.0/x64/src/internal/coverage/rtcov/rtcov.go:1:1: INTERNAL ERROR(s): - nilaway_assertion_analyzer: nilaway_function_analyzer: analyzing function AppendSeq at /opt/hostedtoolcache/go/1.23.0/x64/src/slices/iter.go:49.1: backpropagation across node (/opt/hostedtoolcache/go/1.23.0/x64/src/slices/iter.go:50:6) of type *ast.AssignStmt failed for reason: unrecognized type of rhs in range statement: iter.Seq[E] - /opt/hostedtoolcache/go/1.23.0/x64/src/internal/coverage/rtcov/rtcov.go:1:1: INTERNAL ERROR(s): - nilaway_assertion_analyzer: nilaway_function_analyzer: analyzing function ExampleChunk at /opt/hostedtoolcache/go/1.23.0/x64/src/slices/example_test.go:388.1: backpropagation across node (/opt/hostedtoolcache/go/1.23.0/x64/src/slices/example_test.go:405:6) of type *ast.AssignStmt failed for reason: unrecognized type of rhs in range statement: iter.Seq[slices_test.People] - analyzing function TestValues at /opt/hostedtoolcache/go/1.23.0/x64/src/slices/iter_test.go:58.1: backpropagation across node (/opt/hostedtoolcache/go/1.23.0/x64/src/slices/iter_test.go:66:7) of type *ast.AssignStmt failed for reason: unrecognized type of rhs in range statement: iter.Seq[int] - analyzing function TestChunkRange at /opt/hostedtoolcache/go/1.23.0/x64/src/slices/iter_test.go:275.1: backpropagation across node (/opt/hostedtoolcache/go/1.23.0/x64/src/slices/iter_test.go:278:6) of type *ast.AssignStmt failed for reason: unrecognized type of rhs in range statement: iter.Seq[[]int] - /opt/hostedtoolcache/go/1.23.0/x64/src/internal/coverage/rtcov/rtcov.go:1:1: INTERNAL ERROR(s): - nilaway_assertion_analyzer: nilaway_function_analyzer: analyzing function ExamplePreorder at /opt/hostedtoolcache/go/1.23.0/x64/src/go/ast/example_test.go:143.1: backpropagation across node (/opt/hostedtoolcache/go/1.23.0/x64/src/go/ast/example_test.go:159:6) of type *ast.AssignStmt failed for reason: unrecognized type of rhs in range statement: iter.Seq[go/ast.Node] - analyzing function TestPreorderBreak at /opt/hostedtoolcache/go/1.23.0/x64/src/go/ast/walk_test.go:14.1: backpropagation across node (/opt/hostedtoolcache/go/1.23.0/x64/src/go/ast/walk_test.go:28:6) of type *ast.AssignStmt failed for reason: unrecognized type of rhs in range statement: iter.Seq[go/ast.Node] - /opt/hostedtoolcache/go/1.23.0/x64/src/internal/coverage/rtcov/rtcov.go:1:1: INTERNAL ERROR(s): - nilaway_assertion_analyzer: nilaway_function_analyzer: analyzing function TestKeys at /opt/hostedtoolcache/go/1.23.0/x64/src/maps/iter_test.go:32.1: backpropagation across node (/opt/hostedtoolcache/go/1.23.0/x64/src/maps/iter_test.go:42:7) of type *ast.AssignStmt failed for reason: unrecognized type of rhs in range statement: iter.Seq[int] - analyzing function TestValues at /opt/hostedtoolcache/go/1.23.0/x64/src/maps/iter_test.go:52.1: backpropagation across node (/opt/hostedtoolcache/go/1.23.0/x64/src/maps/iter_test.go:62:7) of type *ast.AssignStmt failed for reason: unrecognized type of rhs in range statement: iter.Seq[int] ```