Repository navigation
chore: bump @metamask/device-mcp to ^0.7.0 - #72
Merged
Merged
Conversation
|
Review the following changes in direct dependencies. Learn more about Socket for GitHub.
|
matallui
approved these changes
Oct 29, 2026
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.
Problem
Core pins
@metamask/device-mcp^0.6.0. On 0.x a caret range does not pick up 0.7.0.DeviceBackendtype in 0.6.0 has nodispose(). feat: dispose session-owned platform drivers on teardown #70 therefore calls the hook through a structural cast inMobilePlatformDriver.dispose().Solution
Adopt the device-mcp 0.7.0 release. Remove the cast and the temporary README text.
0.7.0 contains:
DeviceBackend.dispose()andreconnect(), one private IDB companion per iOS backend, and recovery when the companion or the simulator HID connection is lost.flowchart TD A[mm cleanup / launch --force / stop] --> B[DriverLifecycle] B --> C[MobilePlatformDriver.dispose] C --> D{backend.dispose?} D -->|IdbBackend 0.7.0| E[Stop the private companion and recording] D -->|AdbBackend: no hook| F[Nothing to release] classDef new fill:#fff3cd,stroke:#d39e00 class C,E newYellow boxes change: the driver calls the typed hook, and the 0.7.0 iOS backend releases its companion.
What changes
package.jsondependency range@metamask/device-mcp ^0.6.0^0.7.0yarn.lockresolutionMobilePlatformDriver.dispose()DeviceBackend & { dispose?() }this.#backend.dispose?.()on the typedDeviceBackendREADME.mdteardown paragraphDecisions for reviewers
dispose?.()dispose()is still optional in the 0.7.0DeviceBackendtype.IdbBackendimplements it;AdbBackendandAppiumBackenddo not.Promise.resolve().then(...)chore:, not breakingselectDevice()break in 0.7.0 is onLazyDeviceBackend, which core does not use.Review guide
package.json,yarn.lock^0.7.0. Only the device-mcp entry and the workspace range change.src/platform/mobile-platform-driver.tsREADME.mdsrc/platform/mobile-platform-driver.dispose.test.tsTesting
Device-mcp 0.7.0 is installed from npm, without yalc.
yarn buildpasses.yarn lintpasses, including ESLint, formatting, constraints, dependency and dedupe checks, and changelog validation.yarn testpasses: 53 files and 1,835 tests. Typechecking and coverage thresholds pass. Thresholds are unchanged.tsc --noEmit -p tsconfig.test.jsonreports 8 errors onmainand 8 on this branch. All 8 already exist onmain.dist/backends/types.d.mtsdeclaresdispose?(): Promise<void>andreconnect?(): Promise<void>onDeviceBackend.IdbBackenddeclaresdispose();AdbBackendandAppiumBackenddo not.No device run for this PR. The live teardown and recovery checks are in device-mcp#43 and #70, and they used the same code.