getsentry / sentry-dart Goto Github PK
View Code? Open in Web Editor NEWSentry SDK for Dart and Flutter
Home Page: https://sentry.io/for/flutter/
License: MIT License
Sentry SDK for Dart and Flutter
Home Page: https://sentry.io/for/flutter/
License: MIT License
For now the package has almost 200 errors with NNDB activated cf. https://dart.dev/null-safety
Sentry's SDKs have a Debug
mode which helps troubleshoot issues with the SDK itself.
Add the ability to opt-in to internal SDK logging and replace the actual logging object.
The SDK still misses a SentryOptions
class used to hold options used for initialization of the SDK. That means we'd add:
SentryOptions
and allow initializing the SDK with itboolean
option called debug
to SentryOptions
This allows us to see what's going on in the SDK when using logcat for example. It'd also be possible to adapt to a logger library so that logs are persisted to disk or sent to a logging aggregation service.
Copied over from flutter/flutter#59075
On sentry_flutter: ^4.0.0-alpha.2
After initialize sentry, sentry will automatically uploads 'Flutter Error', Uncontrolled. Full code:
// main.dart
import 'dart:async';
import 'package:sentry_flutter/sentry_flutter.dart';
import 'package:flutter/material.dart';
void main() {
// release: true, debug|profile: false
// As suggested by: https://twitter.com/FlutterDev/status/1048278525432791041
const bool isProduction = const bool.fromEnvironment('dart.vm.product');
// handle Flutter error
FlutterError.onError = (FlutterErrorDetails details,) async {
if (!isProduction) {
FlutterError.dumpErrorToConsole(details);
return;
}
// turn to Zone
Zone.current.handleUncaughtError(details.exception, details.stack);
};
// Handle dart error
runZonedGuarded<Future<void>>(() async {
SentryFlutter.init((options) => options.dsn = 'xxx',
() {
runApp(MyApp());
},
);
}, (Object error, StackTrace stackTrace) async {
if (!isProduction) {
print(error);
print(stackTrace);
return;
}
// Only upload error on release mode
Sentry.captureException(
error,
stackTrace: stackTrace,
);
});
}
class MyApp extends StatelessWidget {
@override
Widget build(BuildContext context) {
return MaterialApp(
title: 'Exception Demo',
theme: ThemeData(
primarySwatch: Colors.blue,
),
home: Scaffold(
backgroundColor: Colors.white,
appBar: AppBar(
title: Text('Error test'),
),
// https://flutter.dev/docs/testing/common-errors#a-renderflex-overflowed
body: Row(
children: [
Column(
crossAxisAlignment: CrossAxisAlignment.start,
children: [
Text("Title", style: Theme.of(context).textTheme.headline4),
Text(
"Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed"
" do eiusmod tempor incididunt ut labore et dolore magna "
"aliqua. Ut enim ad minim veniam, quis nostrud "
"exercitation ullamco laboris nisi ut aliquip ex ea "
"commodo consequat."),
],
),
],
)
)
);
}
}
The above code triggered a Flutter error(layout error).
In debug mode running, Sentry still upload error.
the latest version shipped Android 11 and iOS 14 support, we need to test it
Setting up Sentry on our flutter app, we instantiate the SentryClient just by adding the dsn param and no other context as instructed. Exceptions get catched in the guarded zone and using FlutterError.onError.
Later on the the execution of the code, a user signs in, so we'd like to add that information to next errors. I don't see a client.identify method, which is the strategy crashlytics uses (what we use now) FirebaseCrashlytics.instance.setUserIdentifier(_currentUser.userId);
. We can't add that context on app start, and we can't access current user since it's not global.
How should we make Sentry aware of that context at any point of the code?
This might not be a full feature request maybe more of a documentation request, not sure. It is about Flutter integration.
With the 3.x version I have manually built SentryEvent
s and added all the context information like Device
, App
, OperatingSystem
and so on, using a bunch of different plugins (connectivity, timezone, platform etc.). For me it is not very clear which of this information is now automatically added due to the native integrations. So there are a couple questions that I have not found (fully) answered in code or documentation.
LoadContextsIntegration
produce?LoadContextsIntegration
on Android?EventProcessor
s it is currently hard to add information to the nested structure of the event. Only SentryEvent
has a copyWith(...)
function. Ideally there could be similar copy functions for all the nested context classes so that one could do things like the following which is currently very hard to achieve as all the children have to be rebuild completely.final connectivityResult = await Connectivity().checkConnectivity();
final online = connectivityResult != ConnectivityResult.none;
return event.copyWith(
contexts: event.contexts.copyWith(
device: (event.contexts.device ?? Device()).copyWith(
online: online,
),
),
);
Flutter is gearing up towards null-safety.
This issue is to track progress adding support to it.
sentry
#298sentry_flutter
#337Related to #99
The migration steps are here: https://dart.dev/null-safety/migration-guide
Important to note we should start by migrating our dependencies to the null safety version.
uuid
support tracking: daegalus/dart-uuid#50http
support tracking: dart-lang/http#501device_info
seems to be almost theresentry_flutter: ^4.0.0-alpha.2
Sentry.configureScope((Scope scope) async {
scope.user = User(id: xxx);
});
The user information was set in the flutter and did not synchronize in native(Android).
Hope to add this feature, thanks
I would like to request support for navigation breadcrumbs.
The motivation is, that a developer can better recreate the user flow to track down the reported crash.
This can be implemented using Flutters NavigatorObserver or RouteObserver.
A very simplisitic example of this feature could like this:
(Please note that I haven't confirmed if this actually compiles. It is just meant as an illustration of possible solution.)
import 'package:flutter/widgets.dart';
import 'package:sentry_flutter/sentry_flutter.dart';
Future<void> main() async {
await SentryFlutter.init(
(options) {
options.dsn = 'https://[email protected]/add-your-dsn-here';
// For better groupping, change the 'example' below with your own App's package.
options.addInAppInclude('sentry_flutter_example');
},
() {
runApp(MyApp())
},
);
}
}
class MyApp extends StatelessWidget {
@override
Widget build(BuildContext context) {
return MaterialApp(
navigatorObservers: [
SentryNavigatorObserver(),
],
theme: ThemeData.dark().copyWith(scaffoldBackgroundColor: darkBlue),
debugShowCheckedModeBanner: false,
home: Scaffold(
body: Center(
child: MyWidget(),
),
),
);
}
}
class SentryNavigatorObserver extends NavigatorObserver {
void didPush(Route<dynamic> route, Route<dynamic> previousRoute) {
addBreadcrumb(route.settings.name, "wasPushed");
}
void didPop(Route<dynamic> route, Route<dynamic> previousRoute) {
addBreadcrumb(route.settings.name, "wasPopped");
}
void didRemove(Route<dynamic> route, Route<dynamic> previousRoute) {
addBreadcrumb(route.settings.name, "wasRemoved");
}
void didReplace({ Route<dynamic> newRoute, Route<dynamic> oldRoute }) {
addBreadcrumb(newRoute.settings.name, "didReplace");
}
void addBreadCrumb(String routeName, String type) {
Sentry.addBreadcrumb(Breadcrumb(
message: routeName,
category: "navigation",
type: type,
));
}
void didStartUserGesture(Route<dynamic> route, Route<dynamic> previousRoute) {
// no breadcrumb needed
}
void didStopUserGesture() {
// no breadcrumb needed
}
}
On debug mode, on app startup, I am seeing this log:
/Sentry (24193): sentry-debug-meta.properties file was not found.
I/Sentry (24193): Initializing SDK with DSN: 'https://xxxxx.ingest.sentry.io/xxxx'
D/Sentry (24193): SU doesn't exist.
D/Sentry (24193): java.io.IOException: Cannot run program "/system/xbin/which": error=2, No such file or directory
D/Sentry (24193): at java.lang.ProcessBuilder.start(ProcessBuilder.java:1050)
D/Sentry (24193): at java.lang.Runtime.exec(Runtime.java:698)
D/Sentry (24193): at java.lang.Runtime.exec(Runtime.java:563)
D/Sentry (24193): at io.sentry.android.core.util.RootChecker.checkSUExist(RootChecker.java:135)
D/Sentry (24193): at io.sentry.android.core.util.RootChecker.isDeviceRooted(RootChecker.java:90)
D/Sentry (24193): at io.sentry.android.core.DefaultAndroidEventProcessor.loadContextData(DefaultAndroidEventProcessor.java:114)
D/Sentry (24193): at io.sentry.android.core.DefaultAndroidEventProcessor.lambda$new$0$DefaultAndroidEventProcessor(DefaultAndroidEventProcessor.java:102)
D/Sentry (24193): at io.sentry.android.core.-$$Lambda$DefaultAndroidEventProcessor$NYQ5qA7CeWYLjnxHfVDRm7bpPQ0.call(Unknown Source:2)
D/Sentry (24193): at java.util.concurrent.FutureTask.run(FutureTask.java:266)
D/Sentry (24193): at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1167)
D/Sentry (24193): at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:641)
D/Sentry (24193): at java.lang.Thread.run(Thread.java:919)
D/Sentry (24193): Caused by: java.io.IOException: error=2, No such file or directory
D/Sentry (24193): at java.lang.UNIXProcess.forkAndExec(Native Method)
D/Sentry (24193): at java.lang.UNIXProcess.<init>(UNIXProcess.java:133)
D/Sentry (24193): at java.lang.ProcessImpl.start(ProcessImpl.java:141)
D/Sentry (24193): at java.lang.ProcessBuilder.start(ProcessBuilder.java:1029)
D/Sentry (24193): ... 11 more
It's not causing any crash apparently, but I'd prefer to double check before shipping it :)
flutter doctor
below:[✓] Flutter (Channel stable, 1.22.4, on Mac OS X 10.15.7 19H15 darwin-x64, locale es-ES)
[✓] Android toolchain - develop for Android devices (Android SDK version 29.0.2)
[✓] Xcode - develop for iOS and macOS (Xcode 11.5)
[✓] Android Studio (version 4.1)
[✓] VS Code (version 1.51.1)
[✓] Connected device (1 available)
I am using alpha
sentry_flutter: ^4.0.0-alpha.2
I would like to request support for HTTP breadcrumbs for Sentry-Dart.
A possible solution could look like this:
import 'package:http/http.dart' as http;
import 'package:http/http.dart';
import 'package:sentry/sentry.dart';
class SentryHttpClient extends http.BaseClient {
SentryHttpClient(this._inner);
final http.Client _inner;
@override
Future<StreamedResponse> send(BaseRequest request) async {
final response = await _inner.send(request);
Sentry.addBreadcrumbs(
Breadcrumb(
message: null,
type: 'http',
data: {
'url': request.url.toString(),
'method': request.method,
'status_code': response.statusCode.toString(),
'reason': response.reasonPhrase,
},
),
);
return response;
}
}
There is very little support for Flutter web at the moment. However, just want to know if its possible for there to be a support for Flutter SDK. The performance monitoring feature is a amazing and I would like to implementing it in my Flutter web project.
OS Version: Android 5.1.1 (LMY47V.T280XXU0AQJ1)
Report Version: 104
Exception Type: Unknown (SIGABRT)
Application Specific Information:
Abort
Thread 0 Crashed:
0 libc.so 0xb6e59eb4 tgkill
1 libc.so 0xb6e36735 pthread_kill
2 libc.so 0xb6e3734b raise
3 libc.so 0xb6e33be5 <unknown> + 3068345317
4 libc.so 0xb6e31f74 <unknown> + 3068338036
5 libflutter.so 0xa2da3cbb <unknown> + 2732211387
6 <unknown> 0xa2a495c8 <unknown>
flutter doctor
below:[✓] Flutter (Channel stable, 1.22.3, on macOS 11.0.1 20B29, locale en-GB)
[✓] Android toolchain - develop for Android devices (Android SDK version 29.0.2)
[✓] Xcode - develop for iOS and macOS (Xcode 12.3)
[✓] Android Studio (version 3.5)
[✓] VS Code (version 1.52.0)
Appreciate if someone share any thoughts about this kind of error.
Thanks!!
Client
method calls have redundant naming.
client.captureEvent(event: event);
should be:
client.captureEvent(event);
Same for client.captureException()
I would like to request support for Sentry's User Feedback.
I see at least two possibilities on how to do this:
By providing a more elaborate SentryFlutter.captureException
like for example:
SentryFlutter.captureException(
exception: error,
stackTrace: stackTrace,
context: context, // this is a BuildContext
);
With a BuildContext
one can show a dialog (see showDialog) which can be used to gather the user's feedback.
Another option would be by overriding ErrorWidget.builder (aka Flutter's infamous Red Screen of Death).
This way one could could also capture and report the errors which get passed into ErrorWidget.builder
. These are errors
which are happening during the creation of the UI.
An example (more or less pseudo code):
// We assume SentryOptions has a ErrorWidgetBuilder named errorWidgetBuilder which can be defined by the user.
// By providing the same callback it is easy to migrate to this.
class UserFeedback {
// ...
}
class UserFeedbackErrorWidget extends StatefulWidget {
const YellowBird({ Key key, this.details, this.options }) : super(key: key);
final FlutterErrorDetails details;
final SentryOptions options;
@override
_UserFeedbackErrorWidgetState createState() => _UserFeedbackErrorWidgetState();
}
class _UserFeedbackErrorWidgetState extends State<UserFeedbackErrorWidget> {
@override
void initState(){
super.initState();
// one can't open a dialog in initState
// see https://stackoverflow.com/questions/51766977/flutter-showdialogcontext-in-initstate-method
Future.delayed(Duration.zero, askForUserFeedback)
}
@override
Widget build(BuildContext context) {
// This way a user defined widget is shown inline in the ui.
// It's nice for the user, because it is not very intrusive.
return options.errorWidgetBuilder(widget.details);
}
Future<void> askForUserFeedback() {
final error = widget.details;
final sentryId = await Sentry.captureException(error);
// showDialog returns what is given to Navigator.pop(...)
final feedback = await showDialog<UserFeedback>(context, (innerContext){
// show dialog, where the user can input additional information and return it
return UserFeedbackDialog(
onSubmit: (feedback) => Navigator.pop(innerContext, feedback)
);
});
await Sentry.sendFeedback(sentryId, feedback);
}
}
Now we can set ErrorWidget.builder
inside an Integration
with
ErrorWidget.builder = (FlutterErrorDetails details) => UserFeedbackErrorWidget(details: details, options: sentryOptions);
I guess providing both options would be optimal.
If there are any questions, I'm happy to help.
sentry_flutter versions: https://pub.dev/packages/sentry_flutter/versions
Only 1 version: 4.0.0-alpha.2. Alpha meaning not safe.I can't use safe 3.x version
Compare dio versions: https://pub.dev/packages/dio/versions
Dio has all versions.
Do you plan on adding this feature for the flutter package ?
We'd like to update the docs to state the changes on #100 and #101 and any other breaking changes
We don't have a Dart platform, but we do have a Flutter one:
https://docs.sentry.io/platforms/flutter/
docs: https://github.com/getsentry/sentry-docs/tree/master/src/platforms/flutter
wizard: https://github.com/getsentry/sentry-docs/tree/master/src/wizard/flutter
We might need a migration guide like:
https://docs.sentry.io/platforms/android/migration/
Please describe the issue and how to reproduce it, or link to a small reproducible application:
I am trying to use sentry and i am getting the error undefined method.
The function 'runZonedGuarded' isn't defined. Try importing the library that defines 'runZonedGuarded', correcting the name to the name of an existing function, or defining a function named 'runZonedGuarded'
Include the output of the command flutter doctor
below:
[✓] Flutter (Channel beta, 1.20.2, on Mac OS X 10.14.5 18F132, locale en-GB)
[!] Android toolchain - develop for Android devices (Android SDK version 28.0.3)
! Some Android licenses not accepted. To resolve this, run: flutter doctor --android-licenses
[✓] Xcode - develop for iOS and macOS (Xcode 11.3.1)
[!] Android Studio (version 3.1)
✗ Flutter plugin not installed; this adds Flutter specific functionality.
✗ Dart plugin not installed; this adds Dart specific functionality.
[✓] Connected device (1 available)
! Doctor found issues in 2 categories.
WidgetsFlutterBinding.ensureInitialized();
The FlutterErrorIntegration does not respect the silent flag of FlutterErrorDetails
. There is probably a good reason for that, so maybe Sentry should respect that?
I am trying to setup sentry for flutter and while configuring the configureScope it throws
[error] Error in the 'configureScope' callback.
Code:
sentry_flutter: ^4.0.0
main.dart:
import 'package:sentry_flutter/sentry_flutter.dart';
await SentryFlutter.init((options) {
options.dsn = ServiceKeys.SENTRY_DSN;
options.useFlutterBreadcrumbTracking();
options.useNativeBreadcrumbTracking();
});
log.dart
import 'package:sentry_flutter/sentry_flutter.dart';
Sentry.configureScope((scope) => scope
..setTag('App version', '1.1.1+1')
..user = User(
id: '1234',
email: '[email protected]',
);
Sentry.captureException(
_errorBody,
stackTrace: stackTrace,
);
Interestingly, the errors aren't showing up in the sentry dashboard when I use sentry_flutter package, but when I use the sentry package, instead, the exceptions are getting logged and the configureScope
works perfectly alright.
What do I do?
flutter doctor
below:[✓] Flutter (Channel stable, 1.22.3, on Mac OS X 10.15.6 19G73, locale en-IN)
[✓] Android toolchain - develop for Android devices (Android SDK version
29.0.3)
[✓] Xcode - develop for iOS and macOS (Xcode 11.6)
[✓] Connected device (1 available)
how is our current value? can we run locally for the Dart folder?
I install self host sentry by docker. In my flutter Application by using runZonedGuarded
:
void main() => runZonedGuarded(() async {
await SentryFlutter.init(
(options) {
options.dsn =
"http://[email protected]:9000/2";
options.debug = true;
},
appRunner: () => runApp(MyApp()),
);
}, (exception, StackTrace stackTrace) async {
await Sentry.captureException(
exception,
stackTrace: stackTrace,
);
});
I am trying to report exception on Android emulator but i got:
java.net.ConnectException: Failed to connect to /127.0.0.1:9000
How can i change 127.0.0.1 on sentry ?It is possible to change from dashboard?
Add code coverage to CI.
The GH Action we were blocked by is fixed: #110
I am trying to migrate from the flutter_sentry package which has this option.
In hindsight I found myself using this often to test the correct integration.
It would be great if there was something like SentryFlutter.nativeCrash()
which would use the method channel to create an example crash on the native side.
Hi,
Everytime I see crashes into the Sentry Console, I'm unable to know which app version has encountered the bug. The crash report doesn't specify the app version (build version).
I tried to manually specify it in the Sentry initialization but there are no methods for that yet.
Do you plan to add it in a near future ? This is very hard to know if the crash has been fixed in newer versions because we can't see which app version the user has got neither if it's an Android or Apple device.
Best regards,
PR getsentry/sentry-flutter#1 was attempting that but became stale.
I've attempted using this on a dogfooding project which so far seems like my prefered API:
https://github.com/bruno-garcia/badges.bar/blob/main/lib/src/sentry/sentry.dart
the pub.dev analysis score removes 5 points when there is no changelog file in a package.
cf. #96
Added version in flutter project
dependencies:
sentry: ">=4.0.0 <5.0.0"
However am getting the error
Because app depends on sentry ^4.0.0 which doesn't match any versions, version solving failed.
pub get failed (1; Because app depends on sentry ^4.0.0 which doesn't match any versions, version solving failed.)
flutter doctor
below:Sentry accepts the breadcrumb data as complex JSON content.
This is currently not possible to send as the data field is currently final Map<String, String> data;
.
Other SDKs also accept object types as values.
When the data fields are JSON objects, data scrubbing would work on the fields. Atm I have to transform objects to Strings and data scrubbing doesn't work.
Btw, the issue templates are still for the sentry_flutter package if anyone can change this.
We're releasing 4.0.0 which is a big major version so it's time to discuss the min Dart SDK version we want to support on the sentry
package.
Important notes:
I'd propose we set the min version to 2.7:
Line 9 in cc913bf
To clarify: What would we leaving behind? Is there a reason folks using AngularDart can't be on Dart 2.7?
I tried to implement sentry package to my Flutter application.
It happens to successfully log Flutter-specific errors (like UI crashes or Platform Exceptions), but when it comes to logging the non-crashing exceptions (or dart errors) - it just fails.
I tried with runZoned, but it doesn't work also.
Here's my code:
void main() {
WidgetsFlutterBinding.ensureInitialized();
RemoteConfigModel remoteConfigModel = GetIt.instance<RemoteConfigModel>();
SentryClient sentryClient = new SentryClient(dsn: remoteConfigModel.sentryDSN);
runZonedGuarded( () {
runApp(MyApp());
},
(Object error, StackTrace stackTrace) {
print("Enters onError.");
try {
sentryClient.captureException(
exception: error,
stackTrace: stackTrace,
);
} catch (e) {
debugPrint("ERROR::: Logging in sentry failed. Exception $e");
debugPrint('Original error: $error');
}
}
);
FlutterError.onError = (details, {bool forceReport = false}) {
debugPrint("Flutter-specific error.");
try {
sentryClient.captureException(
exception: details.exception,
stackTrace: details.stack,
);
} catch (e) {
print('Sending report to sentry.io failed: $e');
} finally {
FlutterError.dumpErrorToConsole(details, forceReport: forceReport);
}
};
}
We'd like to add the Sentry static API to Dart:
https://develop.sentry.dev/sdk/unified-api/#static-api
the idea is one will be able to Sentry.captureException(x)
, Sentry.captureMessage(x)
, Sentry.captureEvent(x)
, Sentry.init(options -> {})
Today the SDK is initialized via SentryClient
which has no Hub
and Scope
.
we don't need to care for globalHubMode
that we have on Java.
Also, we don't need a ThreadLocal
on Dart because the language is already single-threaded (is that the right term?).
This issue could have sub-issues like:
So TLDR:
The Sentry.init
creates a Hub
, the Hub
creates and maintains a SentryClient
and a Scope
.
See the workflow: https://develop.sentry.dev/sdk/unified-api/#simplified-visualization
We could have a feature branch for this issue as we'd need to collaborate together, and each item of this task would depend on each other.
Let's add the logEntry to the SentryEvent:
https://develop.sentry.dev/sdk/event-payloads/message/
https://github.com/getsentry/sentry-dart/blob/main/dart/lib/src/protocol/event.dart#L49-L52
the current message
becomes its own class with formatted
, message
and params
fields
yml files need to be inside of .github/workflows
We have a production app that crashes under certain conditions. The crash does not seem to be reported in Sentry.
flutter doctor
below:not relevant
--
Would Sentry pick up a native code crash, f.e. something with a plugin or an exception not happening in dart/flutter?
I can see the source code asks for Sentry cocoa sdk to be installed and configured. Just wanted to double check before we go around adding native Sentry SDK libraries as well to catch additional errors.
Thanks!
This breadcrumb should be analog to this Android breadcrumb.
Currently it is more like an Activity-Lifecycle event despite being an application wide lifecycle event.
I've stumbled across this, while researching this.
It would be nice if sentry got official Flutter support, they support it as mentioned over here: https://flutter.dev/docs/cookbook/maintenance/error-reporting
We currently only have docs and wizard for Flutter.
Once we add dart: https://docs.sentry.io/platforms/dart/ we need to change:
Link to the docs on the footer: https://github.com/getsentry/sentry-dart/blob/main/dart/README.md#L63
pubspec homepage URL: https://github.com/getsentry/sentry-dart/blob/main/dart/pubspec.yaml#L6 to the docs.
E/FileObserver(13655): Unhandled exception in FileObserver io.sentry.android.core.EnvelopeFileObserver@94251ab
E/FileObserver(13655): java.lang.IllegalArgumentException: Invalid envelope. Item at index '1'. has no header delimiter.
E/FileObserver(13655): at io.sentry.EnvelopeReader.read(EnvelopeReader.java:80)
E/FileObserver(13655): at io.sentry.OutboxSender.processFile(OutboxSender.java:60)
E/FileObserver(13655): at io.sentry.OutboxSender.processEnvelopeFile(OutboxSender.java:100)
E/FileObserver(13655): at io.sentry.android.core.EnvelopeFileObserver.onEvent(EnvelopeFileObserver.java:58)
E/FileObserver(13655): at android.os.FileObserver$ObserverThread.onEvent(FileObserver.java:163)
E/FileObserver(13655): at android.os.FileObserver$ObserverThread.observe(Native Method)
E/FileObserver(13655): at android.os.FileObserver$ObserverThread.run(FileObserver.java:113)
To reproduce the issue checkout this branch and press the Open Scaffold with UI error
button.
It only happens on Android, iOS works just fine.
flutter doctor
below:Doctor summary (to see all details, run flutter doctor -v):
[✓] Flutter (Channel stable, 1.22.5, on macOS 11.0.1 20B29 darwin-x64, locale de-DE)
[✓] Android toolchain - develop for Android devices (Android SDK version 30.0.2)
[✓] Xcode - develop for iOS and macOS (Xcode 12.2)
[!] Android Studio (version 4.1)
✗ Flutter plugin not installed; this adds Flutter specific functionality.
✗ Dart plugin not installed; this adds Dart specific functionality.
[✓] VS Code (version 1.51.1)
[✓] Connected device (1 available)
! Doctor found issues in 1 category.
This change in the linked branch improve the error message from
FlutterError
A RenderFlex overflowed by 1175 pixels on the right.
to
════════ Exception caught by rendering library ═════════════════════════════════
The following assertion was thrown during layout:
A RenderFlex overflowed by 1175 pixels on the right.
The relevant error-causing widget was
Row
lib/scaffold_with_ui_error.dart:33
The overflowing RenderFlex has an orientation of Axis.horizontal.
The edge of the RenderFlex that is overflowing has been marked in the rendering with a yellow and black striped pattern. This is usually caused by the contents being too big for the RenderFlex.
Consider applying a flex factor (e.g. using an Expanded widget) to force the children of the RenderFlex to fit within the available space instead of being sized to their natural size.
This is considered an error condition because it indicates that there is content that cannot be seen. If the content is legitimately bigger than the available space, consider clipping it with a ClipRect widget before putting it in the flex, or using a scrollable container rather than a Flex, like a ListView.
The specific RenderFlex in question is: RenderFlex#550f0 OVERFLOWING
════════════════════════════════════════════════════════════════════════════════
This is really helpful as it includes the class from which the error was thrown.
Please consider renaming the Logger
type to something that does not collide with all kinds of logging implementations.
Originally posted on flutter: flutter/flutter#63276
Users would like to see the source context around the stack trace. This is a feature supported in Python, JavaScript and other script languages. Native has this support with source bundles.
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.