Skip to content

Commit dd0b736

Browse files
authored
Merge branch 'sqlc-dev:main' into main
2 parents 77c508d + ce83d3f commit dd0b736

File tree

3,230 files changed

+20488
-6408
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

3,230 files changed

+20488
-6408
lines changed

.github/ISSUE_TEMPLATE/BUG_REPORT.yml

Lines changed: 6 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
name: Bug Report
22
description: File a bug report
3-
labels: [bug, triage]
3+
labels: [bug]
44
body:
55
- type: dropdown
66
id: version
@@ -9,17 +9,12 @@ body:
99
description: What version of sqlc are you running? If you don't know, run `sqlc version`.
1010
multiple: false
1111
options:
12+
- 1.30.0
13+
- 1.29.0
14+
- 1.28.0
15+
- 1.27.0
16+
- 1.26.0
1217
- 1.25.0
13-
- 1.24.0
14-
- 1.23.0
15-
- 1.22.0
16-
- 1.21.0
17-
- 1.20.0
18-
- 1.19.1
19-
- 1.19.0
20-
- 1.18.0
21-
- 1.17.2
22-
- 1.16.0
2318
- Other
2419
validations:
2520
required: true

.github/ISSUE_TEMPLATE/FEATURE_REQUEST.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
name: Feature Request
22
description: Request a new feature or a change to an existing feature
3-
labels: [enhancement, triage]
3+
labels: [enhancement]
44
body:
55
- type: textarea
66
id: feature

.github/dependabot.yml

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,11 @@ updates:
44
directory: "/"
55
schedule:
66
interval: "daily"
7+
groups:
8+
production-dependencies:
9+
dependency-type: "production"
10+
development-dependencies:
11+
dependency-type: "development"
712
- package-ecosystem: "docker"
813
directory: "/"
914
schedule:
@@ -21,3 +26,9 @@ updates:
2126
# sphinx
2227
- dependency-name: "docutils"
2328
- dependency-name: "sphinx"
29+
groups:
30+
production-dependencies:
31+
dependency-type: "production"
32+
development-dependencies:
33+
dependency-type: "development"
34+

.github/workflows/buf.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,6 @@ jobs:
44
build:
55
runs-on: ubuntu-latest
66
steps:
7-
- uses: actions/checkout@v4
7+
- uses: actions/checkout@v6
88
- uses: bufbuild/buf-setup-action@v1
99
- uses: bufbuild/buf-lint-action@v1

.github/workflows/build.yml

Lines changed: 19 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,19 @@
1+
name: build
2+
on:
3+
workflow_dispatch:
4+
jobs:
5+
build:
6+
strategy:
7+
matrix:
8+
os: [ubuntu-24.04, macos-14, windows-2022]
9+
name: build ${{ matrix.os }}
10+
runs-on: ${{ matrix.os }}
11+
steps:
12+
- uses: actions/checkout@v6
13+
- uses: actions/setup-go@v6
14+
with:
15+
go-version: '1.26.0'
16+
- name: install ./...
17+
run: go build ./...
18+
env:
19+
CGO_ENABLED: "0"

.github/workflows/ci-kotlin.yml

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -6,16 +6,17 @@ on:
66
pull_request:
77
jobs:
88
build:
9+
if: false
910
name: test
1011
runs-on: ubuntu-latest
1112
steps:
12-
- uses: actions/checkout@v4
13-
- uses: actions/setup-go@v5
13+
- uses: actions/checkout@v6
14+
- uses: actions/setup-go@v6
1415
with:
15-
go-version: '1.21.3'
16+
go-version: '1.26.0'
1617
- name: install ./...
1718
run: go install ./...
18-
- uses: actions/checkout@v4
19+
- uses: actions/checkout@v6
1920
with:
2021
repository: sqlc-dev/sqlc-gen-kotlin
2122
path: kotlin

.github/workflows/ci-python.yml

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -6,16 +6,17 @@ on:
66
pull_request:
77
jobs:
88
build:
9+
if: false
910
name: test
1011
runs-on: ubuntu-latest
1112
steps:
12-
- uses: actions/checkout@v4
13-
- uses: actions/setup-go@v5
13+
- uses: actions/checkout@v6
14+
- uses: actions/setup-go@v6
1415
with:
15-
go-version: '1.21.3'
16+
go-version: '1.26.0'
1617
- name: install ./...
1718
run: go install ./...
18-
- uses: actions/checkout@v4
19+
- uses: actions/checkout@v6
1920
with:
2021
repository: sqlc-dev/sqlc-gen-python
2122
path: python

.github/workflows/ci-typescript.yml

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -6,16 +6,17 @@ on:
66
pull_request:
77
jobs:
88
build:
9+
if: false
910
name: test
1011
runs-on: ubuntu-latest
1112
steps:
12-
- uses: actions/checkout@v4
13-
- uses: actions/setup-go@v5
13+
- uses: actions/checkout@v6
14+
- uses: actions/setup-go@v6
1415
with:
15-
go-version: '1.21.3'
16+
go-version: '1.26.0'
1617
- name: install ./...
1718
run: go install ./...
18-
- uses: actions/checkout@v4
19+
- uses: actions/checkout@v6
1920
with:
2021
repository: sqlc-dev/sqlc-gen-typescript
2122
path: typescript

.github/workflows/ci.yml

