Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions .github/workflows/cron-checks.yml
Original file line number Diff line number Diff line change
Expand Up @@ -41,8 +41,8 @@ jobs:
strategy:
matrix:
include:
- ios: 18.1
xcode: 16.1 # fails on 16.2
- ios: 18.2
xcode: 16.2
os: macos-15
device: "iPhone 16 Pro"
setup_runtime: false
Expand Down
2 changes: 0 additions & 2 deletions .github/workflows/smoke-checks.yml
Original file line number Diff line number Diff line change
Expand Up @@ -182,8 +182,6 @@ jobs:
- build-test-app-and-frameworks
env:
LAUNCH_ID: ${{ needs.allure_testops_launch.outputs.launch_id }}
XCODE_VERSION: "16.1" # fails on 16.2
IOS_SIMULATOR_DEVICE: "iPhone 16 Pro (18.1)"
strategy:
matrix:
batch: [0, 1]
Expand Down
15 changes: 14 additions & 1 deletion CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,19 @@ The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/).

### 🔄 Changed

# [4.75.0](https://github.com/GetStream/stream-chat-swift/releases/tag/4.75.0)
_March 26, 2025_

## StreamChat
### 🐞 Fixed
- Fix draft local attachments erased when the draft updated event is triggered [#3625](https://github.com/GetStream/stream-chat-swift/pull/3625)
- Fix background tasks not running in `IOSBackgroundTaskScheduler` sometimes [#3628](https://github.com/GetStream/stream-chat-swift/pull/3628)

### StreamChatUI
### 🐞 Fixed
- Fix composer content not cleared when draft deleted event is triggered [#3626](https://github.com/GetStream/stream-chat-swift/pull/3626)
- Set `ColorPalette.text` to `titleLabel` in `ChatChannelListItemView` [#3629](https://github.com/GetStream/stream-chat-swift/pull/3629)

# [4.74.0](https://github.com/GetStream/stream-chat-swift/releases/tag/4.74.0)
_March 14, 2025_

Expand All @@ -16,7 +29,7 @@ _March 14, 2025_
- Add `ChatChannelController.loadChannelReads()`,
- Add `ChatChannelController.loadMoreChannelReads()`
- Add `Chat.loadMembers()`
- Add `Chat.loadMoreMembers()
- Add `Chat.loadMoreMembers()`
### 🐞 Fixed
- Fix background task warning by making task tracking thread-safe [#3604](https://github.com/GetStream/stream-chat-swift/pull/3604)
- Fix an issue where `ChatRemoteNotificationHandler` can lead to persistent store's data inconsistencies [#3601](https://github.com/GetStream/stream-chat-swift/pull/3601)
Expand Down
2 changes: 1 addition & 1 deletion Gemfile.lock
Original file line number Diff line number Diff line change
Expand Up @@ -295,7 +295,7 @@ GEM
netrc (0.11.0)
nio4r (2.7.3)
nkf (0.2.0)
nokogiri (1.18.3)
nokogiri (1.18.4)
mini_portile2 (~> 2.8.2)
racc (~> 1.4)
octokit (9.1.0)
Expand Down
3 changes: 0 additions & 3 deletions Sources/StreamChat/Database/DTOs/MessageDTO.swift
Original file line number Diff line number Diff line change
Expand Up @@ -1134,9 +1134,6 @@ extension NSManagedObjectContext: MessageDatabaseSession {
throw ClientError.CurrentUserDoesNotExist()
}

// Delete existing draft message if it exists.
deleteDraftMessage(in: cid, threadId: payload.parentId)

let dto = MessageDTO.loadOrCreate(id: draftDetailsPayload.id, context: self, cache: cache)
dto.cid = cid.rawValue
dto.text = draftDetailsPayload.text
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -7,5 +7,5 @@ import Foundation

extension SystemEnvironment {
/// A Stream Chat version.
public static let version: String = "4.74.0"
public static let version: String = "4.75.0"
}
2 changes: 1 addition & 1 deletion Sources/StreamChat/Info.plist
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@
<key>CFBundlePackageType</key>
<string>$(PRODUCT_BUNDLE_PACKAGE_TYPE)</string>
<key>CFBundleShortVersionString</key>
<string>4.74.0</string>
<string>4.75.0</string>
<key>CFBundleVersion</key>
<string>$(CURRENT_PROJECT_VERSION)</string>
</dict>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ protocol BackgroundTaskScheduler {
import UIKit

class IOSBackgroundTaskScheduler: BackgroundTaskScheduler {
private let app: UIApplication? = {
private lazy var app: UIApplication? = {
// We can't use `UIApplication.shared` directly because there's no way to convince the compiler
// this code is accessible only for non-extension executables.
UIApplication.value(forKeyPath: "sharedApplication") as? UIApplication
Expand All @@ -35,7 +35,6 @@ class IOSBackgroundTaskScheduler: BackgroundTaskScheduler {
private let queue = DispatchQueue(label: "io.getstream.IOSBackgroundTaskScheduler", target: .global())

var isAppActive: Bool {
let app = self.app
if Thread.isMainThread {
return app?.applicationState == .active
}
Expand All @@ -44,7 +43,7 @@ class IOSBackgroundTaskScheduler: BackgroundTaskScheduler {
let group = DispatchGroup()
group.enter()
DispatchQueue.main.async {
isActive = app?.applicationState == .active
isActive = self.app?.applicationState == .active
group.leave()
}
group.wait()
Expand Down
7 changes: 6 additions & 1 deletion Sources/StreamChatUI/ChatChannel/ChatChannelVC.swift
Original file line number Diff line number Diff line change
Expand Up @@ -584,9 +584,14 @@ open class ChatChannelVC: _ViewController,

if let draftUpdatedEvent = event as? DraftUpdatedEvent,
let draft = channelController.channel?.draftMessage,
draftUpdatedEvent.cid == channelController.cid {
draftUpdatedEvent.cid == channelController.cid, draftUpdatedEvent.draftMessage.threadId == nil {
messageComposerVC.content.draftMessage(draft)
}

if let draftDeletedEvent = event as? DraftDeletedEvent,
draftDeletedEvent.cid == channelController.cid, draftDeletedEvent.threadId == nil {
messageComposerVC.content.clear()
}
}

// MARK: - AudioQueuePlayerDatasource
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -248,6 +248,7 @@ open class ChatChannelListItemView: _View, ThemeProvider, SwiftUIRepresentable {
super.setUpAppearance()
backgroundColor = contentBackgroundColor

titleLabel.textColor = appearance.colorPalette.text
titleLabel.font = appearance.fonts.bodyBold

subtitleLabel.textColor = appearance.colorPalette.subtitleText
Expand Down
2 changes: 2 additions & 0 deletions Sources/StreamChatUI/ChatThread/ChatThreadVC.swift
Original file line number Diff line number Diff line change
Expand Up @@ -493,6 +493,8 @@ open class ChatThreadVC: _ViewController,
if let draft = messageController.message?.draftReply {
messageComposerVC.content.draftMessage(draft)
}
case let event as DraftDeletedEvent where event.threadId == messageController.messageId:
messageComposerVC.content.clear()
default:
break
}
Expand Down
2 changes: 1 addition & 1 deletion Sources/StreamChatUI/Info.plist
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@
<key>CFBundlePackageType</key>
<string>$(PRODUCT_BUNDLE_PACKAGE_TYPE)</string>
<key>CFBundleShortVersionString</key>
<string>4.74.0</string>
<string>4.75.0</string>
<key>CFBundleVersion</key>
<string>$(CURRENT_PROJECT_VERSION)</string>
</dict>
Expand Down
2 changes: 1 addition & 1 deletion StreamChat-XCFramework.podspec
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
Pod::Spec.new do |spec|
spec.name = "StreamChat-XCFramework"
spec.version = "4.74.0"
spec.version = "4.75.0"
spec.summary = "StreamChat iOS Client"
spec.description = "stream-chat-swift is the official Swift client for Stream Chat, a service for building chat applications."

Expand Down
2 changes: 1 addition & 1 deletion StreamChat.podspec
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
Pod::Spec.new do |spec|
spec.name = "StreamChat"
spec.version = "4.74.0"
spec.version = "4.75.0"
spec.summary = "StreamChat iOS Chat Client"
spec.description = "stream-chat-swift is the official Swift client for Stream Chat, a service for building chat applications."

Expand Down
2 changes: 1 addition & 1 deletion StreamChatArtifacts.json

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion StreamChatUI-XCFramework.podspec
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
Pod::Spec.new do |spec|
spec.name = "StreamChatUI-XCFramework"
spec.version = "4.74.0"
spec.version = "4.75.0"
spec.summary = "StreamChat UI Components"
spec.description = "StreamChatUI SDK offers flexible UI components able to display data provided by StreamChat SDK."

Expand Down
2 changes: 1 addition & 1 deletion StreamChatUI.podspec
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
Pod::Spec.new do |spec|
spec.name = "StreamChatUI"
spec.version = "4.74.0"
spec.version = "4.75.0"
spec.summary = "StreamChat UI Components"
spec.description = "StreamChatUI SDK offers flexible UI components able to display data provided by StreamChat SDK."

Expand Down
9 changes: 9 additions & 0 deletions StreamChatUITestsAppUITests/Tests/Attachments_Tests.swift
Original file line number Diff line number Diff line change
Expand Up @@ -7,10 +7,19 @@ import XCTest
final class Attachments_Tests: StreamTestCase {

override func setUpWithError() throws {
try XCTSkipIf(ProcessInfo().operatingSystemVersion.majorVersion >= 18,
"Attachments tests freeze the test app on iOS > 18")

try super.setUpWithError()
addTags([.coreFeatures])
assertMockServer()
}

override func tearDownWithError() throws {
if ProcessInfo().operatingSystemVersion.majorVersion < 18 {
try super.tearDownWithError()
}
}

func test_uploadImage() throws {
linkToScenario(withId: 28)
Expand Down
Original file line number Diff line number Diff line change
@@ -1,11 +1,11 @@
{
"channel": {
"id": "cf770a2e-d32f-4be2-88f1-33ce7a478de1",
"id": "277d1327-0afd-4d76-87e8-fac1b3231ba7",
"type": "messaging",
"cid": "messaging:cf770a2e-d32f-4be2-88f1-33ce7a478de1",
"last_message_at": "2025-03-01T00:16:45.057386Z",
"created_at": "2025-03-01T00:16:42.426556Z",
"updated_at": "2025-03-01T00:16:42.426557Z",
"cid": "messaging:277d1327-0afd-4d76-87e8-fac1b3231ba7",
"last_message_at": "2025-03-15T00:15:56.802706Z",
"created_at": "2025-03-15T00:15:53.237136Z",
"updated_at": "2025-03-15T00:15:53.237137Z",
"created_by": {
"id": "luke_skywalker",
"name": "Luke Skywalker",
Expand All @@ -16,17 +16,17 @@

],
"created_at": "2024-04-04T09:26:11.805899Z",
"updated_at": "2025-02-28T04:46:37.3153Z",
"updated_at": "2025-03-04T17:42:53.930104Z",
"banned": false,
"online": true,
"last_active": "2025-03-01T00:16:41.464293451Z",
"last_active": "2025-03-15T00:15:52.376423417Z",
"blocked_user_ids": [

],
"team": "test",
"type": "team",
"pando": "{\"speciality\":\"ios engineer\"}",
"birthland": "Tatooine",
"team": "test"
"birthland": "Tatooine"
},
"frozen": false,
"disabled": false,
Expand Down Expand Up @@ -131,18 +131,18 @@

],
"created_at": "2024-04-22T06:42:08.562992Z",
"updated_at": "2024-07-11T05:45:57.296628Z",
"updated_at": "2025-03-03T10:00:37.133281Z",
"banned": false,
"online": false,
"last_active": "2025-02-27T16:18:01.645093Z",
"last_active": "2025-03-13T18:04:51.960419Z",
"blocked_user_ids": [

],
"birthland": "Serenno"
},
"status": "member",
"created_at": "2025-03-01T00:16:42.431151Z",
"updated_at": "2025-03-01T00:16:42.431151Z",
"created_at": "2025-03-15T00:15:53.24959Z",
"updated_at": "2025-03-15T00:15:53.24959Z",
"banned": false,
"shadow_banned": false,
"role": "member",
Expand All @@ -164,15 +164,15 @@
"updated_at": "2025-02-27T16:17:46.871132Z",
"banned": false,
"online": false,
"last_active": "2025-02-28T09:52:06.008333Z",
"last_active": "2025-03-14T17:10:33.441699Z",
"blocked_user_ids": [

],
"birthland": "Corellia"
},
"status": "member",
"created_at": "2025-03-01T00:16:42.431151Z",
"updated_at": "2025-03-01T00:16:42.431151Z",
"created_at": "2025-03-15T00:15:53.24959Z",
"updated_at": "2025-03-15T00:15:53.24959Z",
"banned": false,
"shadow_banned": false,
"role": "member",
Expand All @@ -191,21 +191,21 @@

],
"created_at": "2024-04-04T09:26:11.805899Z",
"updated_at": "2025-02-28T04:46:37.3153Z",
"updated_at": "2025-03-04T17:42:53.930104Z",
"banned": false,
"online": true,
"last_active": "2025-03-01T00:16:41.464293451Z",
"last_active": "2025-03-15T00:15:52.376423417Z",
"blocked_user_ids": [

],
"team": "test",
"type": "team",
"pando": "{\"speciality\":\"ios engineer\"}",
"birthland": "Tatooine"
"birthland": "Tatooine",
"team": "test"
},
"status": "member",
"created_at": "2025-03-01T00:16:42.431151Z",
"updated_at": "2025-03-01T00:16:42.431151Z",
"created_at": "2025-03-15T00:15:53.24959Z",
"updated_at": "2025-03-15T00:15:53.24959Z",
"banned": false,
"shadow_banned": false,
"role": "owner",
Expand All @@ -227,7 +227,7 @@
"updated_at": "2025-02-20T11:14:21.287666Z",
"banned": false,
"online": false,
"last_active": "2025-02-28T21:20:23.174867Z",
"last_active": "2025-03-14T13:17:25.910928Z",
"blocked_user_ids": [

],
Expand All @@ -242,14 +242,14 @@
"birthland": "Polis Massa"
},
"status": "member",
"created_at": "2025-03-01T00:16:46.375847Z",
"updated_at": "2025-03-01T00:16:46.375847Z",
"created_at": "2025-03-15T00:15:57.890803Z",
"updated_at": "2025-03-15T00:15:57.890803Z",
"banned": false,
"shadow_banned": false,
"role": "admin",
"channel_role": "channel_member",
"notifications_muted": false
}
],
"duration": "28.85ms"
"duration": "32.74ms"
}
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
{
"file": "https://frankfurt.stream-io-cdn.com/102399/images/9e6097e0-f574-4d57-9eab-31aef610d066.yoda.jpg?Key-Pair-Id=APKAIHG36VEWPDULE23Q&Policy=eyJTdGF0ZW1lbnQiOlt7IlJlc291cmNlIjoiaHR0cHM6Ly9mcmFua2Z1cnQuc3RyZWFtLWlvLWNkbi5jb20vMTAyMzk5L2ltYWdlcy85ZTYwOTdlMC1mNTc0LTRkNTctOWVhYi0zMWFlZjYxMGQwNjYueW9kYS5qcGc~Km9oPTAqb3c9MCoiLCJDb25kaXRpb24iOnsiRGF0ZUxlc3NUaGFuIjp7IkFXUzpFcG9jaFRpbWUiOjE3NDE5OTc4MDd9fX1dfQ__&Signature=Jz2m3g6uOkQi8W4t81i97eRab7EHAEDERys6CvVbcBYlxqoQQP3FYUY9-thG6OHE7BJJrG4AC9o2wFQNMVaPCXYzstiYterHzmswPo0MUYvV0JpB9tKfyqDm5qZf9eDfF-62AriloLgqt93dpbhqPdHt9BYzCFI0HrjA2Ji8eORB1y4UmJPrbZWaJynNTMwtY-moPXMrKQQeEFvBqghttPpy3ZI6sTGg-JwM8gkHE67YXkIpCh8F-S5NowT-Y58vC861cX0Crkk3XuU9zTXu1o79sTm6xaOarWzAfCeedCd~ivhPOXwRGVA8zO0TVoYrgsZQ69Tk8qA7Pojg1fMGNw__&oh=0&ow=0",
"duration": "150.53ms"
"file": "https://frankfurt.stream-io-cdn.com/102399/images/ca1d0939-dcfa-47ae-aff1-99f87ddb4b84.yoda.jpg?Key-Pair-Id=APKAIHG36VEWPDULE23Q&Policy=eyJTdGF0ZW1lbnQiOlt7IlJlc291cmNlIjoiaHR0cHM6Ly9mcmFua2Z1cnQuc3RyZWFtLWlvLWNkbi5jb20vMTAyMzk5L2ltYWdlcy9jYTFkMDkzOS1kY2ZhLTQ3YWUtYWZmMS05OWY4N2RkYjRiODQueW9kYS5qcGc~Km9oPTAqb3c9MCoiLCJDb25kaXRpb24iOnsiRGF0ZUxlc3NUaGFuIjp7IkFXUzpFcG9jaFRpbWUiOjE3NDMyMDczNTh9fX1dfQ__&Signature=K-hSpvlA9G2OfTEbJC9mqXsV1cofTi~zMlAqtGpaWaA44Ew~tKuL7GBY5s29fqLnBjFc8johfDexTNcKCdpg0bvAT197f66upZV0hzR1fGq1tlIm150olBUVKPLDX8FNKBB77S3dNfG6Pwcniv2wWYV85G5yFcP6Bka20B58laRarTtp32vSmq5BjEA7PIueiRR1dGFCykqJsl0-4M~NCLYhuGtqlb7Q5aT2GPrFT9hmf-vFYNNApfe90gZo3i1O6ZeLdF-PwfCqNUiHCvKehUtpjgVYwBqPJHoiPEOe1c018BLsC0JnKaCZQJofHIooLnwVz1skwCdu0NVytwVjSw__&oh=0&ow=0",
"duration": "137.68ms"
}
Loading
Loading