Skip to content

Commit

Permalink
Add logs to debug VM Service Publication (#43616)
Browse files Browse the repository at this point in the history
Adding logs to help debug why VM Service is being published when it shouldn't (flutter/flutter#129987 and flutter/flutter#129836).

[C++, Objective-C, Java style guides]: https://github.com/flutter/engine/blob/main/CONTRIBUTING.md#style
  • Loading branch information
vashworth authored and harryterkelsen committed Jul 20, 2023
1 parent 15e2f02 commit 740e09f
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -80,6 +80,8 @@ - (void)stopService {
}

- (void)publishServiceProtocolPort:(NSURL*)url {
// TODO(vashworth): Remove once done debugging https://github.com/flutter/flutter/issues/129836
FML_LOG(INFO) << "Publish Service Protocol Port";
DNSServiceFlags flags = kDNSServiceFlagsDefault;
#if TARGET_IPHONE_SIMULATOR
// Simulator needs to use local loopback explicitly to work.
Expand Down
2 changes: 2 additions & 0 deletions shell/platform/darwin/ios/framework/Source/FlutterEngine.mm
Original file line number Diff line number Diff line change
Expand Up @@ -871,6 +871,8 @@ - (BOOL)createShell:(NSString*)entrypoint
FML_LOG(ERROR) << "Could not start a shell FlutterEngine with entrypoint: "
<< entrypoint.UTF8String;
} else {
// TODO(vashworth): Remove once done debugging https://github.com/flutter/flutter/issues/129836
FML_LOG(INFO) << "Enabled VM Service Publication: " << settings.enable_vm_service_publication;
[self setupShell:std::move(shell)
withVMServicePublication:settings.enable_vm_service_publication];
if ([FlutterEngine isProfilerEnabled]) {
Expand Down

0 comments on commit 740e09f

Please sign in to comment.