Skip to content
This repository was archived by the owner on Feb 25, 2025. It is now read-only.

Handle error more gracefully, add test for same#40361

Merged
auto-submit[bot] merged 2 commits intoflutter:mainfrom
gspencergoog:fix_exit_application
Mar 16, 2023
Merged

Handle error more gracefully, add test for same#40361
auto-submit[bot] merged 2 commits intoflutter:mainfrom
gspencergoog:fix_exit_application

Conversation

@gspencergoog
Copy link
Contributor

Description

This fixes the application exit handler so that it deals more gracefully with errors returned to it from the framework.

In this case, since the framework doesn't yet have support for requesting an application exit, it was returning an error condition, which the previous code tried to convert to an NSDictionary (and failed, causing a crash).

Now it will log the error and quit as requested if an error or unrecognized object type is returned.

Related Issues

Tests

  • Added a test for the error condition.

@gspencergoog gspencergoog force-pushed the fix_exit_application branch from d930c21 to e46f3e1 Compare March 16, 2023 20:27
@gspencergoog gspencergoog added the autosubmit Merge PR when tree becomes green via auto submit App label Mar 16, 2023
@auto-submit auto-submit bot merged commit 215a438 into flutter:main Mar 16, 2023
engine-flutter-autoroll added a commit to engine-flutter-autoroll/flutter that referenced this pull request Mar 16, 2023
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

autosubmit Merge PR when tree becomes green via auto submit App platform-macos

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants