Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Sign in
Toggle navigation
F
Front-End
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
abdullh.alsoleman
Front-End
Commits
e3106497
Unverified
Commit
e3106497
authored
Mar 25, 2021
by
Konstantin Scheglov
Committed by
GitHub
Mar 25, 2021
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Add '--protocol-traffic-log' option to 'analyze' command. (#78674)
parent
fd1ccd53
Changes
5
Hide whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
14 additions
and
1 deletion
+14
-1
analyze.dart
packages/flutter_tools/lib/src/commands/analyze.dart
+5
-0
analyze_base.dart
packages/flutter_tools/lib/src/commands/analyze_base.dart
+1
-0
analyze_continuously.dart
.../flutter_tools/lib/src/commands/analyze_continuously.dart
+1
-0
analyze_once.dart
packages/flutter_tools/lib/src/commands/analyze_once.dart
+1
-0
analysis.dart
packages/flutter_tools/lib/src/dart/analysis.dart
+6
-1
No files found.
packages/flutter_tools/lib/src/commands/analyze.dart
View file @
e3106497
...
...
@@ -55,6 +55,11 @@ class AnalyzeCommand extends FlutterCommand {
valueHelp:
'path-to-sdk'
,
help:
'The path to the Dart SDK.'
,
hide:
!
verboseHelp
);
argParser
.
addOption
(
'protocol-traffic-log'
,
valueHelp:
'path-to-protocol-traffic-log'
,
help:
'The path to write the request and response protocol. This is '
'only intended to be used for debugging the tooling.'
,
hide:
!
verboseHelp
);
// Hidden option to enable a benchmarking mode.
argParser
.
addFlag
(
'benchmark'
,
...
...
packages/flutter_tools/lib/src/commands/analyze_base.dart
View file @
e3106497
...
...
@@ -86,6 +86,7 @@ abstract class AnalyzeBase {
String
get
sdkPath
=>
argResults
[
'dart-sdk'
]
as
String
??
artifacts
.
getArtifactPath
(
Artifact
.
engineDartSdkPath
);
bool
get
isBenchmarking
=>
argResults
[
'benchmark'
]
as
bool
;
bool
get
isDartDocs
=>
argResults
[
'dartdocs'
]
as
bool
;
String
get
protocolTrafficLog
=>
argResults
[
'protocol-traffic-log'
]
as
String
;
static
int
countMissingDartDocs
(
List
<
AnalysisError
>
errors
)
{
return
errors
.
where
((
AnalysisError
error
)
{
...
...
packages/flutter_tools/lib/src/commands/analyze_continuously.dart
View file @
e3106497
...
...
@@ -77,6 +77,7 @@ class AnalyzeContinuously extends AnalyzeBase {
platform:
platform
,
processManager:
processManager
,
terminal:
terminal
,
protocolTrafficLog:
protocolTrafficLog
,
);
server
.
onAnalyzing
.
listen
((
bool
isAnalyzing
)
=>
_handleAnalysisStatus
(
server
,
isAnalyzing
));
server
.
onErrors
.
listen
(
_handleAnalysisErrors
);
...
...
packages/flutter_tools/lib/src/commands/analyze_once.dart
View file @
e3106497
...
...
@@ -95,6 +95,7 @@ class AnalyzeOnce extends AnalyzeBase {
logger:
logger
,
processManager:
processManager
,
terminal:
terminal
,
protocolTrafficLog:
protocolTrafficLog
,
);
Stopwatch
timer
;
...
...
packages/flutter_tools/lib/src/dart/analysis.dart
View file @
e3106497
...
...
@@ -29,11 +29,13 @@ class AnalysisServer {
@required
Logger
logger
,
@required
Platform
platform
,
@required
Terminal
terminal
,
String
protocolTrafficLog
,
})
:
_fileSystem
=
fileSystem
,
_processManager
=
processManager
,
_logger
=
logger
,
_platform
=
platform
,
_terminal
=
terminal
;
_terminal
=
terminal
,
_protocolTrafficLog
=
protocolTrafficLog
;
final
String
sdkPath
;
final
List
<
String
>
directories
;
...
...
@@ -42,6 +44,7 @@ class AnalysisServer {
final
Logger
_logger
;
final
Platform
_platform
;
final
Terminal
_terminal
;
final
String
_protocolTrafficLog
;
Process
_process
;
final
StreamController
<
bool
>
_analyzingController
=
...
...
@@ -67,6 +70,8 @@ class AnalysisServer {
'--disable-server-feature-search'
,
'--sdk'
,
sdkPath
,
if
(
_protocolTrafficLog
!=
null
)
'--protocol-traffic-log=
$_protocolTrafficLog
'
,
];
_logger
.
printTrace
(
'dart
${command.skip(1).join(' ')}
'
);
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment