Skip to content

Tags: viktar-iosdev/connect-swift

Tags

0.11.0

Toggle 0.11.0's commit message

Verified

This commit was created on GitHub.com and signed with GitHub’s verified signature. The key has expired.
Update CI to Xcode 15.1 & run builds for iOS, watchOS, tvOS (connectr…

…pc#231)

- Adds new CI jobs to build the library against macOS, iOS, tvOS, and
watchOS rather than only the default environment (macOS)
- Updates `@available` annotations to properly accommodate these
additional platforms
- Updates CI to use Xcode 15.1

Originally the intent was to run tests on each platform, but for some
reason GitHub runners are refusing to cooperate and jobs are stalling.
Instead, we'll continue running `swift test` which runs tests on the
host environment (macOS) and will use `xcodebuild` to build for each
platform since it allows for specifying a target SDK/environment (see
[this
question](https://stackoverflow.com/questions/60245159/how-can-i-build-a-swift-package-for-ios-over-command-line)
and [these
notes](https://www.jessesquires.com/blog/2021/11/03/swift-package-ios-tests/)).

Follow-up to connectrpc#227 and
related to connectrpc#226.

0.10.1

Toggle 0.10.1's commit message

Verified

This commit was created on GitHub.com and signed with GitHub’s verified signature. The key has expired.
Update CI release job to use Xcode 15 (connectrpc#216)

Without this, the release job fails because the `Package.swift` requires
a Swift version higher than the GitHub runner's default.

0.10.0

Toggle 0.10.0's commit message

Verified

This commit was created on GitHub.com and signed with GitHub’s verified signature. The key has expired.
Reorganize project files & reduce public interface (connectrpc#212)

Reorganizes files in the project to be more clearly and consistently
organized by visibility (whether the types within each file should be
internal to the package or public). Also reduces the public interface of
the module by moving some types to `internal` or `package`.

Note that `package` is specific to SPM, so the keyword cannot be used in
conjunction with CocoaPods. For this reason, a few of the types are
guarded with `#if COCOAPODS`. It's also worth noting that `ConnectNIO`
cannot be consumed via CocoaPods today because NIO does not support
CocoaPods. For this reason, the shared gRPC interfaces between `Connect`
and `ConnectNIO` don't need to be exposed to CocoaPods at all.
Additionally, [`package` requires Swift
5.9](https://github.com/apple/swift-evolution/blob/main/proposals/0386-package-access-modifier.md),
so the Swift package version has been updated as well.

New directory structure:

```
.
├── Examples
│   ├── ElizaCocoaPodsApp
│   ├── ElizaSharedSources
│   │   ├── AppSources
│   │   └── GeneratedSources
│   │       └── connectrpc
│   │           └── eliza
│   │               └── v1
│   └── ElizaSwiftPackageApp
│       └── ElizaSwiftPackageApp
├── Libraries
│   ├── Connect
│   │   ├── Internal
│   │   │   ├── Generated
│   │   │   │   └── grpc
│   │   │   │       └── status
│   │   │   │           └── v1
│   │   │   ├── Interceptors
│   │   │   ├── Locks
│   │   │   ├── Streaming
│   │   │   └── Unary
│   │   ├── PackageInternal
│   │   ├── Public
│   │   │   ├── Implementation
│   │   │   │   ├── Clients
│   │   │   │   ├── Codecs
│   │   │   │   └── Compression
│   │   │   └── Interfaces
│   │   │       ├── Interceptors
│   │   │       └── Streaming
│   │   │           ├── AsyncAwait
│   │   │           └── Callbacks
│   │   └── proto
│   │       └── grpc
│   │           └── status
│   │               └── v1
│   ├── ConnectMocks
│   └── ConnectNIO
│       ├── Internal
│       │   └── Extensions
│       └── Public
├── Plugins
│   ├── ConnectMocksPlugin
│   ├── ConnectPluginUtilities
│   └── ConnectSwiftPlugin
└── Tests
    ├── ConnectLibraryTests
    │   ├── ConnectConformance
    │   ├── ConnectMocksTests
    │   ├── ConnectTests
    │   ├── Generated
    │   │   ├── connectrpc
    │   │   │   └── conformance
    │   │   │       └── v1
    │   │   └── server
    │   │       └── v1
    │   └── TestResources
    └── ConnectPluginUtilitiesTests
```

0.9.0

Toggle 0.9.0's commit message

Verified

This commit was created on GitHub.com and signed with GitHub’s verified signature. The key has expired.
Update interceptor docs (connectrpc#200)

Updating inline docs to reflect
connectrpc/connectrpc.com#68.

0.8.0

Toggle 0.8.0's commit message

Verified

This commit was created on GitHub.com and signed with GitHub’s verified signature. The key has expired.
Handle `grpc-status` in headers rather than only trailers (connectrpc…

…#174)

"Trailers-only" responses can actually be just headers, in which case we
should read `grpc-status` from them.

This PR:
- Updates the logic for both unary and streaming APIs to properly handle
cases where "trailers-only" responses are returned using the headers
block
- Updates the conformance test suite to test against grpc-go in addition
to connect-go in order to catch this case. (grpc-go returns
"trailers-only" responses in headers, and connect-go returns them in
trailers)

Here's the new logic for gRPC:
- If non-HTTP 200, report an invalid response
- If no body data, assume "trailers-only"
  - Look for the gRPC status and error details in the headers
  - Look for the gRPC status and error details in the trailers
  - If the status is an error, don't process the body

Resolves connectrpc#168.

0.7.0

Toggle 0.7.0's commit message

Verified

This commit was created on GitHub.com and signed with GitHub’s verified signature. The key has expired.
Add concurrency annotations to fix strict compilation warnings (conne…

…ctrpc#155)

This contains fixes for warnings that appear by enabling Swift strict
concurrency in the Xcode 15 beta:

```
swiftSettings: [.unsafeFlags(["-Xfrontend", "-strict-concurrency=complete"])]
```

0.6.0

Toggle 0.6.0's commit message

Verified

This commit was created on GitHub.com and signed with GitHub’s verified signature. The key has expired.
Add assertion when using gRPC with URLSession (connectrpc#138)

Add a debug assertion failure that will trigger when the
`URLSessionHTTPClient` is used with gRPC to make it more apparent as to
why some "successful" responses are still invalid.

For context, URLSession does not support trailers and is thus
incompatible with gRPC.

0.5.0

Toggle 0.5.0's commit message

Verified

This commit was created on GitHub.com and signed with GitHub’s verified signature. The key has expired.
Update gRPC and gRPC-Web links (connectrpc#123)

0.4.0

Toggle 0.4.0's commit message

Verified

This commit was created on GitHub.com and signed with GitHub’s verified signature. The key has expired.
Allow building on iOS 12 (connectrpc#100)

The necessary async/await APIs are only available on iOS 13+, so code
generated using the `GenerateAsyncMethods=true` option will be
unavailable on iOS 12.

0.3.0

Toggle 0.3.0's commit message

Verified

This commit was created on GitHub.com and signed with GitHub’s verified signature. The key has expired.
Replace `ClientOption` with struct-based config (connectrpc#92)

This PR replaces the `ClientOption` interface and all its conformers
with a new struct-based configuration. This has several benefits:
- Enforces that exactly one protocol implementation (Connect or
gRPC-Web) is specified at compile-time. Prior, any number could be
specified and would cause invalid requests to be serialized
- Enforces that either both the minimum compression size threshold and
compression pool are specified for requests, or neither
- Clearer default values (defaults can be seen simply by looking at
`ProtocolClientConfig.init`)
- Removes the need for some types like `IdentityCompressionPool`

The original approach was taken to more clearly mirror Go, but this new
implementation is better for Swift.