Skip to content

[ Tool ] Don't emit artifact downloading messages when --machine is provided #174301

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

Merged
merged 2 commits into from
Aug 22, 2025

Conversation

bkonyi
Copy link
Contributor

@bkonyi bkonyi commented Aug 22, 2025

Fixes #154119

@bkonyi bkonyi requested a review from matanlurey August 22, 2025 19:05
@github-actions github-actions bot added the tool Affects the "flutter" command-line tool. See also t: labels. label Aug 22, 2025
Copy link
Contributor

@gemini-code-assist gemini-code-assist bot left a comment

Choose a reason for hiding this comment

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

Code Review

This pull request correctly fixes an issue where artifact download messages were being emitted when the --machine flag was provided, which is intended for machine-readable output. The change broadens the detection of the --machine flag to apply to any command, not just run and attach. A comprehensive regression test has been added to ensure that these human-readable download messages are suppressed in machine mode, preventing future regressions. The changes are well-implemented and the test is robust.

final bool runMachine =
(args.contains('--machine') && args.contains('run')) ||
(args.contains('--machine') && args.contains('attach'));
final bool runMachine = args.contains('--machine');
Copy link
Contributor

Choose a reason for hiding this comment

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

lol. much nicer, wtf

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Right? I don't even know why we'd want to limit this if we have multiple commands that support --machine and we create the logger factory here...

@bkonyi bkonyi added the autosubmit Merge PR when tree becomes green via auto submit App label Aug 22, 2025
@auto-submit auto-submit bot added this pull request to the merge queue Aug 22, 2025
Merged via the queue into master with commit 699f21a Aug 22, 2025
151 checks passed
@auto-submit auto-submit bot deleted the fix_issue_154119 branch August 22, 2025 21:30
@flutter-dashboard flutter-dashboard bot removed the autosubmit Merge PR when tree becomes green via auto submit App label Aug 22, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
tool Affects the "flutter" command-line tool. See also t: labels.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Tool with --machine emits Downloading ... before emitting JSON
2 participants