Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

engine->flutter roller blocked on test/integration.shard/test_test.dart #105340

Closed
gaaclarke opened this issue Jun 3, 2022 · 4 comments · Fixed by #105344
Closed

engine->flutter roller blocked on test/integration.shard/test_test.dart #105340

gaaclarke opened this issue Jun 3, 2022 · 4 comments · Fixed by #105344
Labels
P0 Critical issues such as a build break or regression

Comments

@gaaclarke
Copy link
Member

example: https://ci.chromium.org/ui/p/flutter/builders/try/Linux%20tool_integration_tests_3_4/11556/overview

@gaaclarke gaaclarke added the P1 label Jun 3, 2022
@gaaclarke
Copy link
Member Author

@alexmarkov can you verify that the change in the stacktrace is acceptable so we can just update the golden for that test?

cc @jason-simmons @zanderso

@jason-simmons
Copy link
Member

Running this test with the new async implementation produces a much shorter stack trace for the "uncaught Future error" phase:

cd dev/automated_tests/flutter_test
flutter test exception_handling_test.dart

With the roll:

When the exception was thrown, this was the stack:
#2      main.<anonymous closure> (file:///usr/local/google/home/jsimmons/ssd/sky/flutter/dev/automated_tests/flutter_test/exception_handling_test.dart:16:5)
#3      testWidgets.<anonymous closure>.<anonymous closure> (package:flutter_test/src/widget_tester.dart:171:29)
#5      testWidgets.<anonymous closure>.<anonymous closure> (package:flutter_test/src/widget_tester.dart:170:25)
#7      TestWidgetsFlutterBinding._runTestBody (package:flutter_test/src/binding.dart:831:5)
#9      Declarer.test.<anonymous closure>.<anonymous closure> (package:test_api/src/backend/declarer.dart:214:9)
#11     Invoker._onRun.<anonymous closure>.<anonymous closure>.<anonymous closure> (package:test_api/src/backend/invoker.dart:389:11)
(elided 5 frames from dart:async)

Before the roll:

