Skip to content

Releases: swhitty/swift-timeout

0.4.0 Swift 6.2

31 Oct 23:28
89f4442

Choose a tag to compare

What's Changed

  • Support Swift 6.2 by @swhitty in #8
  • Removes Swift 5 support
  • use nonisolated(nonsending) in Swift 6.2 by @swhitty in #10

Full Changelog: 0.3.1...0.4.0

0.3.1 struct Timeout -> TimeoutController

09 Jun 21:55
da7999b

Choose a tag to compare

What's Changed

  • Renames struct Timeout -> TimeoutController by @swhitty in #7

Full Changelog: 0.3.0...0.3.1

0.3.0 AsyncTimeoutSequence

03 Jun 08:00
3767380

Choose a tag to compare

What's Changed

Full Changelog: 0.2.1...0.3.0

Rename swift-timeout

08 Sep 21:49
f649c4e

Choose a tag to compare

Renames package to swift-timeout you must now import Timeout.

Adds deadline when Clock is available:

import Timeout

let val = try await withThrowingTimeout(after: .now + .seconds(2)) {
  try await perform()
}

Rename swift-timeout

08 Sep 10:12
df40fd6

Choose a tag to compare

Renames package to swift-timeout you must now import Timeout.

Adds deadline when Clock is available:

import Timeout

let val = try await withThrowingTimeout(after: .now + .seconds(2)) {
  try await perform()
}

Initial Release

01 Sep 08:24
17051a9

Choose a tag to compare

Usage is similar to using task groups:

let val = try await withThrowingTimeout(seconds: 1.5) {
  try await perform()
}

The provided closure is performed within a child task. If the timeout expires before a value is returned the task is cancelled and TimeoutError is thrown.