Lines changed: 35 additions & 44 deletions
Original file line numberDiff line numberDiff line change
@@ -5,79 +5,70 @@ on:
55
- main
66
pull_request:
77
jobs:
8-
test:
8+
build:
99
strategy:
1010
matrix:
11-
os: [ubuntu-latest, macos-latest, windows-latest]
12-
cgo: ['1', '0']
13-
# Workaround no native support for conditional matrix items
14-
# https://github.com/orgs/community/discussions/26253#discussioncomment-6745038
15-
isMain:
16-
- ${{ github.ref == 'refs/heads/main' }}
17-
exclude:
18-
- isMain: false
19-
include:
20-
- os: ubuntu-latest
21-
cgo: '1'
22-
- os: ubuntu-latest
23-
cgo: '0'
24-
name: test ${{ matrix.os }} cgo=${{ matrix.cgo }}
25-
runs-on: ${{ matrix.os }}
26-
11+
goos: [darwin, linux, windows]
12+
goarch: [amd64, arm64]
13+
name: build ${{ matrix.goos }}/${{ matrix.goarch }}
14+
runs-on: ubuntu-24.04
15+
steps:
16+
- uses: actions/checkout@v6
17+
- uses: actions/setup-go@v6
18+
with:
19+
go-version: '1.26.0'
20+
- run: go build ./...
21+
env:
22+
CGO_ENABLED: "0"
23+
GOOS: ${{ matrix.goos }}
24+
GOARCH: ${{ matrix.goarch }}
25+
test:
26+
runs-on: ubuntu-24.04
2727
steps:
28-
- uses: actions/checkout@v4
29-
- uses: actions/setup-go@v5
28+
- uses: actions/checkout@v6
29+
- uses: actions/setup-go@v6
3030
with:
31-
go-version-file: go.mod
32-
check-latest: true
31+
go-version: '1.26.0'
3332

3433
- name: install gotestsum
3534
run: go install gotest.tools/gotestsum@latest
3635

3736
- name: install sqlc-gen-test
3837
run: go install github.com/sqlc-dev/sqlc-gen-test@v0.1.0
3938

39+
- name: install test-json-process-plugin
40+
run: go install ./scripts/test-json-process-plugin/
41+
4042
- name: install ./...
4143
run: go install ./...
4244
env:
43-
CGO_ENABLED: ${{ matrix.cgo }}
45+
CGO_ENABLED: "0"
4446

4547
- name: build internal/endtoend
4648
run: go build ./...
4749
working-directory: internal/endtoend/testdata
4850
env:
49-
CGO_ENABLED: ${{ matrix.cgo }}
51+
CGO_ENABLED: "0"
5052

51-
# Start a PostgreSQL server
52-
- uses: sqlc-dev/action-setup-postgres@master
53-
with:
54-
postgres-version: "16"
55-
id: postgres
53+
- name: install databases
54+
run: go run ./cmd/sqlc-test-setup install
5655

57-
# Start a MySQL server
58-
- uses: shogo82148/actions-setup-mysql@v1
59-
with:
60-
mysql-version: "8.1"
56+
- name: start databases
57+
run: go run ./cmd/sqlc-test-setup start
6158

6259
- name: test ./...
63-
run: gotestsum --junitfile junit.xml -- --tags=examples -timeout 20m ./...
60+
run: gotestsum --junitfile junit.xml -- --tags=examples -timeout 20m -failfast ./...
6461
env:
6562
CI_SQLC_PROJECT_ID: ${{ secrets.CI_SQLC_PROJECT_ID }}
6663
CI_SQLC_AUTH_TOKEN: ${{ secrets.CI_SQLC_AUTH_TOKEN }}
6764
SQLC_AUTH_TOKEN: ${{ secrets.CI_SQLC_AUTH_TOKEN }}
68-
MYSQL_SERVER_URI: root:@tcp(localhost:3306)/mysql?multiStatements=true&parseTime=true
69-
POSTGRESQL_SERVER_URI: ${{ steps.postgres.outputs.connection-uri }}?sslmode=disable
70-
CGO_ENABLED: ${{ matrix.cgo }}
65+
POSTGRESQL_SERVER_URI: "postgres://postgres:postgres@127.0.0.1:5432/postgres?sslmode=disable"
66+
MYSQL_SERVER_URI: "root:mysecretpassword@tcp(127.0.0.1:3306)/mysql?multiStatements=true&parseTime=true"
67+
CGO_ENABLED: "0"
7168

7269
vuln_check:
73-
runs-on: ubuntu-latest
70+
runs-on: ubuntu-24.04
7471
timeout-minutes: 5
7572

7673
steps:
77-
- uses: actions/checkout@v4
78-
- uses: actions/setup-go@v5
79-
with:
80-
go-version-file: go.mod
81-
check-latest: true
82-
- run: go install golang.org/x/vuln/cmd/govulncheck@latest
83-
- run: govulncheck ./...
74+
- uses: golang/govulncheck-action@v1

.github/workflows/gen.yml

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -17,8 +17,8 @@ jobs:
1717
# needed because the postgres container does not provide a healthcheck
1818
options: --health-cmd pg_isready --health-interval 10s --health-timeout 5s --health-retries 5
1919
steps:
20-
- uses: actions/checkout@v4
21-
- uses: actions/setup-go@v5
20+
- uses: actions/checkout@v6
21+
- uses: actions/setup-go@v6
2222
with:
2323
go-version-file: go.mod
2424
check-latest: true
@@ -32,7 +32,7 @@ jobs:
3232
PG_PASSWORD: postgres
3333
PG_PORT: ${{ job.services.postgres.ports['5432'] }}
3434
- name: Save results
35-
uses: actions/upload-artifact@v4
35+
uses: actions/upload-artifact@v6
3636
with:
3737
name: sqlc-pg-gen-results
3838
path: gen

0 commit comments

Comments
 (0)