Skip to content

Commit

Permalink
Merge branch 'main' into fix/add-canonical-docstring-comments
Browse files Browse the repository at this point in the history
# Conflicts:
#	ably/auth.go
#	ably/proto_crypto.go
#	ably/proto_message.go
  • Loading branch information
sacOO7 committed Jan 4, 2023
2 parents c8b8f3e + 25877a6 commit 6e1a824
Show file tree
Hide file tree
Showing 12 changed files with 32 additions and 15 deletions.
11 changes: 9 additions & 2 deletions .github/workflows/check.yml
Expand Up @@ -14,7 +14,7 @@ jobs:
strategy:
fail-fast: false
matrix:
go-version: [1.17, 1.18]
go-version: [1.18, 1.19]

steps:
- uses: actions/checkout@v2
Expand All @@ -30,7 +30,14 @@ jobs:
run: go get -t -v ./ably/...

- name: Format
run: if [ "$(gofmt -l . | wc -l)" -gt 0 ]; then exit 1; fi
run: |
if go version | awk '$3 !~ /go1.18/ {exit(1)}';
then
echo -n Skipping gofmt test for ;
go version
exit 0
fi
if [ "$(gofmt -l . | wc -l)" -gt 0 ]; then exit 1; fi
- name: Vet
run: go vet ./ably/... ./scripts/...
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/integration-test.yml
Expand Up @@ -11,7 +11,7 @@ jobs:
strategy:
fail-fast: false
matrix:
go-version: [1.17, 1.18]
go-version: [1.18, 1.19]
protocol: ['json', 'msgpack']

steps:
Expand Down
9 changes: 9 additions & 0 deletions CHANGELOG.md
@@ -1,5 +1,14 @@
# Change Log

## [1.2.9](https://github.com/ably/ably-go/tree/v1.2.9)

