Skip to content

Commit 00f6cb8

Browse files
authored
chore: upgrade to go1.23 (#6021)
1 parent 949daed commit 00f6cb8

6 files changed

Lines changed: 10 additions & 27 deletions

File tree

.github/workflows/ci.yml

Lines changed: 4 additions & 21 deletions
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@ jobs:
1717
- name: Set up Go
1818
uses: actions/setup-go@v3
1919
with:
20-
go-version: '1.21'
20+
go-version: '1.23'
2121

2222
- name: Set up Node
2323
uses: actions/setup-node@v1
@@ -42,7 +42,7 @@ jobs:
4242
- name: Set up Go
4343
uses: actions/setup-go@v3
4444
with:
45-
go-version: '1.21'
45+
go-version: '1.23'
4646

4747
- name: Set up Node
4848
uses: actions/setup-node@v1
@@ -69,7 +69,7 @@ jobs:
6969
- name: Set up Go
7070
uses: actions/setup-go@v3
7171
with:
72-
go-version: '1.21'
72+
go-version: '1.23'
7373

7474
- name: Set up Node
7575
uses: actions/setup-node@v1
@@ -92,30 +92,13 @@ jobs:
9292
with:
9393
directory: cf-custom-resources/
9494

95-
staticcheck:
96-
runs-on: ubuntu-latest
97-
steps:
98-
- name: Set up Go
99-
uses: actions/setup-go@v3
100-
with:
101-
go-version: '1.21'
102-
103-
- name: Check out code
104-
uses: actions/checkout@v2
105-
106-
- name: Run golangci-lint
107-
uses: golangci/golangci-lint-action@v3
108-
with:
109-
version: v1.54
110-
args: --timeout 5m0s
111-
11295
license:
11396
runs-on: ubuntu-latest
11497
steps:
11598
- name: Set up Go
11699
uses: actions/setup-go@v3
117100
with:
118-
go-version: '1.21'
101+
go-version: '1.23'
119102

120103
- name: Check out code
121104
uses: actions/checkout@v2

.github/workflows/ci_size_computer.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -91,7 +91,7 @@ jobs:
9191
echo ${{ github.event.number }} > artifacts/pr_number
9292
echo ${sizes_json} > artifacts/sizes.json
9393
94-
- uses: actions/upload-artifact@v3
94+
- uses: actions/upload-artifact@v4
9595
with:
9696
name: pr_number_and_bin_sizes
9797
path: artifacts/

CONTRIBUTING.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,7 @@ Please read it over and let us know if it's not up-to-date (or, even better, sub
2020

2121
### Environment
2222

23-
- Make sure you are using Go 1.21 (`go version`).
23+
- Make sure you are using Go 1.23 (`go version`).
2424
- Fork the repository.
2525
- Clone your forked repository locally.
2626
- We use Go Modules to manage dependencies, so you can develop outside of your $GOPATH.

Dockerfile

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
FROM golang:1.21
1+
FROM golang:1.23
22
# We need to have both nodejs and go to build the binaries.
33
# We could use multi-stage builds but that would require significantly changing our Makefile.
44
RUN apt-get update

go.mod

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
module github.com/aws/copilot-cli
22

3-
go 1.21
3+
go 1.23
44

55
require (
66
github.com/AlecAivazis/survey/v2 v2.3.2

internal/pkg/cli/deploy.go

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -338,7 +338,7 @@ func (o *deployOpts) getDeploymentOrder() ([][]string, error) {
338338
if err != nil {
339339
return nil, err
340340
}
341-
workloadsToAppend := slices.DeleteFunc(localWorkloads, func(s string) bool { return slices.Contains(specifiedWorkloadList, s) })
341+
workloadsToAppend := slices.DeleteFunc(slices.Clone(localWorkloads), func(s string) bool { return slices.Contains(specifiedWorkloadList, s) })
342342
if len(workloadsToAppend) != 0 {
343343
groupsMap[math.MaxInt] = append(groupsMap[math.MaxInt], workloadsToAppend...)
344344
}
@@ -348,7 +348,7 @@ func (o *deployOpts) getDeploymentOrder() ([][]string, error) {
348348
if err != nil {
349349
return nil, err
350350
}
351-
workloadsToAppend := slices.DeleteFunc(initializedWorkloads, func(s string) bool { return slices.Contains(specifiedWorkloadList, s) })
351+
workloadsToAppend := slices.DeleteFunc(slices.Clone(initializedWorkloads), func(s string) bool { return slices.Contains(specifiedWorkloadList, s) })
352352
if len(workloadsToAppend) != 0 {
353353
groupsMap[math.MaxInt] = append(groupsMap[math.MaxInt], workloadsToAppend...)
354354
}

0 commit comments

Comments
 (0)