Concatenation not working in flutter, instead, variable breaks into two lines? - flutter

So, this is a very small problem, but totally annoying!
This is my code:
print('COORDINATES -> ${lat}:${lng}');
As you can see, it should print out, example: '74.23132:47.13123' right?
But instead it goes like this..
flutter: COORDINATES -> 74.23132:
47.13123
Is it really suppose to work like that in flutter?
Best regards!
flutter doctor -v
[✓] Flutter (Channel stable, v1.7.8+hotfix.3, on Mac OS X 10.14.5 18F203, locale en-GB)
• Flutter version 1.7.8+hotfix.3 at /Users/usr/Developer/flutter
• Framework revision b712a172f9 (9 days ago), 2019-07-09 13:14:38 -0700
• Engine revision 54ad777fd2
• Dart version 2.4.0
[✓] Android toolchain - develop for Android devices (Android SDK version 28.0.3)
• Android SDK at /Users/usr/Library/Android/sdk
• Android NDK location not configured (optional; useful for native profiling support)
• Platform android-28, build-tools 28.0.3
• Java binary at: /Applications/Android Studio 3.5 Preview.app/Contents/jre/jdk/Contents/Home/bin/java
• Java version OpenJDK Runtime Environment (build 1.8.0_202-release-1483-b49-5587405)
• All Android licenses accepted.
[✓] Xcode - develop for iOS and macOS (Xcode 10.2.1)
• Xcode at /Applications/Xcode.app/Contents/Developer
• Xcode 10.2.1, Build version 10E1001
• CocoaPods version 1.7.0
[✓] iOS tools - develop for iOS devices
• ios-deploy 1.9.4
[✓] Android Studio (version 3.5)
• Android Studio at /Applications/Android Studio 3.5 Preview.app/Contents
• Flutter plugin version 37.1.3
• Dart plugin version 191.7830
• Java version OpenJDK Runtime Environment (build 1.8.0_202-release-1483-b49-5587405)
[✓] Connected device (2 available)
• Mattias’s iPhone • aaf4a41bc5a93fcf273e2070e19ec2a6a3f37921 • ios • iOS 12.3.1
• iPhone Xʀ • 93F3E348-5835-492B-B756-CCD1BAD6C8E8 • ios • com.apple.CoreSimulator.SimRuntime.iOS-12-2 (simulator)
• No issues found!

SOLUTION
After trying every logic step to accomplish this, it turns out that the flutter-team hasn't supported this yet! So don't even get into this ever, until flutter support two variables in concatenating. Very very sad to let you know!

Related

flutter failed to connect android device and off application on iPhone simulator

when I call debug mode on an android device
Error connecting to the service protocol: failed to connect to http://127.0.0.1:60027/bncnE_T-mWw=/
and also asks for permission to wifi, but through a notification, if I give permission, it shows a white screen and the same error
but everything starts quietly if you build the apk and install through it
with an iPhone simulator, the application starts and immediately closes, and in the android studio it is written that the connection is taking too long, it may have crashed
flutter doctor:
[✓] Flutter (Channel stable, 2.5.0, on Mac OS X 10.15.7 19H114 darwin-x64, locale ru-RU)
• Flutter version 2.5.0 at /Users/daniil/Documents/flutter
• Upstream repository https://github.com/flutter/flutter.git
• Framework revision 4cc385b4b8 (6 days ago), 2021-09-07 23:01:49 -0700
• Engine revision f0826da7ef
• Dart version 2.14.0
[✓] Android toolchain - develop for Android devices (Android SDK version 31.0.0)
• Android SDK at /Users/daniil/Library/Android/sdk
• Platform android-31, build-tools 31.0.0
• Java binary at: /Applications/Android Studio.app/Contents/jre/jdk/Contents/Home/bin/java
• Java version OpenJDK Runtime Environment (build 11.0.8+10-b944.6916264)
• All Android licenses accepted.
[✓] Xcode - develop for iOS and macOS
• Xcode at /Applications/Xcode.app/Contents/Developer
• Xcode 12.4, Build version 12D4e
• CocoaPods version 1.10.1
[✓] Chrome - develop for the web
• Chrome at /Applications/Google Chrome.app/Contents/MacOS/Google Chrome
[✓] Android Studio (version 4.2)
• 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.8+10-b944.6916264)
[✓] VS Code (version 1.58.0)
• VS Code at /Applications/Visual Studio Code.app/Contents
• Flutter extension version 3.24.0
[✓] Connected device (3 available)
• Redmi Note 8T (mobile) • 19645373 • android-arm64 • Android 10 (API 29)
• iPhone 8 Plus (mobile) • 06EE905E-8A76-45D5-A844-8DCDF2EEA3CA • ios • com.apple.CoreSimulator.SimRuntime.iOS-14-4 (simulator)
• Chrome (web) • chrome • web-javascript • Google Chrome 93.0.4577.63
• No issues found!
Android the problem was solved by delete update "security" on firmware MIUI

Flutter , Debug Error without Explanation

when debugging , I am facing an issue ,
the debug error is missing the explanation and details.
here is the debug console output :
any idea what is the problem here :
attached Flutter Doctor :
## Flutter Doctor ##
[✓] Flutter (Channel stable, 1.22.1, on Mac OS X 10.15.6 19G2021, locale en-EG)
• Flutter version 1.22.1 at /Users/XXXXX/flutter
• Framework revision f30b7f4db9 (7 days ago), 2020-10-08 10:06:30 -0700
• Engine revision 75bef9f6c8
• Dart version 2.10.1
[✓] Android toolchain - develop for Android devices (Android SDK version 29.0.2)
• Android SDK at /Users/XXXXXX/Library/Android/sdk
• Platform android-29, build-tools 29.0.2
• Java binary at: /Applications/Android
Studio.app/Contents/jre/jdk/Contents/Home/bin/java
• Java version OpenJDK Runtime Environment (build 1.8.0_242-release-1644-b3-6222593)
• All Android licenses accepted.
[✓] Xcode - develop for iOS and macOS (Xcode 11.6)
• Xcode at /Applications/Xcode.app/Contents/Developer
• Xcode 11.6, Build version 11E708
• CocoaPods version 1.8.4
[✓] Android Studio (version 4.0)
• Android Studio at /Applications/Android Studio.app/Contents
• Flutter plugin version 50.0.1
• Dart plugin version 193.7547
• Java version OpenJDK Runtime Environment (build
1.8.0_242-release-1644-b3-6222593)
[✓] IntelliJ IDEA Community Edition (version 2019.1.1)
• IntelliJ at /Applications/IntelliJ IDEA CE.app
• Flutter plugin version 34.0.4
• Dart plugin version 191.6183.88
[✓] VS Code (version 1.48.2)
• VS Code at /Applications/Visual Studio Code.app/Contents
• Flutter extension version 3.12.2
[✓] Connected device (3 available)
• iPhone 11 Pro Max (mobile) • AECA9290-F1AE-45BF-8D0C-6D6A7F6B648D • ios •
com.apple.CoreSimulator.SimRuntime.iOS-13-6 (simulator)
• No issues found!

VSCode cannot run flutter app after upgrading Flutter to release 1.20.0 and VSCode Flutter plugin to 1.13.1

Using MacOS and VSCode. Just upgraded Flutter to release 1.20.0 and now I cannot start my project in debug mode (F5) from within VSCode on my iPhone simulator.
If I execute on the terminal
flutter run
everything is working as expected.
Output of flutter doctor -v:
[✓] Flutter (Channel stable, 1.20.0, on Mac OS X 10.15.6 19G73, locale es-ES)
• Flutter version 1.20.0 at /Applications/flutter
• Framework revision 840c9205b3 (12 hours ago), 2020-08-04 20:55:12 -0700
• Engine revision c8e3b94853
• Dart version 2.9.0
[✓] Android toolchain - develop for Android devices (Android SDK version 29.0.3)
• Android SDK at /Users/abibiano/Library/Android/sdk
• Platform android-29, build-tools 29.0.3
• Java binary at: /Applications/Android Studio.app/Contents/jre/jdk/Contents/Home/bin/java
• Java version OpenJDK Runtime Environment (build 1.8.0_202-release-1483-b49-5587405)
• All Android licenses accepted.
[✓] Xcode - develop for iOS and macOS (Xcode 11.6)
• Xcode at /Applications/Xcode.app/Contents/Developer
• Xcode 11.6, Build version 11E708
• CocoaPods version 1.8.4
[✓] Android Studio (version 3.5)
• Android Studio at /Applications/Android Studio.app/Contents
• Flutter plugin version 43.0.1
• Dart plugin version 191.8593
• Java version OpenJDK Runtime Environment (build 1.8.0_202-release-1483-b49-5587405)
[✓] VS Code (version 1.47.3)
• VS Code at /Applications/Visual Studio Code.app/Contents
• Flutter extension version 3.13.1
[✓] Connected device (1 available)
• iPhone SE (2nd generation) (mobile) • C2027E6D-0C59-4B06-94BC-12382916EE09 • ios •
com.apple.CoreSimulator.SimRuntime.iOS-13-6 (simulator)
• No issues found!
It's fixed.
Please update the vscode plugin for dart.
https://github.com/Dart-Code/Dart-Code/issues/2702

Dart code snippets don't show in-line with stacktraces on the sentry dashboard

Stacktraces from python - beautiful inline code
Stacktraces from dart - no inline code snippets :(
I understand that python is a super dynamic language and can pick up the code using magic like the inspect module, but is there a way to "give" sentry my dart code too?
Dupe of flutter/#63276
fluter doctor -v
[✓] Flutter (Channel stable, v1.17.5, on Mac OS X 10.14.6 18G4032, locale en)
• Flutter version 1.17.5 at /Users/dev/Tools/flutter
• Framework revision 8af6b2f038 (6 weeks ago), 2020-06-30 12:53:55 -0700
• Engine revision ee76268252
• Dart version 2.8.4
[✓] Android toolchain - develop for Android devices (Android SDK version 29.0.3)
• Android SDK at /Users/dev/Library/Android/sdk
• Platform android-29, build-tools 29.0.3
• Java binary at: /Users/dev/Library/Application Support/JetBrains/Toolbox/apps/AndroidStudio/ch-1/192.6392135/Android
Studio.app/Contents/jre/jdk/Contents/Home/bin/java
• Java version OpenJDK Runtime Environment (build 1.8.0_212-release-1586-b4-5784211)
• All Android licenses accepted.
[✓] Xcode - develop for iOS and macOS (Xcode 11.2.1)
• Xcode at /Applications/Xcode.app/Contents/Developer
• Xcode 11.2.1, Build version 11B500
• CocoaPods version 1.8.4
[✓] Android Studio (version 3.6)
• Android Studio at /Users/dev/Library/Application Support/JetBrains/Toolbox/apps/AndroidStudio/ch-1/192.6392135/Android
Studio.app/Contents
• Flutter plugin version 45.1.1
• Dart plugin version 192.8052
• Java version OpenJDK Runtime Environment (build 1.8.0_212-release-1586-b4-5784211)
[✓] VS Code (version 1.46.1)
• VS Code at /Applications/Visual Studio Code.app/Contents
• Flutter extension version 3.12.1
[✓] Connected device (1 available)
• POCO F1 • e19ec1f6 • android-arm64 • Android 10 (API 29)
• No issues found!
This is not yet supported.
It might not be possible to add at all since it depends on some level of support from the platform. One approach is to allow users to run sentry-cli to upload a "source bundle" and on the server we lookup the relevant lines of code on that bundle as the events come in. This is done for some platforms.
I'll update this answer if the situation changes.
I made a comment on the GitHub issue too.

In flutter firebase cloud messaging is not working in oneplus 6/6t in production

In debug mode firebase cloud messaging is working fine in all phones but in production its not working in oneplus phones but its working fine in samsung phones. Battery optimization is not the issue,
I have seen solutions like setting channel id etc... if it is the solution can u please guide me with the solution in dart.
I am new to flutter ,and now stuck with this bug
[✓] Flutter (Channel stable, v1.17.5, on Mac OS X 10.15.5 19F101, locale en-IN) • Flutter version 1.17.5 at /users/rohitmadhu/Documents/flutter • Framework revision 8af6b2f038 (2 weeks ago), 2020-06-30 12:53:55 -0700 • Engine revision ee76268252 • Dart version 2.8.4
[✓] Android toolchain - develop for Android devices (Android SDK version 29.0.2) • Android SDK at /Users/rohitmadhu/Library/Android/sdk • Platform android-29, build-tools 29.0.2 • Java binary at: /Applications/Android Studio.app/Contents/jre/jdk/Contents/Home/bin/java • Java version OpenJDK Runtime Environment (build 1.8.0_202-release-1483-b49-5587405) • All Android licenses accepted.
[✓] Xcode - develop for iOS and macOS (Xcode 11.5) • Xcode at /Applications/Xcode.app/Contents/Developer • Xcode 11.5, Build version 11E608c • CocoaPods version 1.9.3
[✓] Android Studio (version 3.5) • Android Studio at /Applications/Android Studio.app/Contents • Flutter plugin version 44.0.1 • Dart plugin version 191.8593 • Java version OpenJDK Runtime Environment (build 1.8.0_202-release-1483-b49-5587405)
[✓] VS Code (version 1.47.0) • VS Code at /Applications/Visual Studio Code.app/Contents • Flutter extension version 3.12.2
[✓] Connected device (1 available) • Rohit • 2d314272e0c5e22659a0de1a57d7ccc8915fc944 • ios • iOS 13.5.1
I am not sure about this solution is correct or not but it worked for me
Once you update SHA-1 in firebase in some devices we need uninstall the app and need to reinstall, just updating new version from play store was causing this issue.
thank you for all who spend time for this question.