Commit Graph

69 Commits

Author SHA1 Message Date
Doug 5915713a02 Introduce a build setting to detect Nightly builds. (#5852)
* Allow the AppIconBanner tool to be called with purely the build number.

And use that for the Element Pro Nightly.

* Use a build setting to determine Nightly builds.
2026-07-09 13:56:26 +01:00
Stefan Ceriu 95319d13b7 Make the zip and file attaching bug report service steps concurrent 2026-06-29 18:01:57 +03:00
Mauro a520d94760 Swift 6 Migration (#5733)
* Enable Swift 6.2 with default main actor isolation for the app target

Turn on SWIFT_VERSION 6.2, SWIFT_APPROACHABLE_CONCURRENCY and SWIFT_DEFAULT_ACTOR_ISOLATION = MainActor for the ElementX target, matching the NSE and Share Extension (which already use 6.2 without the main actor default).

# Conflicts:
#	ElementX.xcodeproj/project.xcworkspace/xcshareddata/swiftpm/Package.resolved

* Update the code generation templates for Swift 6

Emit nonisolated/@unchecked Sendable mocks and nonisolated string enums, and mark async mock methods @concurrent so they keep suspending like the real implementations (otherwise intermediate states are unobservable in tests). Includes the regenerated mocks and strings.

# Conflicts:
#	ElementX/Sources/Mocks/Generated/GeneratedMocks.swift

* Make the data layer and services nonisolated and Sendable

Annotate the value-type models, Rust SDK proxy wrappers, timeline item graph, settings, logging and NSE-shared types as nonisolated, and conform the service protocols to Sendable so their existentials can cross isolation boundaries. These types run off the main actor and no longer inherit the target's default main actor isolation.

* Adopt the new isolation across call sites, mocks and signatures

Update call sites, closure signatures and mock configuration helpers to match the nonisolated/Sendable data layer, including the main actor isolated mock inits and the @Sendable filter on recentlyVisitedRooms.

^ Conflicts:
^	ElementX/Sources/Services/SecureBackup/SecureBackupController.swift

* Remove redundant @MainActor annotations

With the app target defaulting to main actor isolation, the explicit @MainActor on view models, coordinators, views and their protocols is no longer required.

* Fix concurrency hotspots surfaced by the migration

Resolve the room summary main-thread deadlock by moving diff processing onto AsyncStreams, add the SDKListener.onMainActor FIFO bridge for SDK callbacks, hop KVO/timer/UIKit callbacks to the main actor via assumeIsolated, add isolated deinits, and apply the few justified nonisolated(unsafe) escapes for queue-confined Apple APIs.

* Fix the unit tests for Swift 6 concurrency

Hop the waitForConfirmation body onto the caller's actor (Swift Testing runs confirmation closures off-actor), and adjust the affected suites and async signatures.

* offload diffs on concurrent threads instead of main actor

* make room info protocols sendable

* use a task group for fetching data so that everything runs concurrently in the TextRoomTimelineView when getting the preview.

* use the generic onMainActor implementation, which already makes a stream and send the continuation on the main actor.

* small pr comments issues being addressed

* update enterprise

* Update StaticCode to 1.1.0 and specify the required Swift isolation.

* fix ElementCallServiceTests

* update enterprise

* re-generate mocks

* update enterprise

* enterprise new code conformed to swift 6

---------

Co-authored-by: Doug <douglase@element.io>
2026-06-18 17:55:31 +02:00
Doug fa67713726 Run SwiftFormat. 2026-05-27 17:11:42 +01:00
Michael dfebb4719c Compiler Warning Reductions (#5609)
* Reduce warnings in AttributedStringBuilderTests

(cherry picked from commit e1f32b2b1df147c93207e01df5c8fec4046b0f48)

* Fixed Sentry warning

(cherry picked from commit e45c3002b2331a6f2d363de61a12377316078602)

* JoinRule and AllowRule conform to Sendable

(cherry picked from commit 27c67c27b944df11adc17bdd405e442e8c50b0d6)

* AudioConverterProtocol conform to Sendable

(cherry picked from commit 352bdab15db424c632538eb3140858eae9fdfb15)

* TimelineControllerProtocol conform to Sendable

(cherry picked from commit 07a927745624db4bab3cf68842027e12177be70b)

* Resolved some AI review notes

(cherry picked from commit 8d3ac820754a6126785e639a98c8c1fcf86ef77f)

# Conflicts:
#	ElementX/Sources/Other/SendableConformance/SendableBox.swift
#	ElementX/Sources/Other/SendableConformance/WeakSendableBox.swift
2026-05-22 10:56:30 +02:00
Stefan Ceriu 8f9d507e28 Update the RustSDK and adopt the new tracing configuration that allows maximum size and age limits on all logs.
Set that 100Mb and a week and remove previous rageshake uploading checks as they are no longer required.
2026-02-13 18:00:23 +02:00
Doug 65fb54f1fc Fix the bug report size check and a bad swiftlint command. (#5045) 2026-02-03 13:10:49 +00:00
Doug 347873576a Don't bother compressing really large log files just to throw them away. (#5021) 2026-01-29 12:20:31 +00:00
Stefan Ceriu 23062901c0 Update files following swiftformat upgrade 2026-01-27 12:50:57 +02:00
Mauro f7dd9cdcf8 Update copyright holding and dates (#4640)
* Update copyright holding and dates

* compound IDE Macros updated

* update copyright

* update copyrights done

* update templates and README
2025-10-21 14:34:56 +02:00
Doug e95e8ff5aa Label rageshakes from macOS and report the right operating system. (#4392) 2025-08-07 11:39:29 +00:00
Doug 82c659f3da Refactor Rageshake URL and Target configuration. (#4337)
* Move the rageshakeURL configuration from the BugReportService to AppSettings.

* Refactor Target to return a handle when configuring.

This helps with reconfiguration and removes the @MainActor constraint.
2025-07-22 10:19:26 +01:00
Doug ec7f578f56 Add a few more labels when sending a rageshake. (#4284) 2025-07-03 12:09:27 +01:00
Doug 17596f3de1 Support runtime customisation of the rageshake URL. (#4267) 2025-06-30 10:18:25 +01:00
Doug 0f9d700c99 Fix a crash when attempting to send a bug report with excessively large logs. (#4243)
* Alert the user when there are excessively large log files.
2025-06-24 09:47:20 +01:00
Doug 2d926f446a Refactor reportUrl to reportURL. 2025-06-18 14:32:26 +01:00
Doug d2562b1b7e Don't check the report URL's contents before clearing the lastCrashEventID.
If we reached it this far, the server has indicated that the submission was successful.
2025-06-18 14:32:26 +01:00
Nicolas Buquet dd20823240 Make BugReportService reportUrl optional (#4195) 2025-06-18 14:32:26 +01:00
Stefan Ceriu 0f3d0eb34f Fixes #4185 - Correct the bug report service submission URL after updating how secrets are configured.
- introduced in https://github.com/element-hq/element-x-ios/pull/4145/commits/54f4aeda4fee11f01028944668f01502f63abc35
2025-06-11 12:33:49 +03:00
Doug 574f49d71e Add the build number to rageshakes. (#3978) 2025-04-04 10:36:52 +00:00
Doug 5e50823223 Allow the services that are configured by secrets to be disabled. (#3961)
* Make the map tiler key optional.

* Make the bug report URL optional.

* Make the sentry URL optional.

* Make the analytics configuration optional and handle consent taking Sentry into account.

* Stop prompting users to report crashes when Sentry is disabled.
2025-04-01 09:24:12 +01:00
Stefan Ceriu 57b85d2650 Move tracing configuration to the rust side. 2025-01-10 19:09:52 +02:00
manuroe 3950cac085 Dual licensing: AGPL + Element Commercial (#3657)
* New LICENSE-COMMERCIAL file

* Apply dual licenses: AGPL + Element Commercial to file headers

* Update README with dual licensing
2025-01-06 11:27:37 +01:00
Doug 718774dc36 Fix some warnings. (#3416) 2024-10-16 08:54:34 +01:00
Stefan Ceriu 664e87fe87 Switch license to AGPL (#3237)
* Switch license file to AGPL

* Update file copyright headers

* Update the default project file header
2024-09-06 16:34:30 +03:00
Doug cdd763efd4 Add a certificate validator hook. (#3069)
* Add a certificate validator hook.

* General tidy up of AppHooks.

* Don't worry about the generic call links.
2024-07-19 17:05:54 +01:00
Doug 78b0c7068d Add a bug report hook. (#2988) 2024-07-01 13:53:24 +01:00
Stefan Ceriu 3c500887ab Setup Sentry instrumentation on top of the existing Signposter (#2985)
* Move Sentry setup outside of the BugReportService

* Setup Sentry SwiftUI tracing for the homeScreen and roomScreen roots

* Setup Sentry instrumentation on top of the existing Signposter

* Various tweaks
2024-06-28 18:15:57 +03:00
Stefan Ceriu 9f6fc1d42f Fix various swiftlint and swiftformat warnings 2024-06-11 18:09:43 +03:00
Stefan Ceriu a4c9135b58 Decouple the bug report service from the analytics one 2024-05-30 15:42:26 +03:00
Valere f0ac0a63fb Add device keys to rageshakes (#2838) 2024-05-21 09:54:16 +01:00
Doug ff35688088 Handover log file management to Rust. (#2495)
* Handover log file management to Rust.

Fix all the tests, disabling the logging ones for now.

* Merge logging tests into a single case 😬

Not ideal but at least they're now running.

* Move TracingConfiguration into its own file.

* Split up the tests into smaller functions instead of writing code like a caveman.
2024-02-23 18:29:13 +00:00
Stefan Ceriu 0fe52fe54b Allow reporting a problem from the onboarding screen 2024-01-22 14:17:36 +02:00
Mauro d99d26fcdc Removing Dead Code part 1 (#2234) 2023-12-13 09:51:57 +01:00
Stefan Ceriu ff4d59bac7 Various optimisations (#1878)
* Cache TimelineBubbleLayout subview sizes

* Cache MessageText sizes, avoid extra updates

* Only use the `CollapsibleReactionLayout` if there's more than 5 reactions on a particular message

* Upgrade Sentry to 8.13.0, disable various options as they're not useful and impact performance

* Address PR comments, fix unit tests
2023-10-11 16:21:45 +03:00
Stefan Ceriu 855b08144c Fixes #1861 - Report rust tracing configuration filter in rageshakes 2023-10-09 14:59:56 +03:00
Stefan Ceriu f649d362f5 Various Sentry configuration tweaks to make it more usable 2023-08-09 15:44:23 +03:00
Stefan Ceriu dd6d1f6e63 Tweak swiftlint settings 2023-08-08 11:48:40 +03:00
Stefan Ceriu ebb7436927 Send the SDK's short git SHA to rageshakes 2023-08-02 10:27:22 +03:00
Doug 48dbbfb4d0 Log the crash event's ID to see if duplicate logs are for the same event. (#1350) 2023-07-18 15:00:33 +01:00
Mauro c573892954 Contact me added in Bug Report Screen (#1307)
* contact me added

* fixing tests
2023-07-12 08:20:51 +00:00
Stefan Ceriu e6711a0236 Removed unused swipe gesture (+3 squashed commits)
Squashed commits:
[d64bb3bb] Stop using the ServiceLocator directly in the ScreenTrackerViewModifier
[37c46ab9] Rename Analytics to AnalyticsService
[8852a371] #920 - Cleanup ServiceLocator usages
2023-06-28 11:33:41 +03:00
Stefan Ceriu 8b11a0a5ec Add support for media uploading progress
- replace the ProgressTracker with a combination of currentValueSubjects and currentValuePublishers
2023-06-22 13:37:13 +03:00
Flescio 163e38b1a9 Add reverse geocoding service (#1085)
* add Geocoding service

* move url session extension
2023-06-15 16:40:42 +02:00
Doug ea4aa943e0 Improved bug report error handling (#1018)
* Improve rageshake error handling.

* Add a max file size and exclude older files one the limit is hit.

* Zip log files as smaller chunks.
2023-06-06 11:24:01 +03:00
Nicolas Mauri 5b7ec6c9e2 Set up Analytics to track data per session (#780) 2023-04-18 07:33:32 +00:00
Doug d01349a60e Use iOS localization handling for strings. (#803) 2023-04-17 14:58:39 +00:00
Doug 7d35876753 Update danger message and brew dependencies. (#683) 2023-03-08 10:59:49 +00:00
Stefan Ceriu a3abde9e23 Fixes #614 - Add the user and device identifiers to rageshakes (#620)
* Fixes #614 - Add the user and device identifiers to rageshakes

* Add `base_bundle_identifier` to rageshakes
2023-02-24 14:51:36 +02:00
Mauro e91e0513b6 Attach Screenshot in Bug Report Screen (#578)
* 127 Attach Screenshot in Bug Report Screen

* #127 code improvement

* #127 Code improvements, and changed the loading... label to sending...

* using a statically defined identifier for the new defined ui element

* added the RowLabelStyle and improved the design of the view

* code improvement

* code improvement

* making alignment private

* synthesised init
2023-02-15 16:46:53 +00:00