Skip to content

Commit 57c625f

Browse files
authored
Merge branch 'main' into changed_since_slot
2 parents 889b6bc + 20713fb commit 57c625f

244 files changed

Lines changed: 15363 additions & 920 deletions

File tree

Some content is hidden

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

.github/workflows/commit-lint.yml

Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,14 @@
1+
name: commit-lint
2+
on:
3+
pull_request:
4+
branches: [main]
5+
6+
jobs:
7+
commitlint:
8+
runs-on: ubuntu-latest
9+
steps:
10+
- uses: actions/checkout@v4
11+
with:
12+
fetch-depth: 0
13+
14+
- uses: wagoid/commitlint-github-action@v6

.github/workflows/lint.yml

Lines changed: 32 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,32 @@
1+
on:
2+
push:
3+
paths:
4+
- "**.go"
5+
- "go.mod"
6+
- "go.sum"
7+
- ".golangci.yml"
8+
- ".github/workflows/lint.yml"
9+
pull_request:
10+
paths:
11+
- "**.go"
12+
- "go.mod"
13+
- "go.sum"
14+
- ".golangci.yml"
15+
- ".github/workflows/lint.yml"
16+
name: lint
17+
jobs:
18+
golangci-lint:
19+
runs-on: ubuntu-latest
20+
steps:
21+
- name: Checkout code
22+
uses: actions/checkout@v4
23+
- name: Install Go
24+
uses: actions/setup-go@v5
25+
with:
26+
go-version: "1.24.x"
27+
cache: false
28+
- name: golangci-lint
29+
uses: golangci/golangci-lint-action@v7
30+
with:
31+
version: v2.11.4
32+
args: --timeout=10m

.github/workflows/release.yml

Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,16 @@
1+
name: release
2+
on:
3+
push:
4+
branches: [main]
5+
6+
permissions:
7+
contents: write
8+
pull-requests: write
9+
10+
jobs:
11+
release-please:
12+
runs-on: ubuntu-latest
13+
steps:
14+
- uses: googleapis/release-please-action@v4
15+
with:
16+
release-type: go

.github/workflows/semver-check.yml

Lines changed: 22 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,22 @@
1+
name: semver-check
2+
on:
3+
pull_request:
4+
branches: [main]
5+
6+
jobs:
7+
gorelease:
8+
runs-on: ubuntu-latest
9+
steps:
10+
- uses: actions/checkout@v4
11+
with:
12+
fetch-depth: 0
13+
14+
- uses: actions/setup-go@v5
15+
with:
16+
go-version: "1.24"
17+
18+
- name: Install gorelease
19+
run: go install golang.org/x/exp/cmd/gorelease@latest
20+
21+
- name: Check API compatibility
22+
run: gorelease

.github/workflows/tests.yml

Lines changed: 16 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,16 @@
1-
on: [push, pull_request]
1+
on:
2+
push:
3+
paths:
4+
- "**.go"
5+
- "go.mod"
6+
- "go.sum"
7+
- ".github/workflows/tests.yml"
8+
pull_request:
9+
paths:
10+
- "**.go"
11+
- "go.mod"
12+
- "go.sum"
13+
- ".github/workflows/tests.yml"
214
name: tests
315
jobs:
416
test:
@@ -9,10 +21,10 @@ jobs:
921
runs-on: ${{ matrix.os }}
1022
steps:
1123
- name: Install Go
12-
uses: actions/setup-go@v2
24+
uses: actions/setup-go@v5
1325
with:
1426
go-version: ${{ matrix.go-version }}
1527
- name: Checkout code
16-
uses: actions/checkout@v2
28+
uses: actions/checkout@v4
1729
- name: Test
18-
run: go test ./... -count=100
30+
run: go test ./... -race -count=100

.golangci.yml

