Repository navigation
fix(driver): select isolate exposing ext.flutter.driver - #946
Open
dajiaohuang wants to merge 1 commit into
Open
dajiaohuang wants to merge 1 commit into
dajiaohuang wants to merge 1 commit into
Conversation
|
|
Member
|
Please sign the CLA |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Fixes #912.
Automatic discovery currently chooses the first isolate whose name contains
mainfrom onegetVMresult, then polls only that isolate. If a background Flutter engine is listed first and does not exposeext.flutter.driver, the UI isolate is never considered.This change refreshes the VM isolate list on each automatic-discovery retry and selects the first isolate that advertises
ext.flutter.driver. An explicitly configuredappium:isolateIdremains pinned to that isolate. The synthetic regression tests cover duplicatemainisolates, a UI isolate appearing after the first VM snapshot, and the explicit-ID path.Validation:
npm test: build and all 11 tests passed (the new tests use a local synthetic WebSocket server; no device or user app).npm run lint: passed.git diff --checkfor both changed files: passed.npm run format:checkstill reports 30 unchanged files; the changed source and test pass the targeted format check.Related context: #911 was closed without merge while feedback on #912 was sought. Open #937 also touches
observatory.ts, but addresses pending commands when the Dart VM socket closes; this change addresses isolate discovery. The shared-file relationship is called out for merge coordination.