Skip to content
Draft
Show file tree
Hide file tree
Changes from 16 commits
Commits
Show all changes
18 commits
Select commit Hold shift + click to select a range
1df1f19
chore(sdk): bump submodule to afbca02
smk762 Oct 7, 2025
87f0a78
chore(submodule): bump sdk to latest on chore/kw-release-v0.9.3 for u…
CharlVS Oct 7, 2025
853e555
chore(submodule): track sdk on universal-mac-builds branch
CharlVS Oct 7, 2025
005b873
chore(submodule): point sdk to universal-mac-builds and bump pointer
CharlVS Oct 7, 2025
e70a1c1
chore(submodule): track sdk at add/macos-universal-support and update…
CharlVS Oct 9, 2025
a942124
chore: update SDK submodule
CharlVS Oct 9, 2025
022fe8b
chore: regenerate native podfiles
CharlVS Oct 9, 2025
f1ee957
Merge branch 'dev' of https://github.com/KomodoPlatform/komodo-wallet…
CharlVS Oct 9, 2025
6ec9461
chore(sdk): bump submodule to latest dev commit
CharlVS Oct 10, 2025
69df081
chore(pods): update iOS/macOS lockfiles, macOS Podfile, Xcode project
CharlVS Oct 14, 2025
6e49d28
Merge branch 'dev' of https://github.com/KomodoPlatform/komodo-wallet…
CharlVS Oct 14, 2025
839b5fe
chore(macos,pods): clarify universal architectures comment; add x86_6…
CharlVS Oct 14, 2025
bf2aa9e
chore(macos,pods): set ONLY_ACTIVE_ARCH=YES for Debug pods; universal…
CharlVS Oct 14, 2025
fbff8dd
chore(sdk): bump submodule to include macOS KDF codesign step
CharlVS Oct 15, 2025
bcf6d7b
chore(macos): enforce timestamped hardened codesigning for pods; bump…
CharlVS Oct 15, 2025
cf147cb
chore(analytics,macos): update Firebase analytics integration and mac…
CharlVS Oct 15, 2025
ab5437a
chore: revert macos team changes
CharlVS Oct 15, 2025
88123d5
Merge branch 'dev' of https://github.com/KomodoPlatform/komodo-wallet…
CharlVS Oct 15, 2025
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
8 changes: 7 additions & 1 deletion ios/Podfile.lock
Original file line number Diff line number Diff line change
@@ -1,4 +1,6 @@
PODS:
- device_info_plus (0.0.1):
- Flutter
- DKImagePickerController/Core (4.3.9):
- DKImagePickerController/ImageDataManager
- DKImagePickerController/Resource
Expand Down Expand Up @@ -178,6 +180,7 @@ PODS:
- FlutterMacOS

DEPENDENCIES:
- device_info_plus (from `.symlinks/plugins/device_info_plus/ios`)
- file_picker (from `.symlinks/plugins/file_picker/ios`)
- firebase_analytics (from `.symlinks/plugins/firebase_analytics/ios`)
- firebase_core (from `.symlinks/plugins/firebase_core/ios`)
Expand Down Expand Up @@ -214,6 +217,8 @@ SPEC REPOS:
- SwiftyGif

EXTERNAL SOURCES:
device_info_plus:
:path: ".symlinks/plugins/device_info_plus/ios"
file_picker:
:path: ".symlinks/plugins/file_picker/ios"
firebase_analytics:
Expand Down Expand Up @@ -248,6 +253,7 @@ EXTERNAL SOURCES:
:path: ".symlinks/plugins/video_player_avfoundation/darwin"

SPEC CHECKSUMS:
device_info_plus: 21fcca2080fbcd348be798aa36c3e5ed849eefbe
DKImagePickerController: 946cec48c7873164274ecc4624d19e3da4c1ef3c
DKPhotoGallery: b3834fecb755ee09a593d7c9e389d8b5d6deed60
file_picker: a0560bc09d61de87f12d246fc47d2119e6ef37be
Expand Down Expand Up @@ -280,6 +286,6 @@ SPEC CHECKSUMS:
url_launcher_ios: 694010445543906933d732453a59da0a173ae33d
video_player_avfoundation: 2cef49524dd1f16c5300b9cd6efd9611ce03639b

PODFILE CHECKSUM: f2a1ebd07796ee082cb4d8e8fa742449f698c4f1
PODFILE CHECKSUM: 59b529d1a68d075d396a4247263413419e35c335

COCOAPODS: 1.16.2
3 changes: 3 additions & 0 deletions lib/bloc/analytics/analytics_api.dart
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,9 @@ import 'analytics_repo.dart';

/// Abstract interface for analytics providers
abstract class AnalyticsApi {
/// Whether this analytics provider can be used on the current platform/config
bool isAvailable();

/// Initialize the analytics provider
Future<void> initialize(AnalyticsSettings settings);

Expand Down
17 changes: 11 additions & 6 deletions lib/bloc/analytics/analytics_repo.dart
Original file line number Diff line number Diff line change
Expand Up @@ -119,15 +119,20 @@ class AnalyticsRepository implements AnalyticsRepo {
);
}

// Add Firebase Analytics provider
// Add Firebase Analytics provider if available
final firebaseProvider = FirebaseAnalyticsApi();
_providers.add(firebaseProvider);
if (firebaseProvider.isAvailable()) {
_providers.add(firebaseProvider);
} else if (kDebugMode) {
log(
'Firebase provider not registered: unavailable (missing/placeholder options or unsupported platform)',
path: 'analytics -> AnalyticsRepository -> _initializeProviders',
);
}

