Repository: flutter
Issue: [tool_crash] _TypeError: (#0      Plugin._getDefaultPackageForPlatform (package:flutter_tools/src/plugins.dart:351:71))
Labels: c: crash,tool,P2,team-tool,triaged-tool

## Command
```sh
flutter --no-color run --machine --track-widget-creation --device-id=chrome --start-paused --dart-define=flutter.inspector.structuredErrors=true lib/main.dart
```

## Steps to Reproduce
1. ...
2. ...
3. ...

## Logs
_TypeError: (#0      Plugin._getDefaultPackageForPlatform (package:flutter_tools/src/plugins.dart:351:71))
```console
#0      Plugin._getDefaultPackageForPlatform (package:flutter_tools/src/plugins.dart:351:71)
#1      new Plugin._fromMultiPlatformYaml (package:flutter_tools/src/plugins.dart:163:40)
#2      new Plugin.fromYaml (package:flutter_tools/src/plugins.dart:78:21)
#3      _pluginFromPackage (package:flutter_tools/src/flutter_plugins.dart:71:17)
<asynchronous suspension>
#4      findPlugins (package:flutter_tools/src/flutter_plugins.dart:93:28)
<asynchronous suspension>
#5      injectBuildTimePluginFiles (package:flutter_tools/src/flutter_plugins.dart:1058:32)
<asynchronous suspension>
#6      ResidentWebRunner._generateEntrypoint (package:flutter_tools/src/isolated/resident_web_runner.dart:524:7)
<asynchronous suspension>
#7      ResidentWebRunner._updateDevFS (package:flutter_tools/src/isolated/resident_web_runner.dart:581:16)
<asynchronous suspension>
#8      ResidentWebRunner.run.<anonymous closure> (package:flutter_tools/src/isolated/resident_web_runner.dart:331:41)
<asynchronous suspension>
#9      asyncGuard.<anonymous closure> (package:flutter_tools/src/base/async_guard.dart:111:24)
<asynchronous suspension>
```
```console
[✓] Flutter (Channel stable, 3.27.3, on macOS 15.1.1 24B91 darwin-arm64, locale en-IN)
    • Flutter version 3.27.3 on channel stable at /Users/deendayal/flutter_sdk
    • Upstream repository https://github.com/flutter/flutter.git
    • Framework revision c519ee916e (3 days ago), 2025-01-21 10:32:23 -0800
    • Engine revision e672b006cb
    • Dart version 3.6.1
    • DevTools version 2.40.2

[!] Android toolchain - develop for Android devices (Android SDK version 34.0.0)
    • Android SDK at /Users/deendayal/Library/Android/sdk
    ✗ cmdline-tools component is missing
      Run `path/to/sdkmanager --install "cmdline-tools;latest"`
      See https://developer.android.com/studio/command-line for more details.
    ✗ Android license status unknown.
      Run `flutter doctor --android-licenses` to accept the SDK licenses.
      See https://flutter.dev/to/macos-android-setup for more details.

[✓] Xcode - develop for iOS and macOS (Xcode 16.0)
    • Xcode at /Applications/Xcode.app/Contents/Developer
    • Build 16A242d
    • CocoaPods version 1.15.2

[✓] Chrome - develop for the web
    • Chrome at /Applications/Google Chrome.app/Contents/MacOS/Google Chrome

[✓] Android Studio (version 2024.2)
    • Android Studio at /Applications/Android Studio.app/Contents
    • Flutter plugin can be installed from:
      🔨 https://plugins.jetbrains.com/plugin/9212-flutter
    • Dart plugin can be installed from:
      🔨 https://plugins.jetbrains.com/plugin/6351-dart
    • Java version OpenJDK Runtime Environment (build 21.0.3+-79915917-b509.11)

[✓] VS Code (version 1.67.2)
    • VS Code at /Users/deendayal/Downloads/Visual Studio Code.app/Contents
    • Flutter extension version 3.60.0

[✓] Connected device (4 available)
    • M2006C3MI (mobile)              • TWHUROIV6HPNAUZL      • android-arm    • Android 10 (API 29)
    • macOS (desktop)                 • macos                 • darwin-arm64   • macOS 15.1.1 24B91 darwin-arm64
    • Mac Designed for iPad (desktop) • mac-designed-for-ipad • darwin         • macOS 15.1.1 24B91 darwin-arm64
    • Chrome (web)                    • chrome                • web-javascript • Google Chrome 131.0.6778.265
    ! Error: Browsing on the local area network for Deendayal’s iPhone. Ensure the device is unlocked and attached with a cable or associated with the same local area network as this Mac.
      The device must be opted into Developer Mode to connect wirelessly. (code -27)

[✓] Network resources
    • All expected network resources are available.

! Doctor found issues in 1 category.

```

## Flutter Application Metadata
**Type**: app
**Version**: 1.0.0+1
**Material**: true
**Android X**: false
**Module**: false
**Plugin**: true
**Android package**: null
**iOS bundle identifier**: null
**Creation channel**: stable
**Creation framework version**: 17025dd88227cd9532c33fa78f5250d548d87e9a