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
[flutter_tools] Run ShutdownHooks when handling signals #134590
Merged
christopherfujino
merged 3 commits into
flutter:master
from
christopherfujino:run-hooks-when-handling-signals
Sep 13, 2023
Merged
[flutter_tools] Run ShutdownHooks when handling signals #134590
christopherfujino
merged 3 commits into
flutter:master
from
christopherfujino:run-hooks-when-handling-signals
Sep 13, 2023
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
github-actions
bot
added
the
tool
Affects the "flutter" command-line tool. See also t: labels.
label
Sep 12, 2023
christopherfujino
force-pushed
the
run-hooks-when-handling-signals
branch
from
September 12, 2023 23:49
e044271
to
7ac949b
Compare
vashworth
approved these changes
Sep 13, 2023
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM
Manually merging on red google testing because of: b/300299508#comment2 |
engine-flutter-autoroll
added a commit
to engine-flutter-autoroll/packages
that referenced
this pull request
Sep 14, 2023
auto-submit bot
pushed a commit
to flutter/packages
that referenced
this pull request
Sep 14, 2023
flutter/flutter@61b890b...58ba6c2 2023-09-14 engine-flutter-autoroll@skia.org Roll Packages from 06cd9e9 to 275b76c (1 revision) (flutter/flutter#134734) 2023-09-14 dacoharkes@google.com Update plugin_ffi generated file to match FFIgen 9.0.0 (flutter/flutter#134614) 2023-09-14 jmccandless@google.com LinkedText (Linkify) (flutter/flutter#125927) 2023-09-14 polinach@google.com _DayPicker should build days using separate stetefull widget _Day. (flutter/flutter#134607) 2023-09-13 31859944+LongCatIsLooong@users.noreply.github.com Remove `Path.combine` call from `CupertionoTextSelectionToolbar` (flutter/flutter#134369) 2023-09-13 katelovett@google.com Update KeepAlive.debugTypicalAncestorWidgetClass (flutter/flutter#133498) 2023-09-13 84124091+opxdelwin@users.noreply.github.com Fix null check crash by ReorderableList (flutter/flutter#132153) 2023-09-13 engine-flutter-autoroll@skia.org Roll Flutter Engine from 154d6fd601a3 to cd90cc8469fb (3 revisions) (flutter/flutter#134691) 2023-09-13 49699333+dependabot[bot]@users.noreply.github.com Bump github/codeql-action from 2.21.5 to 2.21.6 (flutter/flutter#134692) 2023-09-13 engine-flutter-autoroll@skia.org Roll Flutter Engine from b71b366e3de3 to 154d6fd601a3 (6 revisions) (flutter/flutter#134683) 2023-09-13 christopherfujino@gmail.com [flutter_tools] Run ShutdownHooks when handling signals (flutter/flutter#134590) 2023-09-13 jhy03261997@gmail.com Dispose routes in navigator when throwing exception (flutter/flutter#134596) 2023-09-13 jonahwilliams@google.com [framework] reduce ink sparkle uniform count. (flutter/flutter#133897) 2023-09-13 engine-flutter-autoroll@skia.org Roll Flutter Engine from 5e671d5c90f9 to b71b366e3de3 (4 revisions) (flutter/flutter#134676) 2023-09-13 15619084+vashworth@users.noreply.github.com Set the CONFIGURATION_BUILD_DIR in generated xcconfig when debugging core device (flutter/flutter#134493) 2023-09-13 zanderso@users.noreply.github.com Bump gradle heap size limit in *everywhere* (flutter/flutter#134665) If this roll has caused a breakage, revert this CL and stop the roller using the controls here: https://autoroll.skia.org/r/flutter-packages Please CC camillesimon@google.com,rmistry@google.com,stuartmorgan@google.com on the revert to ensure that a human is aware of the problem. To file a bug in Packages: https://github.com/flutter/flutter/issues/new/choose To report a problem with the AutoRoller itself, please file a bug: https://bugs.chromium.org/p/skia/issues/entry?template=Autoroller+Bug Documentation for the AutoRoller is here: https://skia.googlesource.com/buildbot/+doc/main/autoroll/README.md
Mairramer
pushed a commit
to Mairramer/flutter
that referenced
this pull request
Oct 10, 2023
Fixes flutter#134566. Prior to this fix, `ShutdownHooks` were run in the private helper function `_exit()` defined in the `package:flutter_tools/runner.dart` library. Independent of this, the tool had signal handling logic that traps SIGINT and SIGTERM. However, these handlers called `exit()` from `dart:io`, and didn't run these hooks. This PR moves the `_exit()` private helper to `package:flutter_tools/src/base/process.dart` and renames it to `exitWithHooks()`, so that it can be called by the signal handlers in `package:flutter_tools/src/base/signals.dart`.
engine-flutter-autoroll
added a commit
to engine-flutter-autoroll/packages
that referenced
this pull request
Nov 15, 2023
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Fixes #134566.
Prior to this fix,
ShutdownHooks
were run in the private helper function_exit()
defined in thepackage:flutter_tools/runner.dart
library. Independent of this, the tool had signal handling logic that traps SIGINT and SIGTERM. However, these handlers calledexit()
fromdart:io
, and didn't run these hooks.This PR moves the
_exit()
private helper topackage:flutter_tools/src/base/process.dart
and renames it toexitWithHooks()
, so that it can be called by the signal handlers inpackage:flutter_tools/src/base/signals.dart
.