// Add Matomo Analytics provider when configuration is present
final bool hasMatomoConfig =
matomoUrl.isNotEmpty && matomoSiteId.isNotEmpty;
if (hasMatomoConfig) {
final matomoProvider = MatomoAnalyticsApi();
final matomoProvider = MatomoAnalyticsApi();
if (matomoProvider.isAvailable()) {
_providers.add(matomoProvider);
} else if (kDebugMode) {
log(
Expand Down
25 changes: 22 additions & 3 deletions lib/bloc/analytics/firebase_analytics_api.dart
Original file line number Diff line number Diff line change
Expand Up @@ -41,6 +41,25 @@ class FirebaseAnalyticsApi implements AnalyticsApi {
return _initializeWithRetry(settings);
}

@override
bool isAvailable() {
try {
// Only proceed if Firebase options exist and are not placeholders
final FirebaseOptions options = DefaultFirebaseOptions.currentPlatform;
final serialized = options.toString();
if (serialized.contains('THIS_IS_AUTOGENERATED')) {
return false;
}
// Additionally, ensure we are not on unsupported desktop Linux
if (!kIsWeb && defaultTargetPlatform == TargetPlatform.linux) {
return false;
}
return true;
} catch (_) {
return false;
}
}
Comment thread
CharlVS marked this conversation as resolved.

/// Initialize with retry mechanism
Future<void> _initializeWithRetry(AnalyticsSettings settings) async {
try {
Expand All @@ -60,11 +79,11 @@ class FirebaseAnalyticsApi implements AnalyticsApi {
// Load any previously saved events
await _loadPersistedQueue();

// Skip unsupported platforms (Linux not supported by Firebase Analytics)
if (!kIsWeb && defaultTargetPlatform == TargetPlatform.linux) {
// Skip when unavailable (invalid options, unsupported platform)
if (!isAvailable()) {
if (kDebugMode) {
log(
'Firebase Analytics not supported on Linux; marking as initialized=false and enabled=false',
'Firebase Analytics unavailable (missing/placeholder options or unsupported platform). Disabling.',
path: 'analytics -> FirebaseAnalyticsApi -> _initialize',
);
}
Expand Down
6 changes: 6 additions & 0 deletions lib/bloc/analytics/matomo_analytics_api.dart
Original file line number Diff line number Diff line change
Expand Up @@ -208,6 +208,12 @@ class MatomoAnalyticsApi implements AnalyticsApi {
@override
bool get isEnabled => _isEnabled;

@override
bool isAvailable() {
// Available only when MATOMO_URL and MATOMO_SITE_ID are configured
return matomoUrl.isNotEmpty && matomoSiteId.isNotEmpty;
}

@override
Future<void> initialize(AnalyticsSettings settings) async {
return _initializeWithRetry(settings);
Expand Down
22 changes: 22 additions & 0 deletions macos/Podfile
Original file line number Diff line number Diff line change
@@ -1,5 +1,8 @@
require 'xcodeproj'

# Use the CocoaPods CDN source for faster and more reliable dependency resolution
source 'https://cdn.cocoapods.org/'

def deployment_target
project_path = 'Runner.xcodeproj'
project = Xcodeproj::Project.open(project_path)
Expand Down Expand Up @@ -50,6 +53,25 @@ post_install do |installer|
flutter_additional_macos_build_settings(target)
target.build_configurations.each do |config|
config.build_settings['MACOSX_DEPLOYMENT_TARGET'] = deployment_target
# Ensure timestamped, hardened runtime code signing for all pods and Runner
existing = config.build_settings['OTHER_CODE_SIGN_FLAGS']
flags = existing ? Array(existing) : []
flags << '--timestamp=auto'
flags << '--options=runtime'
config.build_settings['OTHER_CODE_SIGN_FLAGS'] = flags.uniq
end
end

# Use $(ARCHS_STANDARD) (arm64 + x86_64) to produce a universal macOS build.
# Debug builds: build only the active architecture to speed up local development.
# TODO: If we encounter arch/linker errors from pods missing x86_64 slices (often vendored/prebuilt),
# exclude x86_64 for affected configs or switch Release to arm64-only.
installer.pods_project.build_configurations.each do |config|
config.build_settings['ARCHS'] = '$(ARCHS_STANDARD)'
if config.name == 'Debug'
config.build_settings['ONLY_ACTIVE_ARCH'] = 'YES'
else
config.build_settings['ONLY_ACTIVE_ARCH'] = 'NO'
end
end
end
10 changes: 8 additions & 2 deletions macos/Podfile.lock
Original file line number Diff line number Diff line change
@@ -1,4 +1,6 @@
PODS:
- device_info_plus (0.0.1):
- FlutterMacOS
- file_picker (0.0.1):
- FlutterMacOS
- Firebase/Analytics (11.15.0):
Expand Down Expand Up @@ -136,6 +138,7 @@ PODS:
- FlutterMacOS

DEPENDENCIES:
- device_info_plus (from `Flutter/ephemeral/.symlinks/plugins/device_info_plus/macos`)
- file_picker (from `Flutter/ephemeral/.symlinks/plugins/file_picker/macos`)
- firebase_analytics (from `Flutter/ephemeral/.symlinks/plugins/firebase_analytics/macos`)
- firebase_core (from `Flutter/ephemeral/.symlinks/plugins/firebase_core/macos`)
Expand Down Expand Up @@ -168,6 +171,8 @@ SPEC REPOS:
- PromisesObjC

EXTERNAL SOURCES:
device_info_plus:
:path: Flutter/ephemeral/.symlinks/plugins/device_info_plus/macos
file_picker:
:path: Flutter/ephemeral/.symlinks/plugins/file_picker/macos
firebase_analytics:
Expand Down Expand Up @@ -204,6 +209,7 @@ EXTERNAL SOURCES:
:path: Flutter/ephemeral/.symlinks/plugins/window_size/macos

SPEC CHECKSUMS:
device_info_plus: 4fb280989f669696856f8b129e4a5e3cd6c48f76
file_picker: 7584aae6fa07a041af2b36a2655122d42f578c1a
Firebase: d99ac19b909cd2c548339c2241ecd0d1599ab02e
firebase_analytics: 3091f96bd17636f6da5092a4701ffacf67c6e455
Expand All @@ -218,7 +224,7 @@ SPEC CHECKSUMS:
FlutterMacOS: d0db08ddef1a9af05a5ec4b724367152bb0500b1
GoogleAppMeasurement: 700dce7541804bec33db590a5c496b663fbe2539
GoogleUtilities: 00c88b9a86066ef77f0da2fab05f65d7768ed8e1
komodo_defi_framework: 725599127b357521f4567b16192bf07d7ad1d4b0
komodo_defi_framework: 1eb76cee957ff7598498a87bb0d1c470da0f0980
local_auth_darwin: d2e8c53ef0c4f43c646462e3415432c4dab3ae19
mobile_scanner: 9157936403f5a0644ca3779a38ff8404c5434a93
nanopb: fad817b59e0457d11a5dfbde799381cd727c1275
Expand All @@ -232,6 +238,6 @@ SPEC CHECKSUMS:
video_player_avfoundation: 2cef49524dd1f16c5300b9cd6efd9611ce03639b
window_size: 4bd15034e6e3d0720fd77928a7c42e5492cfece9

PODFILE CHECKSUM: d064900e78ded0efef7fcc0db57cbf4bc2487624
PODFILE CHECKSUM: e956d7d2637294ec1826a83f192da39c811af440

COCOAPODS: 1.16.2
16 changes: 10 additions & 6 deletions macos/Runner.xcodeproj/project.pbxproj
Original file line number Diff line number Diff line change
Expand Up @@ -487,14 +487,15 @@
isa = XCBuildConfiguration;
baseConfigurationReference = 33E5194F232828860026EE4D /* AppInfo.xcconfig */;
buildSettings = {
ARCHS = "$(ARCHS_STANDARD)";
ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon;
CLANG_ENABLE_MODULES = YES;
CODE_SIGN_ENTITLEMENTS = Runner/DebugProfile.entitlements;
CODE_SIGN_IDENTITY = "Apple Development";
"CODE_SIGN_IDENTITY[sdk=macosx*]" = "Apple Development";
CODE_SIGN_STYLE = Automatic;
COMBINE_HIDPI_IMAGES = YES;
DEVELOPMENT_TEAM = 8HPBYKKKQP;
DEVELOPMENT_TEAM = WDS9WYN969;
EXCLUDED_ARCHS = "";
FRAMEWORK_SEARCH_PATHS = (
"$(inherited)",
Expand All @@ -510,7 +511,8 @@
"$(PROJECT_DIR)",
);
MACOSX_DEPLOYMENT_TARGET = 13.5;
PRODUCT_BUNDLE_IDENTIFIER = com.komodo.komodowallet;
ONLY_ACTIVE_ARCH = NO;
PRODUCT_BUNDLE_IDENTIFIER = com321.komodo.komodowallet;
PROVISIONING_PROFILE_SPECIFIER = "";
SWIFT_VERSION = 5.0;
};
Expand Down Expand Up @@ -634,7 +636,7 @@
"CODE_SIGN_IDENTITY[sdk=macosx*]" = "Apple Development";
CODE_SIGN_STYLE = Automatic;
COMBINE_HIDPI_IMAGES = YES;
DEVELOPMENT_TEAM = 8HPBYKKKQP;
DEVELOPMENT_TEAM = WDS9WYN969;
EXCLUDED_ARCHS = "";
FRAMEWORK_SEARCH_PATHS = (
"$(inherited)",
Expand All @@ -650,7 +652,7 @@
"$(PROJECT_DIR)",
);
MACOSX_DEPLOYMENT_TARGET = 13.5;
PRODUCT_BUNDLE_IDENTIFIER = com.komodo.komodowallet;
PRODUCT_BUNDLE_IDENTIFIER = com321.komodo.komodowallet;
PROVISIONING_PROFILE_SPECIFIER = "";
SWIFT_OBJC_BRIDGING_HEADER = "";
SWIFT_OPTIMIZATION_LEVEL = "-Onone";
Expand All @@ -662,14 +664,15 @@
isa = XCBuildConfiguration;
baseConfigurationReference = 33E5194F232828860026EE4D /* AppInfo.xcconfig */;
buildSettings = {
ARCHS = "$(ARCHS_STANDARD)";
ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon;
CLANG_ENABLE_MODULES = YES;
CODE_SIGN_ENTITLEMENTS = Runner/DebugProfile.entitlements;
CODE_SIGN_IDENTITY = "-";
"CODE_SIGN_IDENTITY[sdk=macosx*]" = "Apple Development";
CODE_SIGN_STYLE = Automatic;
COMBINE_HIDPI_IMAGES = YES;
DEVELOPMENT_TEAM = 8HPBYKKKQP;
DEVELOPMENT_TEAM = WDS9WYN969;
EXCLUDED_ARCHS = "";
FRAMEWORK_SEARCH_PATHS = (
"$(inherited)",
Expand All @@ -685,7 +688,8 @@
"$(PROJECT_DIR)",
);
MACOSX_DEPLOYMENT_TARGET = 13.5;
PRODUCT_BUNDLE_IDENTIFIER = com.komodo.komodowallet;
ONLY_ACTIVE_ARCH = NO;
Comment thread
CharlVS marked this conversation as resolved.
Outdated
PRODUCT_BUNDLE_IDENTIFIER = com321.komodo.komodowallet;
Comment thread
CharlVS marked this conversation as resolved.
Outdated
PROVISIONING_PROFILE_SPECIFIER = "";
SWIFT_VERSION = 5.0;
};
Expand Down
23 changes: 13 additions & 10 deletions macos/Runner/GoogleService-Info.plist
Original file line number Diff line number Diff line change
@@ -1,19 +1,24 @@
<!-- This is a dummy GoogleService-Info.plist file for projects not using Firebase -->
<!-- See [docs/FIREBASE_SETUP.md](docs/FIREBASE_SETUP.md) for setup details -->
<!-- TODO: Look at an alternative approach of conditionally installing Firebase Pods -->
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
<dict>
<key>GOOGLE_APP_ID</key>
<string>1:000000000000:ios:0000000000000000</string>
<key>GCM_SENDER_ID</key>
<string>000000000000</string>
<key>PROJECT_ID</key>
<string>dummy-project</string>
<key>BUNDLE_ID</key>
<string>com.example.dummy</string>
<key>API_KEY</key>
<string>THIS_IS_AUTOGENERATED</string>
<key>GCM_SENDER_ID</key>
<string>THIS_IS_AUTOGENERATED</string>
<string>A_DUMMY_API_KEY_00000000000000000000000</string>
<key>PLIST_VERSION</key>
<string>1</string>
<key>BUNDLE_ID</key>
<string>THIS_IS_AUTOGENERATED</string>
<key>PROJECT_ID</key>
<string>THIS_IS_AUTOGENERATED</string>
<key>STORAGE_BUCKET</key>
<string>THIS_IS_AUTOGENERATED</string>
<string>dummy-project.firebasestorage.app</string>
<key>IS_ADS_ENABLED</key>
<false></false>
<key>IS_ANALYTICS_ENABLED</key>
Expand All @@ -24,7 +29,5 @@
<true></true>
<key>IS_SIGNIN_ENABLED</key>
<true></true>
<key>GOOGLE_APP_ID</key>
<string>THIS_IS_AUTOGENERATED</string>
</dict>
</plist>
2 changes: 1 addition & 1 deletion sdk
Submodule sdk updated from 679fd9 to ffa766
Loading