When the exception was thrown, this was the stack:
#2      main.<anonymous closure> (file:///usr/local/google/home/jsimmons/ssd/sky/flutter/dev/automated_tests/flutter_test/exception_handling_test.dart:16:5)
#3      main.<anonymous closure> (file:///usr/local/google/home/jsimmons/ssd/sky/flutter/dev/automated_tests/flutter_test/exception_handling_test.dart:15:77)
#4      testWidgets.<anonymous closure>.<anonymous closure> (package:flutter_test/src/widget_tester.dart:171:29)
#7      testWidgets.<anonymous closure>.<anonymous closure> (package:flutter_test/src/widget_tester.dart:0:0)
#8      TestWidgetsFlutterBinding._runTestBody (package:flutter_test/src/binding.dart:841:19)
#13     TestWidgetsFlutterBinding._runTest (package:flutter_test/src/binding.dart:820:14)
#14     AutomatedTestWidgetsFlutterBinding.runTest.<anonymous closure> (package:flutter_test/src/binding.dart:1247:24)
#15     FakeAsync.run.<anonymous closure>.<anonymous closure> (package:fake_async/fake_async.dart:182:54)
#20     withClock (package:clock/src/default.dart:48:10)
#21     FakeAsync.run.<anonymous closure> (package:fake_async/fake_async.dart:182:22)
#26     FakeAsync.run (package:fake_async/fake_async.dart:182:7)
#27     AutomatedTestWidgetsFlutterBinding.runTest (package:flutter_test/src/binding.dart:1244:15)
#28     testWidgets.<anonymous closure> (package:flutter_test/src/widget_tester.dart:164:24)
#29     Declarer.test.<anonymous closure>.<anonymous closure> (package:test_api/src/backend/declarer.dart:215:19)
#32     Declarer.test.<anonymous closure>.<anonymous closure> (package:test_api/src/backend/declarer.dart:0:0)
#37     Declarer.test.<anonymous closure> (package:test_api/src/backend/declarer.dart:213:13)
#38     Declarer.test.<anonymous closure> (package:test_api/src/backend/declarer.dart:196:45)
#39     Invoker._waitForOutstandingCallbacks.<anonymous closure> (package:test_api/src/backend/invoker.dart:257:15)
#40     Invoker._waitForOutstandingCallbacks.<anonymous closure> (package:test_api/src/backend/invoker.dart:254:14)
#45     Invoker._waitForOutstandingCallbacks (package:test_api/src/backend/invoker.dart:254:5)
#46     Invoker._onRun.<anonymous closure>.<anonymous closure>.<anonymous closure> (package:test_api/src/backend/invoker.dart:391:17)
#49     Invoker._onRun.<anonymous closure>.<anonymous closure>.<anonymous closure> (package:test_api/src/backend/invoker.dart:0:0)
#54     Invoker._onRun.<anonymous closure>.<anonymous closure> (package:test_api/src/backend/invoker.dart:380:9)
#55     Invoker._guardIfGuarded (package:test_api/src/backend/invoker.dart:423:15)
#56     Invoker._onRun.<anonymous closure> (package:test_api/src/backend/invoker.dart:379:7)
#63     Invoker._onRun (package:test_api/src/backend/invoker.dart:378:11)
#64     LiveTestController.run (package:test_api/src/backend/live_test_controller.dart:153:11)
#65     RemoteListener._runLiveTest.<anonymous closure> (package:test_api/src/backend/remote_listener.dart:273:16)
#70     RemoteListener._runLiveTest (package:test_api/src/backend/remote_listener.dart:272:5)
#71     RemoteListener._serializeTest.<anonymous closure> (package:test_api/src/backend/remote_listener.dart:220:7)
#89     _GuaranteeSink.add (package:stream_channel/src/guarantee_channel.dart:125:12)
#90     new _MultiChannel.<anonymous closure> (package:stream_channel/src/multi_channel.dart:159:31)
#92     CastStreamSubscription._onData (dart:_internal/async_cast.dart:85:11)
#118    new _WebSocketImpl._fromSocket.<anonymous closure> (dart:_http/websocket_impl.dart:1144:21)
#124    _WebSocketProtocolTransformer._messageFrameEnd (dart:_http/websocket_impl.dart:332:23)
#125    _WebSocketProtocolTransformer.add (dart:_http/websocket_impl.dart:226:46)
#133    _Socket._onData (dart:io-patch/socket_patch.dart:2320:41)
#140    new _RawSocket.<anonymous closure> (dart:io-patch/socket_patch.dart:1845:33)
#141    _NativeSocket.issueReadEvent.issue (dart:io-patch/socket_patch.dart:1322:14)
(elided 104 frames from dart:async, dart:async-patch, and package:stack_trace)

@gaaclarke

This comment was marked as outdated.

copybara-service bot pushed a commit to dart-lang/sdk that referenced this issue Jun 9, 2022
…the Zone

During 'await', when registering 'then' and 'error' callbacks in
a custom Zone, the stack trace should be collected synchronously
as there are no awaiters yet, but the suspended function and its
callers are still on the stack.

This change corrects the new implementation of async to collect
these stack traces synchronously.

Class StackZoneSpecification from package:stack_trace relies on the
stack traces during callback registration in order to provide more
detailed chain of async stack traces via Chain.capture.
Without this change package:stack_trace captured truncated Chains.

Issue: #48378
Issue: flutter/flutter#105340

TEST=vm/dart/causal_stacks/zone_callback_stack_traces_test

Change-Id: Iee348aa5c9abb4126f6c5d8215a6dc2cee57e124
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/247620
Reviewed-by: Slava Egorov <vegorov@google.com>
Commit-Queue: Alexander Markov <alexmarkov@google.com>
@github-actions
Copy link

This thread has been automatically locked since there has not been any recent activity after it was closed. If you are still experiencing a similar issue, please open a new bug, including the output of flutter doctor -v and a minimal reproduction of the issue.

@github-actions github-actions bot locked as resolved and limited conversation to collaborators Jun 18, 2022
@flutter-triage-bot flutter-triage-bot bot added P0 Critical issues such as a build break or regression and removed P1 labels Jun 28, 2023
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
P0 Critical issues such as a build break or regression
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants