Skip to content

[flutter_tools] let the logger know about machine mode - #86116

Merged
fluttergithubbot merged 2 commits into
flutter:masterfrom
jonahwilliams:machine-mode-flags
Jul 12, 2021
Merged

fluttergithubbot merged 2 commits into
flutter:masterfrom
jonahwilliams:machine-mode-flags

Conversation

@jonahwilliams

@jonahwilliams jonahwilliams commented Jul 8, 2021 •

Copy link
Copy Markdown
Contributor

In order to better support machine mode, the loggers need to be aware of it - so that they can allow calling code to elide prompts or avoid displaying messages that aren't reasonable to JSON format.

Start of the work towards #80993

@flutter-dashboard flutter-dashboard Bot added the tool Affects the "flutter" command-line tool. See also t: labels. label Jul 8, 2021
@google-cla google-cla Bot added the cla: yes label Jul 8, 2021

@christopherfujino christopherfujino 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.

cooLGTM

@jonahwilliams

Copy link
Copy Markdown
Contributor Author

FYI @Hixie on linux testing failure:

+ web_socket_channel 2.1.0
+ webkit_inspection_protocol 1.0.0
+ yaml 3.1.0
Changed 54 dependencies!
Cloning into '../../bin/cache/pkg/tests'...
Downloading Dart SDK from Flutter engine 1c24b5050df26a5ba80810b41d66dbcd1506e7f7...
Building flutter tool...
error: unknown option `:--:--'
usage: git checkout [<options>] <branch>
   or: git checkout [<options>] [<branch>] -- <file>...

@christopherfujino

christopherfujino commented Jul 9, 2021 •

Copy link
Copy Markdown
Contributor

FYI @Hixie on linux testing failure:

+ web_socket_channel 2.1.0
+ webkit_inspection_protocol 1.0.0
+ yaml 3.1.0
Changed 54 dependencies!
Cloning into '../../bin/cache/pkg/tests'...
Downloading Dart SDK from Flutter engine 1c24b5050df26a5ba80810b41d66dbcd1506e7f7...
Building flutter tool...
error: unknown option `:--:--'
usage: git checkout [<options>] <branch>
   or: git checkout [<options>] [<branch>] -- <file>...

opened issue #86192, since I also saw this.

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

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.

this won't work. Consider for example "flutter create --machine --org run attach".

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.

This is true. Also, this PR doesn't change this behavior.

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.

Ah right this is what I filed in #75876

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.

4 participants