Skip to content

Extend 'flutter symbolize' to handle deferred loading units. - #149315

Merged
auto-submit[bot] merged 8 commits into
flutter:masterfrom
sstrickl:deferred-symbolize
Sep 16, 2024
Merged

auto-submit[bot] merged 8 commits into
flutter:masterfrom
sstrickl:deferred-symbolize

Conversation

@sstrickl

@sstrickl sstrickl commented May 30, 2024 •

Copy link
Copy Markdown
Contributor

Adds -u/--unit-id-debug-info arguments to flutter symbolize to pass paths to DWARF information for deferred loading units. The argument passed via -u should be of the form N:P, where N is the loading unit ID (an integer) and P is the path to the debug information for loading unit N. The DWARF information for the root loading unit can either be passed by -d/--debug-info as before or by --unit-id-debug-info 1:<path>.

Partial fix for #137527. Additional work is needed to adjust tools built on top of flutter symbolize to store and pass along this additional information appropriately when there are deferred loading units.

Pre-launch Checklist

  • I read the [Contributor Guide] and followed the process outlined there for submitting PRs.
  • I read the [Tree Hygiene] wiki page, which explains my responsibilities.
  • I read and followed the [Flutter Style Guide], including [Features we expect every widget to implement].
  • I signed the [CLA].
  • I listed at least one issue that this PR fixes in the description above.
  • I updated/added relevant documentation (doc comments with ///).
  • I added new tests to check the change I am making, or this PR is [test-exempt].
  • I followed the [breaking change policy] and added [Data Driven Fixes] where supported.
  • All existing and new tests are passing.

@github-actions github-actions Bot added the tool Affects the "flutter" command-line tool. See also t: labels. label May 30, 2024
@sstrickl
sstrickl force-pushed the deferred-symbolize branch from 7379fdb to 90bf11f Compare May 30, 2024 13:59
@sstrickl
sstrickl marked this pull request as ready for review May 30, 2024 14:07
Comment thread packages/flutter_tools/lib/src/commands/symbolize.dart Outdated
Comment thread packages/flutter_tools/lib/src/commands/symbolize.dart Outdated
Comment thread packages/flutter_tools/lib/src/commands/symbolize.dart Outdated
Comment thread packages/flutter_tools/lib/src/commands/symbolize.dart Outdated
@andrewkolos

ghost commented Aug 8, 2024

Copy link
Copy Markdown
Contributor

@sstrickl Friendly ping.

@sstrickl

ghost commented Aug 9, 2024 •

Copy link
Copy Markdown
Contributor Author

Thanks for the ping! Sorry, was on leave for a month and then forgot to re-check this once I returned. Looking at Christopher's responses now and will address them either code-wise or with words :)

@sstrickl
sstrickl force-pushed the deferred-symbolize branch from 90bf11f to c511dcd Compare August 21, 2024 10:51
@sstrickl

ghost commented Aug 21, 2024

Copy link
Copy Markdown
Contributor Author

Okay, Christopher, I've taken a shot at addressing all your comments. PTAL and let me know if there's anything remaining, or if the changes don't address them adequately!

ghost left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@andrewkolos
andrewkolos self-requested a review August 22, 2024 20:36
@christopherfujino

ghost commented Aug 27, 2024

Copy link
Copy Markdown
Contributor

@andrewkolos friendly ping

ghost left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

RSLGTM

@andrewkolos andrewkolos added the autosubmit Merge PR when tree becomes green via auto submit App label Aug 29, 2024
@auto-submit

ghost commented Aug 29, 2024

Copy link
Copy Markdown
Contributor

auto label is removed for flutter/flutter/149315, Failed to merge flutter/flutter/149315 with Pull request flutter/flutter/149315 could not be merged: You're not authorized to push to this branch. Visit https://docs.github.com/repositories/configuring-branches-and-merges-in-your-repository/managing-protected-branches/about-protected-branches for more information..

@auto-submit auto-submit Bot removed the autosubmit Merge PR when tree becomes green via auto submit App label Aug 29, 2024
@andrewkolos
andrewkolos changed the base branch from main to master August 29, 2024 20:31
@andrewkolos andrewkolos added the autosubmit Merge PR when tree becomes green via auto submit App label Aug 29, 2024
@auto-submit

ghost commented Aug 29, 2024

Copy link
Copy Markdown
Contributor

auto label is removed for flutter/flutter/149315, due to - The status or check suite Mac_arm64 tool_tests_commands has failed. Please fix the issues identified (or deflake) before re-applying this label.

@auto-submit auto-submit Bot removed the autosubmit Merge PR when tree becomes green via auto submit App label Aug 29, 2024
@sstrickl

ghost commented Sep 2, 2024

Copy link
Copy Markdown
Contributor Author

So looking at the failures, they all are the .dSYM tests, which are just checking that if the .dSYM package directory exists, are failing. However, I'm not sure why, as we never createSync the directory it's looking for in the fresh MemoryFileSystem created using MemoryFileSystem.test(), but _fileSystem.directory(fileName).exists[Sync] and _fileSystem.isDirectory[Sync] both return true for it despite it not being there, and so validation succeeds and its not until the run actually tries to read the bytes out of the non-existent file deep within the non-existent .dSYM directory that fails. Hmm.

@sstrickl

ghost commented Sep 16, 2024

Copy link
Copy Markdown
Contributor Author

Coming back to this after a couple weeks OOO and just realized that I never called _handleDSYM on the path passed as --debug-info, if any. That's why those tests were failing. 🤦‍♀️

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

autosubmit Merge PR when tree becomes green via auto submit App tool Affects the "flutter" command-line tool. See also t: labels.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants