Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Release v5.2.6 #1122

Merged
merged 7 commits into from
Mar 25, 2024
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
40 changes: 20 additions & 20 deletions BookPlayer.xcodeproj/project.pbxproj
Original file line number Diff line number Diff line change
Expand Up @@ -3967,7 +3967,7 @@
"@executable_path/Frameworks",
"@executable_path/../../Frameworks",
);
MARKETING_VERSION = 5.2.5;
MARKETING_VERSION = 5.2.6;
MTL_ENABLE_DEBUG_INFO = INCLUDE_SOURCE;
MTL_FAST_MATH = YES;
PRODUCT_BUNDLE_IDENTIFIER = "$(BP_BUNDLE_IDENTIFIER).BookPlayerIntents";
Expand Down Expand Up @@ -4001,7 +4001,7 @@
"@executable_path/Frameworks",
"@executable_path/../../Frameworks",
);
MARKETING_VERSION = 5.2.5;
MARKETING_VERSION = 5.2.6;
MTL_FAST_MATH = YES;
PRODUCT_BUNDLE_IDENTIFIER = "$(BP_BUNDLE_IDENTIFIER).BookPlayerIntents";
PRODUCT_NAME = "$(TARGET_NAME)";
Expand Down Expand Up @@ -4033,7 +4033,7 @@
"@executable_path/Frameworks",
"@executable_path/../../Frameworks",
);
MARKETING_VERSION = 5.2.5;
MARKETING_VERSION = 5.2.6;
MTL_FAST_MATH = YES;
PRODUCT_BUNDLE_IDENTIFIER = "$(BP_BUNDLE_IDENTIFIER).BookPlayerIntents";
PRODUCT_NAME = "$(TARGET_NAME)";
Expand Down Expand Up @@ -4069,7 +4069,7 @@
"@executable_path/Frameworks",
"@executable_path/../../Frameworks",
);
MARKETING_VERSION = 5.2.5;
MARKETING_VERSION = 5.2.6;
MTL_ENABLE_DEBUG_INFO = INCLUDE_SOURCE;
MTL_FAST_MATH = YES;
PRODUCT_BUNDLE_IDENTIFIER = "$(BP_BUNDLE_IDENTIFIER).watchkitapp";
Expand Down Expand Up @@ -4110,7 +4110,7 @@
"@executable_path/Frameworks",
"@executable_path/../../Frameworks",
);
MARKETING_VERSION = 5.2.5;
MARKETING_VERSION = 5.2.6;
MTL_FAST_MATH = YES;
PRODUCT_BUNDLE_IDENTIFIER = "$(BP_BUNDLE_IDENTIFIER).watchkitapp";
PRODUCT_NAME = "$(TARGET_NAME)";
Expand Down Expand Up @@ -4148,7 +4148,7 @@
"@executable_path/Frameworks",
"@executable_path/../../Frameworks",
);
MARKETING_VERSION = 5.2.5;
MARKETING_VERSION = 5.2.6;
MTL_FAST_MATH = YES;
PRODUCT_BUNDLE_IDENTIFIER = "$(BP_BUNDLE_IDENTIFIER).watchkitapp";
PRODUCT_NAME = "$(TARGET_NAME)";
Expand Down Expand Up @@ -4317,7 +4317,7 @@
"@executable_path/Frameworks",
"@executable_path/../../Frameworks",
);
MARKETING_VERSION = 5.2.5;
MARKETING_VERSION = 5.2.6;
MTL_ENABLE_DEBUG_INFO = INCLUDE_SOURCE;
MTL_FAST_MATH = YES;
PRODUCT_BUNDLE_IDENTIFIER = "$(BP_BUNDLE_IDENTIFIER).BookPlayerWidgetUI";
Expand Down Expand Up @@ -4355,7 +4355,7 @@
"@executable_path/Frameworks",
"@executable_path/../../Frameworks",
);
MARKETING_VERSION = 5.2.5;
MARKETING_VERSION = 5.2.6;
MTL_FAST_MATH = YES;
PRODUCT_BUNDLE_IDENTIFIER = "$(BP_BUNDLE_IDENTIFIER).BookPlayerWidgetUI";
PRODUCT_NAME = "$(TARGET_NAME)";
Expand Down Expand Up @@ -4391,7 +4391,7 @@
"@executable_path/Frameworks",
"@executable_path/../../Frameworks",
);
MARKETING_VERSION = 5.2.5;
MARKETING_VERSION = 5.2.6;
MTL_FAST_MATH = YES;
PRODUCT_BUNDLE_IDENTIFIER = "$(BP_BUNDLE_IDENTIFIER).BookPlayerWidgetUI";
PRODUCT_NAME = "$(TARGET_NAME)";
Expand Down Expand Up @@ -4544,7 +4544,7 @@
"$(inherited)",
"@executable_path/Frameworks",
);
MARKETING_VERSION = 5.2.5;
MARKETING_VERSION = 5.2.6;
PRODUCT_BUNDLE_IDENTIFIER = "$(BP_BUNDLE_IDENTIFIER)";
PRODUCT_NAME = BookPlayer;
PROVISIONING_PROFILE_SPECIFIER = "$(BP_PROVISIONING_MAIN)";
Expand Down Expand Up @@ -4582,7 +4582,7 @@
"$(inherited)",
"@executable_path/Frameworks",
);
MARKETING_VERSION = 5.2.5;
MARKETING_VERSION = 5.2.6;
PRODUCT_BUNDLE_IDENTIFIER = "$(BP_BUNDLE_IDENTIFIER)";
PRODUCT_NAME = BookPlayer;
PROVISIONING_PROFILE_SPECIFIER = "$(BP_PROVISIONING_MAIN)";
Expand Down Expand Up @@ -4804,7 +4804,7 @@
"@executable_path/Frameworks",
"@executable_path/../../Frameworks",
);
MARKETING_VERSION = 5.2.5;
MARKETING_VERSION = 5.2.6;
MTL_ENABLE_DEBUG_INFO = INCLUDE_SOURCE;
MTL_FAST_MATH = YES;
PRODUCT_BUNDLE_IDENTIFIER = "$(BP_BUNDLE_IDENTIFIER).watchkitapp.widgets";
Expand Down Expand Up @@ -4842,7 +4842,7 @@
"@executable_path/Frameworks",
"@executable_path/../../Frameworks",
);
MARKETING_VERSION = 5.2.5;
MARKETING_VERSION = 5.2.6;
MTL_FAST_MATH = YES;
PRODUCT_BUNDLE_IDENTIFIER = "$(BP_BUNDLE_IDENTIFIER).watchkitapp.widgets";
PRODUCT_NAME = "$(TARGET_NAME)";
Expand Down Expand Up @@ -4878,7 +4878,7 @@
"@executable_path/Frameworks",
"@executable_path/../../Frameworks",
);
MARKETING_VERSION = 5.2.5;
MARKETING_VERSION = 5.2.6;
MTL_FAST_MATH = YES;
PRODUCT_BUNDLE_IDENTIFIER = "$(BP_BUNDLE_IDENTIFIER).watchkitapp.widgets";
PRODUCT_NAME = "$(TARGET_NAME)";
Expand Down Expand Up @@ -4917,7 +4917,7 @@
"@executable_path/Frameworks",
"@executable_path/../../Frameworks",
);
MARKETING_VERSION = 5.2.5;
MARKETING_VERSION = 5.2.6;
MTL_ENABLE_DEBUG_INFO = INCLUDE_SOURCE;
MTL_FAST_MATH = YES;
PRODUCT_BUNDLE_IDENTIFIER = "$(BP_BUNDLE_IDENTIFIER).BookPlayerShareExtension";
Expand Down Expand Up @@ -4957,7 +4957,7 @@
"@executable_path/Frameworks",
"@executable_path/../../Frameworks",
);
MARKETING_VERSION = 5.2.5;
MARKETING_VERSION = 5.2.6;
MTL_FAST_MATH = YES;
PRODUCT_BUNDLE_IDENTIFIER = "$(BP_BUNDLE_IDENTIFIER).BookPlayerShareExtension";
PRODUCT_NAME = "$(TARGET_NAME)";
Expand Down Expand Up @@ -4995,7 +4995,7 @@
"@executable_path/Frameworks",
"@executable_path/../../Frameworks",
);
MARKETING_VERSION = 5.2.5;
MARKETING_VERSION = 5.2.6;
MTL_FAST_MATH = YES;
PRODUCT_BUNDLE_IDENTIFIER = "$(BP_BUNDLE_IDENTIFIER).BookPlayerShareExtension";
PRODUCT_NAME = "$(TARGET_NAME)";
Expand Down Expand Up @@ -5087,7 +5087,7 @@
"$(inherited)",
"@executable_path/Frameworks",
);
MARKETING_VERSION = 5.2.5;
MARKETING_VERSION = 5.2.6;
PRODUCT_BUNDLE_IDENTIFIER = "$(BP_BUNDLE_IDENTIFIER)";
PRODUCT_NAME = BookPlayer;
PROVISIONING_PROFILE_SPECIFIER = "$(BP_PROVISIONING_MAIN)";
Expand Down Expand Up @@ -5278,7 +5278,7 @@
repositoryURL = "https://github.com/getsentry/sentry-cocoa.git";
requirement = {
kind = exactVersion;
version = 8.7.3;
version = 8.21.0;
};
};
41F1A214254B0AA40043FCF3 /* XCRemoteSwiftPackageReference "Kingfisher" */ = {
Expand Down Expand Up @@ -5310,7 +5310,7 @@
repositoryURL = "https://github.com/RevenueCat/purchases-ios.git";
requirement = {
kind = upToNextMajorVersion;
minimumVersion = 4.0.0;
minimumVersion = 4.38.0;
};
};
/* End XCRemoteSwiftPackageReference section */
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -50,8 +50,8 @@
"kind" : "remoteSourceControl",
"location" : "https://github.com/RevenueCat/purchases-ios.git",
"state" : {
"revision" : "ff4907a2b01fb6e0e891f36e9a14421a5500cc04",
"version" : "4.31.9"
"revision" : "022748f79384035c0752602300e4e112018cd9c9",
"version" : "4.38.1"
}
},
{
Expand All @@ -77,8 +77,8 @@
"kind" : "remoteSourceControl",
"location" : "https://github.com/getsentry/sentry-cocoa.git",
"state" : {
"revision" : "9cf7d2e514af1600cc2b3c5592e2848c6c5a76d6",
"version" : "8.7.3"
"revision" : "38f4f70d07117b9f958a76b1bff278c2f29ffe0e",
"version" : "8.21.0"
}
},
{
Expand Down
1 change: 1 addition & 0 deletions BookPlayer/AppDelegate.swift
Original file line number Diff line number Diff line change
Expand Up @@ -451,6 +451,7 @@ class AppDelegate: UIResponder, UIApplicationDelegate, BPLogger {
options.debug = false
options.enableCoreDataTracing = false
options.enableFileIOTracing = false
options.enableAppHangTracking = false
options.tracesSampleRate = 0.5
}
}
Expand Down
24 changes: 14 additions & 10 deletions BookPlayer/Coordinators/DataInitializerCoordinator.swift
Original file line number Diff line number Diff line change
Expand Up @@ -36,11 +36,13 @@ class DataInitializerCoordinator: BPLogger {
|| error.code == NSFileWriteOutOfSpaceError
) {
// CoreData may fail if device doesn't have space
alertPresenter.showAlert(
"error_title".localized,
message: "coredata_error_diskfull_description".localized,
completion: nil
)
await MainActor.run {
alertPresenter.showAlert(
"error_title".localized,
message: "coredata_error_diskfull_description".localized,
completion: nil
)
}
} catch let error as NSError where (
error.code == NSMigrationError ||
error.code == NSMigrationConstraintViolationError ||
Expand All @@ -55,11 +57,13 @@ class DataInitializerCoordinator: BPLogger {
) {
// TODO: We can handle `isRecoveryAttempt` to show a different error message
Self.logger.warning("Failed to perform migration, attempting recovery with the loading library sequence")
alertPresenter.showAlert(
"error_title".localized,
message: "coredata_error_migration_description".localized
) { [unowned self] in
recoverLibraryFromFailedMigration()
await MainActor.run {
alertPresenter.showAlert(
"error_title".localized,
message: "coredata_error_migration_description".localized
) { [unowned self] in
recoverLibraryFromFailedMigration()
}
}
} catch {
let error = error as NSError
Expand Down
8 changes: 8 additions & 0 deletions BookPlayer/Coordinators/LibraryListCoordinator.swift
Original file line number Diff line number Diff line change
Expand Up @@ -85,6 +85,7 @@ class LibraryListCoordinator: ItemListCoordinator, UINavigationControllerDelegat
loadLastBookIfNeeded()
syncList()
bindImportObserverIfNeeded()
bindDownloadErrorObserver()

if let appDelegate = AppDelegate.shared {
for action in appDelegate.pendingURLActions {
Expand Down Expand Up @@ -136,6 +137,13 @@ class LibraryListCoordinator: ItemListCoordinator, UINavigationControllerDelegat
notifyPendingFiles()
}

func bindDownloadErrorObserver() {
syncService.downloadErrorPublisher.sink { (relativePath, error) in
self.showAlert("network_error_title".localized, message: "\(relativePath)\n\(error.localizedDescription)")
}
.store(in: &disposeBag)
}

@MainActor
func notifyPendingFiles() {
// Get reference of all the files located inside the Documents, Shared and Inbox folders
Expand Down
5 changes: 5 additions & 0 deletions BookPlayer/Generated/AutoMockable.generated.swift
Original file line number Diff line number Diff line change
Expand Up @@ -1414,6 +1414,11 @@ class SyncServiceProtocolMock: SyncServiceProtocol {
set(value) { underlyingDownloadProgressPublisher = value }
}
var underlyingDownloadProgressPublisher: PassthroughSubject<(String, String, String?, Double), Never>!
var downloadErrorPublisher: PassthroughSubject<(String, Error), Never> {
get { return underlyingDownloadErrorPublisher }
set(value) { underlyingDownloadErrorPublisher = value }
}
var underlyingDownloadErrorPublisher: PassthroughSubject<(String, Error), Never>!
//MARK: - queuedJobsCount

var queuedJobsCountCallsCount = 0
Expand Down
12 changes: 6 additions & 6 deletions BookPlayer/Library/ItemList Screen/ItemListViewModel.swift
Original file line number Diff line number Diff line change
Expand Up @@ -211,12 +211,12 @@ class ItemListViewModel: ViewModelProtocol {
))
}

singleDownloadProgressDelegateInterface.didFinishDownloadingTask = { [weak self] (task, fileURL) in
self?.handleSingleDownloadTaskFinished(task, fileURL: fileURL)
}

singleDownloadProgressDelegateInterface.didFinishTaskWithError = { [weak self] (task, error) in
self?.handleSingleDownloadTaskFinishedWithError(task, error: error)
singleDownloadProgressDelegateInterface.didFinishDownloadingTask = { [weak self] (task, fileURL, error) in
if let error {
self?.handleSingleDownloadTaskFinishedWithError(task, error: error)
} else if let fileURL {
self?.handleSingleDownloadTaskFinished(task, fileURL: fileURL)
}
}
}

Expand Down
Loading