[Full Changelog](https://github.com/ably/ably-go/compare/v1.2.8...v1.2.9)

**Merged pull requests:**

- Test against go 1.19, and drop support for 1.17 [\#563](https://github.com/ably/ably-go/pull/563) ([amnonbc](https://github.com/amnonbc))
- fix GO-2022-0493 [\#562](https://github.com/ably/ably-go/pull/562) ([amnonbc](https://github.com/amnonbc))

## [1.2.8](https://github.com/ably/ably-go/tree/v1.2.8)

[Full Changelog](https://github.com/ably/ably-go/compare/v1.2.7...v1.2.8) (2022-07-01)
Expand Down
3 changes: 2 additions & 1 deletion README.md
@@ -1,6 +1,7 @@
## [Ably Go](https://ably.com/)

[![.github/workflows/check.yml](https://github.com/ably/ably-go/actions/workflows/check.yml/badge.svg)](https://github.com/ably/ably-go/actions/workflows/check.yml)
[![.github/workflows/integration-test.yml](https://github.com/ably/ably-go/actions/workflows/integration-test.yml/badge.svg)](https://github.com/ably/ably-go/actions/workflows/integration-test.yml)

[![Go Reference](https://pkg.go.dev/badge/github.com/ably/ably-go/ably.svg)](https://pkg.go.dev/github.com/ably/ably-go/ably)

Expand Down Expand Up @@ -360,4 +361,4 @@ Please visit https://faqs.ably.com/ for access to our knowledgebase. If you requ
You can also view the [community reported Github issues](https://github.com/ably/ably-go/issues).

## Contributing
For guidance on how to contribute to this project, see [CONTRIBUTING.md](CONTRIBUTING.md).
For guidance on how to contribute to this project, see [CONTRIBUTING.md](CONTRIBUTING.md).
2 changes: 1 addition & 1 deletion ably/proto_http.go
Expand Up @@ -10,7 +10,7 @@ const (
ablyVersionHeader = "X-Ably-Version"
ablyErrorCodeHeader = "X-Ably-Errorcode"
ablyErrorMessageHeader = "X-Ably-Errormessage"
libraryVersion = "1.2.8"
libraryVersion = "1.2.9"
libraryName = "go"
ablyVersion = "1.2"
ablyClientIDHeader = "X-Ably-ClientId"
Expand Down
2 changes: 1 addition & 1 deletion ably/proto_message.go
Expand Up @@ -55,7 +55,7 @@ func (p *protocolMessage) updateInnerMessageEmptyFields(m *Message, index int) {
}
}

//updateInnerMessagesEmptyFields updates [Message.ID], [Message.ConnectionID] and [Message.Timestamp] with
// updateInnerMessagesEmptyFields updates [Message.ID], [Message.ConnectionID] and [Message.Timestamp] with
// outer/parent message fields.
func (p *protocolMessage) updateInnerMessagesEmptyFields() {
for i, m := range p.Messages {
Expand Down
4 changes: 2 additions & 2 deletions ably/realtime_presence_integration_test.go
Expand Up @@ -141,8 +141,8 @@ func TestRealtimePresence_EnsureChannelIsAttached(t *testing.T) {
assert.NoError(t, err)
}

//When a client is created with a ClientID, Enter is used to announce the client's presence.
//This example shows Client A entering their presence.
// When a client is created with a ClientID, Enter is used to announce the client's presence.
// This example shows Client A entering their presence.
func ExampleRealtimePresence_Enter() {

// A new realtime client is created with a ClientID.
Expand Down
2 changes: 1 addition & 1 deletion ably/realtime_presence_test.go
Expand Up @@ -11,7 +11,7 @@ import (
"github.com/ably/ably-go/ably"
)

//When a client is created without a ClientID, EnterClient is used to announce the presence of a client.
// When a client is created without a ClientID, EnterClient is used to announce the presence of a client.
// This example shows a client without a clientID announcing the presence of "Client A" using EnterClient.
func ExampleRealtimePresence_EnterClient() {

Expand Down
5 changes: 3 additions & 2 deletions ably/rest_channel.go
Expand Up @@ -54,8 +54,9 @@ func (c *RESTChannel) Publish(ctx context.Context, name string, data interface{}
// RESTChannel.Publish and RESTChannel.PublishMultiple.
//
// TODO: This started out as just an option for PublishMultiple, but has since
// been added as an option for Publish too, so it should be renamed to
// PublishOption when we perform the next major version bump to 2.x.x.
//
// been added as an option for Publish too, so it should be renamed to
// PublishOption when we perform the next major version bump to 2.x.x.
type PublishMultipleOption func(*publishMultipleOptions)

type publishMultipleOptions struct {
Expand Down
1 change: 0 additions & 1 deletion ablytest/proxies.go
Expand Up @@ -113,7 +113,6 @@ func MustAuthReverseProxy(opts ...ably.ClientOption) *AuthReverseProxy {
// - "token", which responds with (ably.TokenDetails).Token as a string
// - "details", which responds with ably.TokenDetails
// - "request", which responds with ably.TokenRequest
//
func (srv *AuthReverseProxy) URL(responseType string) string {
return "http://" + srv.Listener.Addr().String() + "/" + responseType
}
Expand Down
2 changes: 1 addition & 1 deletion go.mod
Expand Up @@ -3,7 +3,7 @@ module github.com/ably/ably-go
require (
github.com/stretchr/testify v1.7.1
github.com/ugorji/go/codec v1.1.9
golang.org/x/sys v0.0.0-20211019181941-9d821ace8654
golang.org/x/sys v0.2.0
nhooyr.io/websocket v1.8.7
)

Expand Down
4 changes: 2 additions & 2 deletions go.sum
Expand Up @@ -52,8 +52,8 @@ github.com/ugorji/go/codec v1.1.7/go.mod h1:Ax+UKWsSmolVDwsd+7N3ZtXu+yMGCf907BLY
github.com/ugorji/go/codec v1.1.9 h1:J/7hhpkQwgypRNvaeh/T5gzJ2gEI/l8S3qyRrdEa1fA=
github.com/ugorji/go/codec v1.1.9/go.mod h1:+SWgpdqOgdW5sBaiDfkHilQ1SxQ1hBkq/R+kHfL7Suo=
golang.org/x/sys v0.0.0-20200116001909-b77594299b42/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
golang.org/x/sys v0.0.0-20211019181941-9d821ace8654 h1:id054HUawV2/6IGm2IV8KZQjqtwAOo2CYlOToYqa0d0=
golang.org/x/sys v0.0.0-20211019181941-9d821ace8654/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg=
golang.org/x/sys v0.2.0 h1:ljd4t30dBnAvMZaQCevtY0xLLD0A+bRZXbgLMLU1F/A=
golang.org/x/sys v0.2.0/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg=
golang.org/x/text v0.3.2/go.mod h1:bEr9sfX3Q8Zfm5fL9x+3itogRgK3+ptLWKqgva+5dAk=
golang.org/x/time v0.0.0-20191024005414-555d28b269f0/go.mod h1:tRJNPiyCQ0inRvYxbN9jk5I+vvW/OXSQhTDSoE431IQ=
golang.org/x/tools v0.0.0-20180917221912-90fa682c2a6e/go.mod h1:n7NCudcB/nEzxVGmLbDWY5pfWTLqBcC2KZ6jyYvM4mQ=
Expand Down

0 comments on commit 6e1a824

Please sign in to comment.