Commit Graph

101 Commits

Author SHA1 Message Date
Morgan Pretty 06f12a58b0 Change the 'Grant Camera Access' copy to 'Continue' at Apple's request
Updated translations again
2023-10-04 10:52:40 +11:00
Morgan Pretty f9dc85b7ab Fixed a couple of onboarding bugs and tweaks some logs
Fixed an issue where starting and then restarting onboarding would get the app into an invalid state
Fixed an issue where newline characters could cause issues with parsing the recovery phrase
Added additional logs to better be able to understand the database state
2023-10-02 12:59:52 +11:00
Morgan Pretty 5917cf103f Refactored the LintLocalizableStrings
Added inline errors & warnings (regex could use some work to remove invalid cases)
Added a build step to validate the strings are included in the app and it's extensions
2023-09-25 18:32:56 +10:00
Morgan Pretty 32527d7e83
Merge pull request #856 from mpretty-cyro/feature/updated-push-server
Updated Push Notification API Integration
2023-08-11 18:02:20 +10:00
Morgan Pretty 5285d81177 Fixed a few more PN logic issues
Sorted out some more threading issues
Removed a redundant SyncPushTokensJob run
Fixed an issue where the NotificationServiceExtension could incorrectly setup the database before setting up it's context
Fixed a few warnings
Removed a bunch of legacy code
Refactored the MainAppContext from Objective C into Swift
2023-08-10 14:43:40 +10:00
Morgan Pretty 0e952b40bb Removed 'useSharedUtilForUserConfig' flag and most legacy config logic 2023-08-03 09:09:33 +10:00
Morgan Pretty b471a32209 Merge remote-tracking branch 'upstream/dev' into feature/job-runner-unit-tests
# Conflicts:
#	Session/Conversations/ConversationVC+Interaction.swift
#	SessionMessagingKit/Open Groups/OpenGroupAPI.swift
#	SessionMessagingKit/Open Groups/OpenGroupManager.swift
2023-08-01 14:39:00 +10:00
Morgan Pretty a41f1c1366 Fixed the broken tests
Cleaned up the Dependencies so that tests can run synchronously without having to custom set queues as much
Sorted out the crypto and network dependencies to avoid needing weird dependency inheritance
Fixed the flaky tests so they are no longer flaky
Fixed some unexpected JobRunner behaviours
Updated the CI config to use a local build directory for derivedData (now works with build tweaks)
2023-08-01 14:27:41 +10:00
Morgan Pretty f373a989a8 Fixes for user config crashes
Added a method to determine if the database is suspended
Updated the code to show the "Failed" state if sending a message fails due to a suspended database
Prevented a crash which could occur in rare cases when accessing the Seed via the home screen prompt (direct user to share logs with session - db locked or device in an invalid state)
Prevented a crash which could occur when trying to send a message due to failing to retrieve the mnemonic (db locked or device in an invalid state)
Fixed a bug where optimistic messages could end up appearing multiple times
Fixed a crash with the QRCode scanner
Fixed a crash when trying to take a video attachment
Fixed a crash where the image picker grid could go out of bounds when selecting elements
Fixed a crash which could occur when a user provides a recovery password with a word that contains less than 3 characters
Fixed a potential issue where the dependency injection could result in a stale date being used in some places (removing the DI here, proper fix requires larger changes in another branch)
2023-07-20 12:29:56 +10:00
Morgan Pretty c7f6b5a94e Replaced the 'ZXingObjC' dependency with a native implementation for scanning QR Codes 2023-07-12 17:13:59 +10:00
Morgan Pretty d0be7f786c Fixed a hang, removed redundant libs, files and code
Fixed an issue where returning the app from the background would result in the app staying permanently on the splash screen
Included a CRC32 implementation so we can drop the CryptoSwift dependenciy (using CryptoKit everywhere else)
Removed 'SocketRocket' (unused)
Removed the `xcode_14_3_workaround` post-install hook (fixed with CocoaPods 1.12.1)
Removed the `enable_fts5_support` post-install hook (enabled by default since GRDB 6.7.0 so redundant)
Removed the `enable_whole_module_optimization_for_crypto_swift` post-install hook (dropped CryptoSwift support)
Cleared out a bunch of headers from the Signal-Bridging-header file (direct imports instead to reduce incremental build sizes)
Deleted some unused code
2023-06-29 16:58:23 +10:00
Morgan Pretty b6328f79b9 Reworked the app startup process
Shifted the initial HomeVC population to a background thread to avoid blocking launch processing
Added some logging for database 'ABORT' errors to better identify cases of deadlocks
Added a launch timeout modal to allow users to share their logs if the startup process happens to hang
Updated the notification handling (and cancelling) so it could run on background threads (seemed to take up a decent chunk of main thread time)
Fixed an issue where the IP2Country population was running sync which could cause a hang on startup
Fixed an issue where the code checking if the UIPasteBoard contained an image was explicitly advised against by the documentation (caused some reported hangs)
Fixed a hang which could be caused by a redundant function when the ImagePickerController appeared
2023-06-27 18:01:00 +10:00
Morgan Pretty 53a5db0ea5 Fixed a number of issues found during internal testing
Added copy for an unrecoverable startup case
Added some additional logs to better debug ValueObservation query errors
Increased the pageSize to 20 on iPad devices (to prevent it immediately loading a second page)
Cleaned up a bunch of threading logic (try to avoid overriding subscribe/receive threads specified at subscription)
Consolidated the 'sendMessage' and 'sendAttachments' functions
Updated the various frameworks to use 'DAWRF with DSYM' to allow for better debugging during debug mode (at the cost of a longer build time)
Updated the logic to optimistically insert messages when sending to avoid any database write delays
Updated the logic to avoid sending notifications for messages which are already marked as read by the config
Fixed an issue where multiple paths could incorrectly get built at the same time in some cases
Fixed an issue where other job queues could be started before the blockingQueue finishes
Fixed a potential bug with the snode version comparison (was just a string comparison which would fail when getting to double-digit values)
Fixed a bug where you couldn't remove the last reaction on a message
Fixed the broken media message zoom animations
Fixed a bug where the last message read in a conversation wouldn't be correctly detected as already read
Fixed a bug where the QuoteView had no line limits (resulting in the '@You' mention background highlight being incorrectly positioned in the quote preview)
Fixed a bug where a large number of configSyncJobs could be scheduled (only one would run at a time but this could result in performance impacts)
2023-06-23 17:54:29 +10:00
Morgan Pretty c455a13a7b Finished adding logic to ignore messages invalidated by config
Added timestamps to the Profile table to avoid overriding current profile info with older info
Updated the MessageReceiver to ignore the rest of the messages invalidated by the config
Updated to the latest libSession
Updated the JobRunner to expose some more info about the currently running jobs
Made some tweaks to the ConfigurationSyncJob to better support concurrent jobs running for different targets
2023-05-31 14:30:33 +10:00
Morgan Pretty 3f362a71f3 Fixed a couple of QA issues
Forced the user config feature to be on (for testing)
Fixed a bug where triggering the 'Delete for everyone' functionality would incorrectly try to delete from the recipient swarm (not possible)
Fixed a bug where the 'profileNamePublisher' could only be set once resulting in potential issues if you try to restore different accounts within the same session
Re-added the limit to the number of reactions to display before collapsing to make it consistent with the designs and other platforms
Updated the SnodeAPI to ensure that when it retries it will actually select a new snode
2023-05-23 09:42:10 +10:00
Morgan Pretty 534343f8b0 Merge remote-tracking branch 'upstream/dev' into feature/updated-user-config-handling
# Conflicts:
#	Session/Closed Groups/NewClosedGroupVC.swift
#	Session/Conversations/ConversationVC+Interaction.swift
#	Session/Conversations/ConversationVC.swift
#	Session/Conversations/ConversationViewModel.swift
#	Session/Conversations/Settings/ThreadSettingsViewModel.swift
#	Session/Home/GlobalSearch/GlobalSearchViewController.swift
#	Session/Home/HomeVC.swift
#	Session/Home/New Conversation/NewDMVC.swift
#	Session/Media Viewing & Editing/GIFs/GifPickerViewController.swift
#	Session/Meta/Translations/de.lproj/Localizable.strings
#	Session/Meta/Translations/en.lproj/Localizable.strings
#	Session/Meta/Translations/es.lproj/Localizable.strings
#	Session/Meta/Translations/fa.lproj/Localizable.strings
#	Session/Meta/Translations/fi.lproj/Localizable.strings
#	Session/Meta/Translations/fr.lproj/Localizable.strings
#	Session/Meta/Translations/hi.lproj/Localizable.strings
#	Session/Meta/Translations/hr.lproj/Localizable.strings
#	Session/Meta/Translations/id-ID.lproj/Localizable.strings
#	Session/Meta/Translations/it.lproj/Localizable.strings
#	Session/Meta/Translations/ja.lproj/Localizable.strings
#	Session/Meta/Translations/nl.lproj/Localizable.strings
#	Session/Meta/Translations/pl.lproj/Localizable.strings
#	Session/Meta/Translations/pt_BR.lproj/Localizable.strings
#	Session/Meta/Translations/ru.lproj/Localizable.strings
#	Session/Meta/Translations/si.lproj/Localizable.strings
#	Session/Meta/Translations/sk.lproj/Localizable.strings
#	Session/Meta/Translations/sv.lproj/Localizable.strings
#	Session/Meta/Translations/th.lproj/Localizable.strings
#	Session/Meta/Translations/vi-VN.lproj/Localizable.strings
#	Session/Meta/Translations/zh-Hant.lproj/Localizable.strings
#	Session/Meta/Translations/zh_CN.lproj/Localizable.strings
#	Session/Settings/BlockedContactsViewController.swift
#	Session/Settings/NukeDataModal.swift
#	Session/Settings/SettingsViewModel.swift
#	SessionMessagingKit/Shared Models/SessionThreadViewModel.swift
#	SessionUIKit/Components/ConfirmationModal.swift
2023-05-18 17:34:25 +10:00
Morgan Pretty 9c8653aa21 Updated the profile picture management UI
Updated the UI to use a modal
Added the ability to remove the profile picture
2023-05-16 13:09:05 +10:00
Morgan Pretty 6fd574916b Fixed a few bugs and build libSession-util from source
Added libSession-util as a submodule and wired into build
Updated the logic to run migrations when returning from the background as well (since we will have feature-flag controlled migrations it's possible for a "new" migration to become available at this point)
Fixed an issue where the 'Note to Self' conversation could appear when linking a device for a new user
Fixed an issue where the app would process the ConfigSyncJob before completing onboarding
2023-04-21 16:34:06 +10:00
Morgan Pretty 8c8453d922 Updated to the latest libSession, fixed remaining items
Updated to the latest libSession version
Updated the 'hidden' logic to be based on a negative 'priority' value
Added an index on the Quote table to speed up conversation query
Fixed an odd behaviour with GRDB and Combine (simplified the interface as well)
Fixed an issue where migrations could fail
2023-04-14 12:39:18 +10:00
Morgan Pretty 66fd2d4ff8 Finished off a few remaining bits and pieces
Added the 'outdated client' warning banner
Added a unit test to validate the 'group(by:)' method maintains ordering
Added an error when trying to message a non-standard session id directly
Removed the "hide" logic for groups (don't want it)
Removed some unneeded thread fetching
Updated the logic to use the 'lastHash' when fetching config messages
Updated the logic to use the libSession value restrictions instead of hard-coded values
Fixed an issue where members weren't getting removed from legacy groups
2023-03-08 17:27:07 +11:00
Morgan Pretty 7d47a36f9f Merge remote-tracking branch 'upstream/dev' into feature/updated-user-config-handling
# Conflicts:
#	Session/Conversations/ConversationVC+Interaction.swift
#	Session/Conversations/Settings/ThreadSettingsViewModel.swift
#	Session/Home/Message Requests/MessageRequestsViewController.swift
#	Session/Shared/Views/SessionAvatarCell.swift
#	SessionMessagingKit/Sending & Receiving/Message Handling/MessageReceiver+ClosedGroups.swift
#	SessionMessagingKit/Sending & Receiving/MessageSender.swift
2023-03-06 18:02:26 +11:00
Morgan Pretty 7ee84fe0d3 Cleaned up a bunch of code, added pinned and hidden handling
Added in logic to handle the 'hidden' state
Replaced the 'Group Created' message with an empty state
Cleaned up a bunch of boilerplate code
2023-03-02 17:52:37 +11:00
Morgan Pretty ff36b3eeab Resolved a number of TODOs and a couple of crashes
Updated the logic to always fetch all config messages (and not de-dupe them)
Updated the onboarding to fallback to fetch the legacy config if the there is no updated user config
Added sorting to config message processing to reduce the turn-around time for certain edge-cases to resolve
Removed some redundant code
Fixed a database re-entrancy crash
Fixed a crash when merging config messages
Fixed an issue which could occur by registering too many 'afterTransaction' closures
2023-02-21 17:10:02 +11:00
Morgan Pretty f30b383bb8 Updated to the latest version of libSession-util
Updated the SharedConfigMessage type to have a TTL of 30 days
Updated the SnodeAPI to have a 'poll' method to be more consistent with the OpenGroupAPI (it also does multiple things now so is cleaner)
Added logic to limit the number of config messages to be retrieved per poll
Added the 'ValidatableResponse' protocol to standardise SnodeAPI response validation
Added the libSession version to the logs
Fixed an issue where the user profile pic wouldn't get synced correctly due to memory going out of scope
Fixed some threading issues
Refactored the thread variants to follow the updated terminology (will think about refactoring other code areas later)
Cleaned up the Combine error handling
Started fixing broken unit tests
2023-02-20 12:56:48 +11:00
Emily ec0b35a9a2 Merge branch 'dev' into accessibility_ids_3 2023-02-02 11:41:48 +11:00
Emily 379f5c82ee Adding ids to photo library and editing media page 2023-02-02 11:41:09 +11:00
Morgan Pretty 29ba25916c Fixed a few issues uncovered when testing the shared util feature flag
Added code to handle an edge-case where an account could exist without a display name if crashing at the right time when onboarding/linking (now request a display name on start up)
Fixed a crash which could occur when downloading new avatars
Fixed a minor layout issue with the seed reminder view
2023-01-05 13:40:33 +11:00
Morgan Pretty 8f3dcbc6be Sorted out a bunch of the config syncing logic
Updated the onboarding to attempt to retrieve the current user profile config and skip display name collection if it already exists
Updated the logic to get the snode pool and build paths immediately on launch even if the user hasn't been created yet (faster onboarding)
Removed the iOS-specific concurrent dual snode '/store' behaviour
Cleaned up the profile updating logic
Fixed an issue where the pollers could end up deadlocking the main thread if too many tried to start concurrently
2022-12-16 16:51:08 +11:00
Ryan Zhao c867c95c7a fix a crash happening when long mnemonic is used to recover an account 2022-12-15 15:48:06 +11:00
Morgan Pretty 174725c7fd Removed unneeded imports of libraries to understand usage
Refactored some 3rd-part standard encryption to use CryptoKit
Removed the PromiseKit pod
Fixed the broken tests
2022-12-08 18:07:02 +11:00
Morgan Pretty 8b37002d89 Removed some unneeded imports
# Conflicts:
#	SessionMessagingKit/Jobs/Types/AttachmentUploadJob.swift
#	SessionMessagingKit/Jobs/Types/MessageSendJob.swift
#	SessionShareExtension/SAEScreenLockViewController.swift
#	SessionSnodeKit/Models/SnodeBatchRequest.swift
2022-12-07 15:54:56 +11:00
Morgan Pretty f5933bdf75 Updated to the latest version of the shared util library
# Conflicts:
#	Session/Onboarding/Onboarding.swift
2022-12-07 15:08:04 +11:00
RyanZhao ff65c84504
Merge pull request #713 from RyanRory/accessibility-ids-2
Add AccessibilityIDs
2022-12-06 15:15:19 +11:00
Emily f1dd8a8a53 Adding accessibility ids for closed group testing, messaging tests, onboarding tests and linked device testing 2022-12-05 15:27:27 +11:00
ryanzhao fe8930405d Merge branch 'dev' into ipad-landscape-support 2022-11-15 11:32:29 +11:00
Emily 2159ec149e adding accessibility ids and label to extract session id and recovery phrase and adding ids for message requests workflow 2022-11-14 13:54:33 -10:00
Morgan Pretty 1b350cf422 Fixed a number of crashes
Consolidated the PagedDatabaseObserver updating logic into a static function (can be improved further in the future)
Added defensive coding to prevent the LinkDeviceVC from crashing when the nav controller doesn't exist
Fixed an issue where the 'Permissions' callbacks were doing UI logic on background threads
Fixed an issue where the 'reloadCurrent' load type for the PagedDatabaseObserver was incorrectly increasing the 'currentCount' of the PageInfo
Fixed an issue where loading all of the data for paged data could result in a crash when the 'loadMore' section was removed
2022-10-24 14:52:28 +11:00
ryanzhao 265659c8cb add accessibility labels for automation test 2022-10-19 16:13:21 +11:00
Ryan Zhao b44a61b1dd Merge branch 'theming' into ipad-landscape-support 2022-10-10 09:43:42 +11:00
Morgan Pretty c33b555c3c Translations, better RTL support and minor animation fix
Added some better support for right-to-left languages
Added updated Farsi translations
Fixed a minor transition glitch
2022-10-07 18:46:05 +11:00
ryanzhao 3dfa3ac5ee Merge branch 'theming' into ipad-landscape-support 2022-10-04 16:48:42 +11:00
Morgan Pretty 93e12a3fcb Cleaned out old strings 2022-10-03 16:01:46 +11:00
Morgan Pretty 37124c2185 Updated the alerts to use the custom styled ones
Removed some more unused code
Moved around some files to make them more reusable
2022-09-28 18:26:02 +10:00
Morgan Pretty 40109e0bea Cleaned up the config-based table view controller to be more reusable
Updated the settings screens to have the "rounded group" styling
Added a "loading conversations" label to the Message Requests screen before the conversations load
Removed the legacy UserCell (replaced with the more reusable 'SessionCell')
Renamed a few things to make them more generic and reusable
2022-09-28 17:30:31 +10:00
ryanzhao cc3591a207 minor tweak on the width of fake chat bubble 2022-09-28 15:58:53 +10:00
ryanzhao bd1e1b266b fix gradient background 2022-09-28 14:26:07 +10:00
Morgan Pretty f98e2a157e Added rounding to the settings and updated the SettingVC to use the config approach
Removed some unused code
2022-09-27 15:36:47 +10:00
Morgan Pretty 8109a326cf Merge remote-tracking branch 'upstream/dev' into feature/theming
# Conflicts:
#	Session.xcodeproj/project.pbxproj
#	Session/Closed Groups/NewClosedGroupVC.swift
#	Session/Conversations/ConversationVC+Interaction.swift
#	Session/Conversations/Message Cells/CallMessageCell.swift
#	Session/Conversations/Views & Modals/JoinOpenGroupModal.swift
#	Session/Home/HomeVC.swift
#	Session/Home/New Conversation/NewDMVC.swift
#	Session/Home/NewConversationButtonSet.swift
#	Session/Meta/Translations/de.lproj/Localizable.strings
#	Session/Meta/Translations/en.lproj/Localizable.strings
#	Session/Meta/Translations/es.lproj/Localizable.strings
#	Session/Meta/Translations/fa.lproj/Localizable.strings
#	Session/Meta/Translations/fi.lproj/Localizable.strings
#	Session/Meta/Translations/fr.lproj/Localizable.strings
#	Session/Meta/Translations/hi.lproj/Localizable.strings
#	Session/Meta/Translations/hr.lproj/Localizable.strings
#	Session/Meta/Translations/id-ID.lproj/Localizable.strings
#	Session/Meta/Translations/it.lproj/Localizable.strings
#	Session/Meta/Translations/ja.lproj/Localizable.strings
#	Session/Meta/Translations/nl.lproj/Localizable.strings
#	Session/Meta/Translations/pl.lproj/Localizable.strings
#	Session/Meta/Translations/pt_BR.lproj/Localizable.strings
#	Session/Meta/Translations/ru.lproj/Localizable.strings
#	Session/Meta/Translations/si.lproj/Localizable.strings
#	Session/Meta/Translations/sk.lproj/Localizable.strings
#	Session/Meta/Translations/sv.lproj/Localizable.strings
#	Session/Meta/Translations/th.lproj/Localizable.strings
#	Session/Meta/Translations/vi-VN.lproj/Localizable.strings
#	Session/Meta/Translations/zh-Hant.lproj/Localizable.strings
#	Session/Meta/Translations/zh_CN.lproj/Localizable.strings
#	Session/Open Groups/JoinOpenGroupVC.swift
#	Session/Open Groups/OpenGroupSuggestionGrid.swift
#	Session/Settings/SettingsVC.swift
#	Session/Shared/BaseVC.swift
#	Session/Shared/OWSQRCodeScanningViewController.m
#	Session/Shared/ScanQRCodeWrapperVC.swift
#	Session/Shared/UserCell.swift
#	SessionMessagingKit/Configuration.swift
#	SessionShareExtension/SAEScreenLockViewController.swift
#	SessionUIKit/Style Guide/Gradients.swift
#	SignalUtilitiesKit/Media Viewing & Editing/OWSViewController+ImageEditor.swift
#	SignalUtilitiesKit/Screen Lock/ScreenLockViewController.m
2022-09-26 11:16:47 +10:00
Morgan Pretty f7fd15dae0 Finished removing usages to non-theme colour variables
Updated theming throughout
Fixed a couple of bugs with the media gallery
2022-09-20 16:06:01 +10:00
Morgan Pretty 1bc6b0bdba Merge remote-tracking branch 'upstream/dev' into feature/theming
# Conflicts:
#	Session.xcodeproj/project.pbxproj
#	Session/Conversations/ConversationVC+Interaction.swift
#	Session/Conversations/ConversationVC.swift
#	Session/Conversations/ConversationViewModel.swift
#	Session/Conversations/Message Cells/VisibleMessageCell.swift
#	Session/Home/HomeVC.swift
#	Session/Home/Message Requests/MessageRequestsViewController.swift
#	Session/Media Viewing & Editing/MediaTileViewController.swift
#	Session/Meta/AppDelegate.swift
#	Session/Meta/Translations/de.lproj/Localizable.strings
#	Session/Meta/Translations/en.lproj/Localizable.strings
#	Session/Meta/Translations/es.lproj/Localizable.strings
#	Session/Meta/Translations/fa.lproj/Localizable.strings
#	Session/Meta/Translations/fi.lproj/Localizable.strings
#	Session/Meta/Translations/fr.lproj/Localizable.strings
#	Session/Meta/Translations/hi.lproj/Localizable.strings
#	Session/Meta/Translations/hr.lproj/Localizable.strings
#	Session/Meta/Translations/id-ID.lproj/Localizable.strings
#	Session/Meta/Translations/it.lproj/Localizable.strings
#	Session/Meta/Translations/ja.lproj/Localizable.strings
#	Session/Meta/Translations/nl.lproj/Localizable.strings
#	Session/Meta/Translations/pl.lproj/Localizable.strings
#	Session/Meta/Translations/pt_BR.lproj/Localizable.strings
#	Session/Meta/Translations/ru.lproj/Localizable.strings
#	Session/Meta/Translations/si.lproj/Localizable.strings
#	Session/Meta/Translations/sk.lproj/Localizable.strings
#	Session/Meta/Translations/sv.lproj/Localizable.strings
#	Session/Meta/Translations/th.lproj/Localizable.strings
#	Session/Meta/Translations/vi-VN.lproj/Localizable.strings
#	Session/Meta/Translations/zh-Hant.lproj/Localizable.strings
#	Session/Meta/Translations/zh_CN.lproj/Localizable.strings
#	Session/Onboarding/LandingVC.swift
#	SessionMessagingKitTests/_TestUtilities/MockGeneralCache.swift
2022-09-15 14:22:11 +10:00