Commit graph

32 commits

Author SHA1 Message Date
Benoit Marty
c901772145 Metro 0.10.0: Classes annotated with ContributesIntoSet do not need to be annotated with Inject. 2026-01-20 10:13:39 +01:00
Jorge Martin Espinosa
06c4b9488b
Adjust metrics to the new specifications (#5937)
* Add `AnalyticsTransactions` with a set of `TransactionDefinition` items matching those in the user story

* Use that for `AnalyticsLongRunningTransactions`, make sure we send the right fields (name, operation, description)

* Add `AnalyticsSendMessageWatcher` to track how long it takes for an event to be sent and for us to get a call back for that from sync

* Add `Noop` implementation for enterprise
2026-01-05 16:23:26 +01:00
Jorge Martin Espinosa
f78c80803b
Add some performance metrics for Sentry (#5760)
- Add `AnalyticsService.startTransaction(...)` to start a logging transaction that can be uploaded to Sentry if the user enabled the analytics upload.
- Add `AnalyticsTransaction` wrapper to abstract the Sentry ones.
- Added several helper methods to improve the UX around these transactions.
- Then measure:
  - Time until the first sync, and how it ended.
  - Time until the first rooms are displayed.
  - Time to load a room or a preview.
  - Time to load a timeline.
2025-11-19 11:42:55 +00:00
Benoit Marty
eb31505dc7 Copyright: Add Element Creations Ltd. copyright 2025-11-10 11:05:05 +01:00
Benoit Marty
f86431e663 Copyright: Add final period 2025-11-10 10:13:41 +01:00
Benoit Marty
c4e0370f41 Copyright: run command uv run license-editor --repository ../element-x-android 2025-11-10 10:09:26 +01:00
Benoit Marty
a575019760 Use DependencyHandlerScope.testCommonDependencies() 2025-09-16 14:38:31 +02:00
Jorge Martín
de8de61b2e Remove dagger and anvil dependencies, try to simplify gradle build scripts a bit 2025-09-04 16:49:21 +02:00
Jorge Martín
4ab62a6a38 Redo DI gradle setup code 2025-09-04 16:49:20 +02:00
Jorge Martín
29a97fc0d9 Fix lint issues and restore commented out code 2025-09-04 16:49:18 +02:00
Jorge Martín
b76a71ebf5 Start migrating Anvil KSP to Metro 2025-09-04 16:48:34 +02:00
Benoit Marty
3c1deff79c
Element config (#4471)
* Add handy extension "VariantDimension.buildConfigFieldStr"

* Update configuration for MapTiler.

* Update configuration for Sentry.

* Build AnalyticsConfig depending on analytics configuration.

* Configure analytics policy url.

* Add handy extension "VariantDimension.buildConfigFieldBoolean"

* Configure legal urls.

* Add a way to disable rageshake / reporting bugs.

* Update screenshots

* Quality

* Fix test

* Use `ifBlank` extension

* Add missing configuration for PostHog

* Update configuration for Rageshake.

* Add build log.

* Disable crash detection if rageshake feature is not available.
Disabled twice.

* Hide link to analytics policy if the link is missing.

* Fix test when run in enterprise context.

* Use RageshakeFeatureAvailability where appropriate.

* Rename file.

* Move some classes to their correct module.

* Update screenshots

---------

Co-authored-by: ElementBot <android@element.io>
2025-03-27 11:25:04 +01:00
Benoit Marty
97f3be3dc5 Apply dual licenses: AGPL + Element Commercial to file headers.
2 replace all actions have been performed:
- "SPDX-License-Identifier: AGPL-3.0-only" to "SPDX-License-Identifier: AGPL-3.0-only OR LicenseRef-Element-Commercial"
- "Please see LICENSE in the repository root for full details." to "Please see LICENSE files in the repository root for full details."
2025-01-07 10:05:04 +01:00
Jorge Martin Espinosa
eeec7cc785
Centralise the DI code generation logic (#3562)
* Create Anvil extension helper

* Use the helper everywhere
2024-09-30 12:20:28 +00:00
Benoit Marty
f61df38e55 Migrate license to AGPL.
Run script `uv run license-editor --repository ../element-x-android`
2024-09-06 17:19:19 +02:00
Benoit Marty
9567119e31 Ensure Posthog is only used for Element builds. 2024-06-04 17:04:19 +02:00
Valere
bf6ad4c5ca Analytics | Add support for SuperProperties 2024-05-31 14:07:02 +02:00
Valere
6ad40fc6e0 Code review - more tests 2024-05-07 09:38:26 +02:00
Valere
a761215e31 Add support for Verification state analytics 2024-05-06 19:06:54 +02:00
Benoit Marty
73f80b314f Add extra properties "cryptoSDK" to Error.CryptoSDK.Rust to all events and screen sent to PostHog. 2024-03-15 11:27:53 +01:00
renovate[bot]
c8bd362397
Update plugin ktlint to v12.1.0 (#2200)
* Update plugin ktlint to v12.1.0

* Run `./gradlew ktlintFormat` and fix some issues manually.

* Fix other issues reproted by Ktlint

* Limit false positives, KtLint removes unnecessary curly brace in String templates.

* Remove useless Unit

* Minor improvements over ktlint changes

* Restore `AlertDialogContent` behaviour

* Update screenshots

---------

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
Co-authored-by: Benoit Marty <benoit@matrix.org>
Co-authored-by: Jorge Martín <jorgem@element.io>
Co-authored-by: ElementBot <benoitm+elementbot@element.io>
2024-01-10 16:22:24 +01:00
Benoit Marty
2b764a1e56 Migrate to PostHog 3.0.0 2023-12-05 16:12:17 +01:00
Benoit Marty
cbb27cb5e5 Class annotated with @ContributesMultibinding cannot be internal. 2023-09-11 12:03:17 +02:00
Benoit Marty
3ff7b752a1 Ensure Posthog data are sent to "https://posthog.element.io" for release build. 2023-09-11 11:35:19 +02:00
jonnyandrew
c44b7eb81c
Fix crash in error tracking (#1248) 2023-09-07 15:05:11 +02:00
Benoit Marty
69dcd47e22 Update tag value and make it internal. 2023-07-21 18:35:47 +02:00
Benoit Marty
d4156653fd No need to sort AnalyticsProvider (it was copied from PushProvider) 2023-07-21 18:12:17 +02:00
Benoit Marty
2928073e22 Enable detekt rules UnusedImports and cleanup the code. 2023-07-20 18:00:23 +02:00
Benoit Marty
86756dbc09 Enable detekt rules UnusedParameter and UnusedPrivateProperty and cleanup the code. 2023-07-20 17:48:56 +02:00
Benoit Marty
24ece8c454 Enable detekt rule UnusedPrivateMember and cleanup the code. 2023-07-20 17:44:14 +02:00
yostyle
3b4bff61e9 Init or stop posthog based on user consent 2023-06-23 15:57:25 +02:00
Yoan Pintas
f534ecda96 Init analytics modules (#350) 2023-06-05 13:11:34 +00:00