Open Smibser opened 2 years ago
@Smibser please share some info from your environment, can you show us your pubspec and the flutter doctor output?
Oh yeah of course.
pubspec.yaml
environment:
sdk: ">=2.12.0 <3.0.0"
dependencies:
flutter:
sdk: flutter
flutter_bloc: ^8.0.1
bloc_concurrency: ^0.2.0
equatable: ^2.0.2
flutter_secure_storage: ^5.0.2
dio: ^4.0.0
intl: ^0.17.0
time_machine: ^0.9.16
url_launcher: ^6.0.6
cupertino_icons: ^1.0.2
decimal: ^2.0.0
flutter_svg: ^0.23.0+1
backend_api:
path: api/backend-api
flutter_html: ^2.1.0
shared_preferences: ^2.0.11
flutter_dialogs: ^2.1.0
sentry_flutter: ^6.2.0
wakelock: ^0.5.6
package_info_plus: ^1.3.0
flutter_appauth: 1.1.0+1 # Fixed version because of https://github.com/MaikuB/flutter_appauth/issues/256
flutter_segment: 3.3.0 # Fixed version because of https://github.com/la-haus/flutter-segment/issues/22
cached_network_image: ^3.1.0+1
flutter_local_notifications: ^9.1.5
timezone: ^0.8.0
device_info: ^2.0.3
flutter_native_timezone: ^2.0.0
keyboard_dismisser: ^2.0.0
rxdart: ^0.27.3
launchdarkly_flutter_client_sdk: ^1.0.0
fake_async: ^1.2.0
audioplayers: ^0.20.1
provider: ^6.0.1
video_player: ^2.2.10
touch_indicator: ^2.0.0
flutter_webview_plugin: ^0.4.0
invalid:
git:
url: https://github.com/CodingPassion-net/invalid.git
firebase_dynamic_links: ^4.1.1
dotted_border: ^2.0.0+1
dev_dependencies:
flutter_test:
sdk: flutter
flutter_driver:
sdk: flutter
integration_test:
sdk: flutter
flutter_launcher_icons: ^0.9.0
flutter_native_splash: ^1.1.8+4
network_image_mock: ^2.0.1
bloc_test: ^9.0.1
mockito: ^5.0.16
flutter doctor -v
[✓] Flutter (Channel stable, 2.10.4, on macOS 12.2.1 21D62 darwin-x64, locale en-DE)
• Flutter version 2.10.4 at /Users/./development/flutter
• Upstream repository https://github.com/flutter/flutter.git
• Framework revision c860cba910 (3 weeks ago), 2022-03-25 00:23:12 -0500
• Engine revision 57d3bac3dd
• Dart version 2.16.2
• DevTools version 2.9.2
[✓] Android toolchain - develop for Android devices (Android SDK version 30.0.3)
• Android SDK at /Users/./Library/Android/sdk
• Platform android-32, build-tools 30.0.3
• ANDROID_HOME = /Users/./Library/Android/sdk
• Java binary at: /Applications/Android Studio.app/Contents/jre/Contents/Home/bin/java
• Java version OpenJDK Runtime Environment (build 11.0.11+0-b60-7590822)
• All Android licenses accepted.
[✓] Xcode - develop for iOS and macOS (Xcode 13.3)
• Xcode at /Applications/Xcode.app/Contents/Developer
• CocoaPods version 1.11.3
[✓] Chrome - develop for the web
• Chrome at /Applications/Google Chrome.app/Contents/MacOS/Google Chrome
[✓] Android Studio (version 2021.1)
• Android Studio at /Applications/Android Studio.app/Contents
• Flutter plugin can be installed from:
🔨 https://plugins.jetbrains.com/plugin/9212-flutter
• Dart plugin can be installed from:
🔨 https://plugins.jetbrains.com/plugin/6351-dart
• Java version OpenJDK Runtime Environment (build 11.0.11+0-b60-7590822)
[✓] IntelliJ IDEA Ultimate Edition (version 2020.3.2)
• IntelliJ at /Applications/IntelliJ IDEA.app
• Flutter plugin can be installed from:
🔨 https://plugins.jetbrains.com/plugin/9212-flutter
• Dart plugin can be installed from:
🔨 https://plugins.jetbrains.com/plugin/6351-dart
[✓] VS Code (version 1.65.2)
• VS Code at /Applications/Visual Studio Code.app/Contents
• Flutter extension version 3.38.1
[✓] Connected device (2 available)
• iPhone 13 (mobile) • 9ABDFA93-B9CF-45DE-A860-E1023FF33AB9 • ios • com.apple.CoreSimulator.SimRuntime.iOS-15-4 (simulator)
• Chrome (web) • chrome • web-javascript • Google Chrome 100.0.4896.75
[✓] HTTP Host Availability
• All required HTTP hosts are available
• No issues found!
@Smibser Please run
flutter clean
flutter pub get
then
Run the project
if what @ariefwijaya dont work, can you share a working example that reproduce the issue? I am not able to reproduce it
The problem appears when there are configuration keys in the Info.plist
file (the deprecated ones). The PR #94 added a boolean wasSetupFromFile
that is causing the problem when there are two setups, from Info.plist
and from dart method Segment.config
. The solution is to simply remove the configuration keys from Info.plist
.
We should remove the deprecated configs 🤔
We probably should add that to the README, and also remove the boolean wasSetupFromFile
as the configuration file is no longer needed/supported.
Mm I see that theres a method that handles this:
@Smibser the issue happens on which device? android or iOS?
This may be related to this issues:
@limonadev the feature exists for compatibility reasons, its deprecated but it should work, if it is not working... to me we can remove the deprecated code since the warning exists since 2021, feel free to send a contribution :)
Since I updated flutter_segment to 3.7.0 I get the following exception on app start when I call
Segment.config(...)
The last working version is 3.3.0