Lines changed: 121 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,121 @@
1+
version: "2"
2+
3+
run:
4+
timeout: 10m
5+
6+
issues:
7+
max-issues-per-linter: 0
8+
max-same-issues: 0
9+
10+
linters:
11+
default: none
12+
enable:
13+
- errcheck
14+
- govet
15+
- ineffassign
16+
- staticcheck
17+
- unused
18+
- errorlint
19+
- misspell
20+
settings:
21+
errcheck:
22+
check-type-assertions: false
23+
check-blank: false
24+
exclude-functions:
25+
- (io.Closer).Close
26+
- (*os.File).Close
27+
- (net.Listener).Close
28+
- (*net.TCPConn).Close
29+
- (*net.UDPConn).Close
30+
- (*bytes.Buffer).WriteString
31+
- (*bytes.Buffer).WriteByte
32+
- (*bytes.Buffer).Write
33+
- (*strings.Builder).WriteString
34+
- (*strings.Builder).WriteByte
35+
- (*strings.Builder).WriteRune
36+
- (*strings.Builder).Write
37+
- (*go.uber.org/zap/buffer.Buffer).Write
38+
- (*github.com/gorilla/websocket.Conn).SetReadDeadline
39+
- (*github.com/gorilla/websocket.Conn).SetWriteDeadline
40+
- fmt.Fprint
41+
- fmt.Fprintln
42+
- fmt.Fprintf
43+
- github.com/gagliardetto/binary.EncodeCompactU16Length
44+
errorlint:
45+
errorf: true
46+
asserts: true
47+
comparison: true
48+
staticcheck:
49+
checks:
50+
- all
51+
# Known follow-ups — tracked separately, not in scope for the lint rollout:
52+
- -SA1019 # deprecated API usage (logging package, ssh/terminal -> x/term, cloudkms.New)
53+
- -ST1001 # dot imports (text/format, zap-box) — refactor-scale change
54+
- -ST1003 # underscore naming in exported consts/params — breaking API change
55+
- -ST1016 # receiver name consistency — ws pkg mixes "c"/"cl", refactor-scale
56+
- -ST1019 # duplicate imports (same files)
57+
- -QF1008 # could remove embedded field selector — stylistic, keep for legibility
58+
- -SA9003 # empty branches — scaffolding in rpc/ws/examples/
59+
misspell:
60+
locale: US
61+
exclusions:
62+
generated: lax
63+
presets:
64+
- comments
65+
- common-false-positives
66+
- legacy
67+
- std-error-handling
68+
rules:
69+
# Test files: allow unchecked errors and legacy error comparisons.
70+
- path: _test\.go
71+
linters:
72+
- errcheck
73+
- errorlint
74+
# CLI / cmd binaries: unchecked errors on stdout prints are fine.
75+
- path: cmd/
76+
linters:
77+
- errcheck
78+
- path: cli/
79+
linters:
80+
- errcheck
81+
# WS subscription examples are demo code using `if false {}` to show
82+
# multiple patterns side by side. Exclude from lint.
83+
- path: rpc/ws/examples/
84+
linters:
85+
- govet
86+
- staticcheck
87+
# Unused identifiers that are either intentionally kept (lookup tables
88+
# reserved for future work, logging-side-effect registrations) or live
89+
# in code paths pending refactor. Tracked as follow-up.
90+
- path: base58/tables\.go
91+
linters:
92+
- unused
93+
- path: logging\.go
94+
linters:
95+
- unused
96+
- path: diff/
97+
linters:
98+
- unused
99+
- staticcheck
100+
- path: text/encoder\.go
101+
linters:
102+
- staticcheck
103+
- path: zap-box/
104+
linters:
105+
- unused
106+
- path: programs/token(-2022)?/json\.go
107+
linters:
108+
- unused
109+
- path: rpc/client\.go
110+
linters:
111+
- unused
112+
- path: rpc/ws/client\.go
113+
linters:
114+
- unused
115+
116+
formatters:
117+
enable:
118+
- gofmt
119+
- goimports
120+
exclusions:
121+
generated: lax

CHANGELOG.md

Lines changed: 37 additions & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -1,23 +1,43 @@
1-
# Change log
1+
# Changelog
22

3-
The format is based on
4-
[Keep a Changelog](https://keepachangelog.com/en/1.0.0/), and this
5-
project adheres to
6-
[Semantic Versioning](https://semver.org/spec/v2.0.0.html). See
7-
[MAINTAINERS.md](./MAINTAINERS.md) for instructions to keep up to
8-
date.
3+
## [1.19.0](https://github.com/solana-foundation/solana-go/compare/v1.18.0...v1.19.0) (2026-04-23)
94

10-
```
11-
⚠️ solana-go works using SemVer but in 0 version, which means that the 'minor' will be changed when some broken changes are introduced into the application, and the 'patch' will be changed when a new feature with new changes is added or for bug fixing. As soon as v1.0.0 be released, solana-go will start to use SemVer as usual.
12-
```
135

14-
# [v0.1.0] 2020-11-09
6+
### Features
157

16-
First release
8+
* is token mint classifier ([4f72982](https://github.com/solana-foundation/solana-go/commit/4f72982442c9b3c166b72dbb2de730f58b575539))
179

18-
# Includes the following features:
1910

20-
* Get basic information from the chain about accounts, balances, etc.
21-
* Issue SOL native token transfer
22-
* Issue SPL token transfers
23-
* Get Project SERUM markets list and live market data
11+
### Bug Fixes
12+
13+
* enhance getUint64 function to handle string inputs ([5309095](https://github.com/solana-foundation/solana-go/commit/53090952ffc598c1870617b1727179135994ec65))
14+
* keep websocket request IDs within JSON-safe range ([8ed3105](https://github.com/solana-foundation/solana-go/commit/8ed31050f7af62f26b5615f40546bb498cab9219))
15+
* **message:** json version detection ([1fd2201](https://github.com/solana-foundation/solana-go/commit/1fd2201431de71d9164d281eef2c62f858fb5016))
16+
* **message:** use gojson ([8d211d5](https://github.com/solana-foundation/solana-go/commit/8d211d5dc9e610b54fb84f662d83e2f55668e9d4))
17+
* reject malformed ed25519 private keys in PrivateKeyFromBase58 ([edcedcc](https://github.com/solana-foundation/solana-go/commit/edcedcc2ba5ebd01c65baf64b8a22bf879cb0d55))
18+
* **rpc:** match ParsedTransactionMeta to TransactionMeta ([a0f95c2](https://github.com/solana-foundation/solana-go/commit/a0f95c23eac6031c0f44e3095b763da531b8b2b7))
19+
20+
### Performance Improvements
21+
22+
* **json:** swap encoding/json and jsoniter for goccy/go-json ([c445f76](https://github.com/solana-foundation/solana-go/commit/c445f76c249d944731983fd720c2a9e6a874dc62))
23+
* **transaction:** add cap hints and use pk instead of str ([91e8cec](https://github.com/solana-foundation/solana-go/commit/91e8cec9785fccd2663f28e61c8cc5353f38c419))
24+
25+
26+
## [1.18.0](https://github.com/solana-foundation/solana-go/compare/v1.17.0...v1.18.0) (2026-04-16)
27+
28+
29+
### Features
30+
31+
* add getters to txn with meta
32+
* add token-2022 extensions
33+
* stake state types & ext tests
34+
* vote program complete
35+
36+
### Bug Fixes
37+
38+
* allign rpc client with agave
39+
* memo program parity
40+
41+
### Performance Improvements
42+
43+
* **message:** eliminate complex scans, struct copies, and redundant allocs

0 commit comments

Comments
 (0)