[pigeon] ClassCastException with Kotlin generated code

This issue has been created since 2022-11-23.
E/BasicMessageChannel#dev.flutter.pigeon.AndroidVideoPlayerApi.pause(12252): Failed to handle message
E/BasicMessageChannel#dev.flutter.pigeon.AndroidVideoPlayerApi.pause(12252): java.lang.ClassCastException: java.lang.Integer cannot be cast to java.lang.Long

Dart side
Schermata 2022-11-23 alle 12 03 53

Kotlin side
Schermata 2022-11-23 alle 12 04 31

The same code works in Java because the cast checks the instance of the value
Schermata 2022-11-23 alle 12 10 51

danagbemava-nc wrote this answer on 2022-11-23

Hi @giovannilattanziocrispy, please provide the version of pigeon you're using along with the output of flutter doctor -v.

Please also provide a complete minimal reproducible code sample as well along with steps to reproduce.

Thank you.

As a side note, in the future, do not provide screenshots of code snippets. It is better for you to paste the actual code sample in properly formatted text in the issue directly.

giovannilattanziocrispy wrote this answer on 2022-11-23

Pigeon version: pigeon: ^4.2.6
Flutter doctor:

[✓] Flutter (Channel stable, 3.3.7, on macOS 12.4 21F79 darwin-x64, locale it-IT)
    • Flutter version 3.3.7 on channel stable at /Users/crispybacon039/development/flutter
    • Upstream repository https://github.com/flutter/flutter.git
    • Framework revision e99c9c7cd9 (3 weeks ago), 2022-11-01 16:59:00 -0700
    • Engine revision 857bd6b74c
    • Dart version 2.18.4
    • DevTools version 2.15.0

[✓] Android toolchain - develop for Android devices (Android SDK version 33.0.0-rc4)
    • Android SDK at /Users/crispybacon039/Library/Android/sdk
    • Platform android-33, build-tools 33.0.0-rc4
    • ANDROID_HOME = /Users/crispybacon039/Library/Android/sdk
    • Java binary at: /Applications/Android Studio.app/Contents/jre/Contents/Home/bin/java
    • Java version OpenJDK Runtime Environment (build 11.0.13+0-b1751.21-8125866)
    • All Android licenses accepted.

[✓] Xcode - develop for iOS and macOS (Xcode 13.4.1)
    • Xcode at /Applications/Xcode.app/Contents/Developer
    • Build 13F100
    • CocoaPods version 1.11.3

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

[✓] Android Studio (version 2021.3)
    • 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 11.0.13+0-b1751.21-8125866)

[✓] Connected device (3 available)
    • Mi 9T (mobile)  • d1e9d55b • android-arm64  • Android 11 (API 30)
    • macOS (desktop) • macos    • darwin-x64     • macOS 12.4 21F79 darwin-x64
    • Chrome (web)    • chrome   • web-javascript • Google Chrome 107.0.5304.110

[✓] HTTP Host Availability
    • All required HTTP hosts are available

If you run this file

import 'package:pigeon/pigeon.dart';

@ConfigurePigeon(
  PigeonOptions(
    dartOut: 'lib/src/messages.g.dart',
    kotlinOut:
        'android/src/main/kotlin/it/test/video/Messages.kt',
    kotlinOptions: KotlinOptions(
      package: 'it.test.video',
    ),
  ),
)

class IdentifyMessage {
  IdentifyMessage(this.viewId);
  int viewId;
}

@HostApi(dartHostTestHandler: 'TestHostVideoPlayerApi')
abstract class AndroidVideoPlayerApi {
  void play(IdentifyMessage msg);
}

with

flutter pub run pigeon \
  --input pigeons/video.dart

you'll have the error implementing the play method.
If you run the same, but with the Java configuration

import 'package:pigeon/pigeon.dart';

@ConfigurePigeon(
  PigeonOptions(
    dartOut: 'lib/src/messages.g.dart',
    javaOut:
        'android/src/main/java/it/test/video/Messages.java',
    javaOptions: JavaOptions(
      package: 'it.test.video',
    ),
  ),
)

class IdentifyMessage {
  IdentifyMessage(this.viewId);
  int viewId;
}

@HostApi(dartHostTestHandler: 'TestHostVideoPlayerApi')
abstract class AndroidVideoPlayerApi {
  void play(IdentifyMessage msg);
}

the generated code goes well

danagbemava-nc wrote this answer on 2022-11-24

I can reproduce the issue using the info provided in #115914 (comment)

When I use the generated Java code, it works as expected but throws an exception when I use the generated Kotlin code.

Generated code

JavaMessages.java

// Autogenerated from Pigeon (v4.2.6), do not edit directly.
// See also: https://pub.dev/packages/pigeon

package com.example.pt;

import android.util.Log;
import androidx.annotation.NonNull;
import androidx.annotation.Nullable;
import io.flutter.plugin.common.BasicMessageChannel;
import io.flutter.plugin.common.BinaryMessenger;
import io.flutter.plugin.common.MessageCodec;
import io.flutter.plugin.common.StandardMessageCodec;
import java.io.ByteArrayOutputStream;
import java.nio.ByteBuffer;
import java.util.Arrays;
import java.util.ArrayList;
import java.util.Collections;
import java.util.List;
import java.util.Map;
import java.util.HashMap;

/**Generated class from Pigeon. */
@SuppressWarnings({"unused", "unchecked", "CodeBlock2Expr", "RedundantSuppression"})
public class JavaMessages {

  /** Generated class from Pigeon that represents data sent in messages. */
  public static class IdentifyMessage {
    private @NonNull Long viewId;
    public @NonNull Long getViewId() { return viewId; }
    public void setViewId(@NonNull Long setterArg) {
      if (setterArg == null) {
        throw new IllegalStateException("Nonnull field \"viewId\" is null.");
      }
      this.viewId = setterArg;
    }

    /**Constructor is private to enforce null safety; use Builder. */
    private IdentifyMessage() {}
    public static final class Builder {
      private @Nullable Long viewId;
      public @NonNull Builder setViewId(@NonNull Long setterArg) {
        this.viewId = setterArg;
        return this;
      }
      public @NonNull IdentifyMessage build() {
        IdentifyMessage pigeonReturn = new IdentifyMessage();
        pigeonReturn.setViewId(viewId);
        return pigeonReturn;
      }
    }
    @NonNull Map<String, Object> toMap() {
      Map<String, Object> toMapResult = new HashMap<>();
      toMapResult.put("viewId", viewId);
      return toMapResult;
    }
    static @NonNull IdentifyMessage fromMap(@NonNull Map<String, Object> map) {
      IdentifyMessage pigeonResult = new IdentifyMessage();
      Object viewId = map.get("viewId");
      pigeonResult.setViewId((viewId == null) ? null : ((viewId instanceof Integer) ? (Integer)viewId : (Long)viewId));
      return pigeonResult;
    }
  }
  private static class AndroidVideoPlayerApiCodec extends StandardMessageCodec {
    public static final AndroidVideoPlayerApiCodec INSTANCE = new AndroidVideoPlayerApiCodec();
    private AndroidVideoPlayerApiCodec() {}
    @Override
    protected Object readValueOfType(byte type, @NonNull ByteBuffer buffer) {
      switch (type) {
        case (byte)128:         
          return IdentifyMessage.fromMap((Map<String, Object>) readValue(buffer));
        
        default:        
          return super.readValueOfType(type, buffer);
        
      }
    }
    @Override
    protected void writeValue(@NonNull ByteArrayOutputStream stream, Object value)     {
      if (value instanceof IdentifyMessage) {
        stream.write(128);
        writeValue(stream, ((IdentifyMessage) value).toMap());
      } else 
{
        super.writeValue(stream, value);
      }
    }
  }

  /** Generated interface from Pigeon that represents a handler of messages from Flutter. */
  public interface AndroidVideoPlayerApi {
    void play(@NonNull IdentifyMessage msg);

    /** The codec used by AndroidVideoPlayerApi. */
    static MessageCodec<Object> getCodec() {
      return       AndroidVideoPlayerApiCodec.INSTANCE;    }
    /**Sets up an instance of `AndroidVideoPlayerApi` to handle messages through the `binaryMessenger`. */
    static void setup(BinaryMessenger binaryMessenger, AndroidVideoPlayerApi api) {
      {
        BasicMessageChannel<Object> channel =
            new BasicMessageChannel<>(binaryMessenger, "dev.flutter.pigeon.AndroidVideoPlayerApi.play", getCodec());
        if (api != null) {
          channel.setMessageHandler((message, reply) -> {
            Map<String, Object> wrapped = new HashMap<>();
            try {
              ArrayList<Object> args = (ArrayList<Object>)message;
              assert args != null;
              IdentifyMessage msgArg = (IdentifyMessage)args.get(0);
              if (msgArg == null) {
                throw new NullPointerException("msgArg unexpectedly null.");
              }
              api.play(msgArg);
              wrapped.put("result", null);
            }
            catch (Error | RuntimeException exception) {
              wrapped.put("error", wrapError(exception));
            }
            reply.reply(wrapped);
          });
        } else {
          channel.setMessageHandler(null);
        }
      }
    }
  }
  @NonNull private static Map<String, Object> wrapError(@NonNull Throwable exception) {
    Map<String, Object> errorMap = new HashMap<>();
    errorMap.put("message", exception.toString());
    errorMap.put("code", exception.getClass().getSimpleName());
    errorMap.put("details", "Cause: " + exception.getCause() + ", Stacktrace: " + Log.getStackTraceString(exception));
    return errorMap;
  }
}

Messages.kt

// Autogenerated from Pigeon (v4.2.6), do not edit directly.
// See also: https://pub.dev/packages/pigeon

package com.example.pt

import android.util.Log
import io.flutter.plugin.common.BasicMessageChannel
import io.flutter.plugin.common.BinaryMessenger
import io.flutter.plugin.common.MessageCodec
import io.flutter.plugin.common.StandardMessageCodec
import java.io.ByteArrayOutputStream
import java.nio.ByteBuffer

/** Generated class from Pigeon. */

/** Generated class from Pigeon that represents data sent in messages. */
data class IdentifyMessage (
  val viewId: Long

) {
  companion object {
    @Suppress("UNCHECKED_CAST")
    fun fromMap(map: Map<String, Any?>): IdentifyMessage {
      val viewId = map["viewId"] as Long

      return IdentifyMessage(viewId)
    }
  }
  fun toMap(): Map<String, Any?> {
    val map = mutableMapOf<String, Any?>()
    map["viewId"] = viewId
    return map
  }
}
@Suppress("UNCHECKED_CAST")
private object AndroidVideoPlayerApiCodec : StandardMessageCodec() {
  override fun readValueOfType(type: Byte, buffer: ByteBuffer): Any? {
    return when (type) {
      128.toByte() -> {
        return (readValue(buffer) as? Map<String, Any?>)?.let {
          IdentifyMessage.fromMap(it)
        }
      }
      else -> super.readValueOfType(type, buffer)
    }
  }
  override fun writeValue(stream: ByteArrayOutputStream, value: Any?)   {
    when (value) {
      is IdentifyMessage -> {
        stream.write(128)
        writeValue(stream, value.toMap())
      }
      else -> super.writeValue(stream, value)
    }
  }
}

/** Generated interface from Pigeon that represents a handler of messages from Flutter. */
interface AndroidVideoPlayerApi {
  fun play(msg: IdentifyMessage)

  companion object {
    /** The codec used by AndroidVideoPlayerApi. */
    val codec: MessageCodec<Any?> by lazy {
      AndroidVideoPlayerApiCodec
    }
    /** Sets up an instance of `AndroidVideoPlayerApi` to handle messages through the `binaryMessenger`. */
    @Suppress("UNCHECKED_CAST")
    fun setUp(binaryMessenger: BinaryMessenger, api: AndroidVideoPlayerApi?) {
      run {
        val channel = BasicMessageChannel<Any?>(binaryMessenger, "dev.flutter.pigeon.AndroidVideoPlayerApi.play", codec)
        if (api != null) {
          channel.setMessageHandler { message, reply ->
            val wrapped = hashMapOf<String, Any?>()
            try {
              val args = message as List<Any?>
              val msgArg = args[0] as IdentifyMessage
              api.play(msgArg)
              wrapped["result"] = null
            } catch (exception: Error) {
              wrapped["error"] = wrapError(exception)
            }
            reply.reply(wrapped)
          }
        } else {
          channel.setMessageHandler(null)
        }
      }
    }
  }
}

private fun wrapResult(result: Any?): Map<String, Any?> {
  return hashMapOf("result" to result)
}

private fun wrapError(exception: Throwable): Map<String, Any> {
  return hashMapOf<String, Any>(
    "error" to hashMapOf<String, Any>(
      "code" to exception.javaClass.simpleName,
      "message" to exception.toString(),
      "details" to "Cause: " + exception.cause + ", Stacktrace: " + Log.getStackTraceString(exception)
    )
  )
}

messages.g.dart

// Autogenerated from Pigeon (v4.2.6), do not edit directly.
// See also: https://pub.dev/packages/pigeon
// ignore_for_file: public_member_api_docs, non_constant_identifier_names, avoid_as, unused_import, unnecessary_parenthesis, prefer_null_aware_operators, omit_local_variable_types, unused_shown_name, unnecessary_import
import 'dart:async';
import 'dart:typed_data' show Float64List, Int32List, Int64List, Uint8List;

import 'package:flutter/foundation.dart' show ReadBuffer, WriteBuffer;
import 'package:flutter/services.dart';

class IdentifyMessage {
  IdentifyMessage({
    required this.viewId,
  });

  int viewId;

  Object encode() {
    final Map<Object?, Object?> pigeonMap = <Object?, Object?>{};
    pigeonMap['viewId'] = viewId;
    return pigeonMap;
  }

  static IdentifyMessage decode(Object message) {
    final Map<Object?, Object?> pigeonMap = message as Map<Object?, Object?>;
    return IdentifyMessage(
      viewId: pigeonMap['viewId']! as int,
    );
  }
}

class _AndroidVideoPlayerApiCodec extends StandardMessageCodec{
  const _AndroidVideoPlayerApiCodec();
  @override
  void writeValue(WriteBuffer buffer, Object? value) {
    if (value is IdentifyMessage) {
      buffer.putUint8(128);
      writeValue(buffer, value.encode());
    } else 
{
      super.writeValue(buffer, value);
    }
  }
  @override
  Object? readValueOfType(int type, ReadBuffer buffer) {
    switch (type) {
      case 128:       
        return IdentifyMessage.decode(readValue(buffer)!);
      
      default:      
        return super.readValueOfType(type, buffer);
      
    }
  }
}

class AndroidVideoPlayerApi {
  /// Constructor for [AndroidVideoPlayerApi].  The [binaryMessenger] named argument is
  /// available for dependency injection.  If it is left null, the default
  /// BinaryMessenger will be used which routes to the host platform.
  AndroidVideoPlayerApi({BinaryMessenger? binaryMessenger}) : _binaryMessenger = binaryMessenger;
  final BinaryMessenger? _binaryMessenger;

  static const MessageCodec<Object?> codec = _AndroidVideoPlayerApiCodec();

  Future<void> play(IdentifyMessage arg_msg) async {
    final BasicMessageChannel<Object?> channel = BasicMessageChannel<Object?>(
        'dev.flutter.pigeon.AndroidVideoPlayerApi.play', codec, binaryMessenger: _binaryMessenger);
    final Map<Object?, Object?>? replyMap =
        await channel.send(<Object?>[arg_msg]) as Map<Object?, Object?>?;
    if (replyMap == null) {
      throw PlatformException(
        code: 'channel-error',
        message: 'Unable to establish connection on channel.',
      );
    } else if (replyMap['error'] != null) {
      final Map<Object?, Object?> error = (replyMap['error'] as Map<Object?, Object?>?)!;
      throw PlatformException(
        code: (error['code'] as String?)!,
        message: error['message'] as String?,
        details: error['details'],
      );
    } else {
      return;
    }
  }
}
Exception after calling play
E/BasicMessageChannel#dev.flutter.pigeon.AndroidVideoPlayerApi.play( 8234): Failed to handle message
E/BasicMessageChannel#dev.flutter.pigeon.AndroidVideoPlayerApi.play( 8234): java.lang.ClassCastException: java.lang.Integer cannot be cast to java.lang.Long
E/BasicMessageChannel#dev.flutter.pigeon.AndroidVideoPlayerApi.play( 8234): 	at com.example.pt.IdentifyMessage$Companion.fromMap(Messages.kt:24)
E/BasicMessageChannel#dev.flutter.pigeon.AndroidVideoPlayerApi.play( 8234): 	at com.example.pt.AndroidVideoPlayerApiCodec.readValueOfType(Messages.kt:41)
E/BasicMessageChannel#dev.flutter.pigeon.AndroidVideoPlayerApi.play( 8234): 	at io.flutter.plugin.common.StandardMessageCodec.readValue(StandardMessageCodec.java:340)
E/BasicMessageChannel#dev.flutter.pigeon.AndroidVideoPlayerApi.play( 8234): 	at io.flutter.plugin.common.StandardMessageCodec.readValueOfType(StandardMessageCodec.java:424)
E/BasicMessageChannel#dev.flutter.pigeon.AndroidVideoPlayerApi.play( 8234): 	at com.example.pt.AndroidVideoPlayerApiCodec.readValueOfType(Messages.kt:44)
E/BasicMessageChannel#dev.flutter.pigeon.AndroidVideoPlayerApi.play( 8234): 	at io.flutter.plugin.common.StandardMessageCodec.readValue(StandardMessageCodec.java:340)
E/BasicMessageChannel#dev.flutter.pigeon.AndroidVideoPlayerApi.play( 8234): 	at io.flutter.plugin.common.StandardMessageCodec.decodeMessage(StandardMessageCodec.java:89)
E/BasicMessageChannel#dev.flutter.pigeon.AndroidVideoPlayerApi.play( 8234): 	at io.flutter.plugin.common.BasicMessageChannel$IncomingMessageHandler.onMessage(BasicMessageChannel.java:218)
E/BasicMessageChannel#dev.flutter.pigeon.AndroidVideoPlayerApi.play( 8234): 	at io.flutter.embedding.engine.dart.DartMessenger.invokeHandler(DartMessenger.java:295)
E/BasicMessageChannel#dev.flutter.pigeon.AndroidVideoPlayerApi.play( 8234): 	at io.flutter.embedding.engine.dart.DartMessenger.lambda$dispatchMessageToQueue$0$io-flutter-embedding-engine-dart-DartMessenger(DartMessenger.java:319)
E/BasicMessageChannel#dev.flutter.pigeon.AndroidVideoPlayerApi.play( 8234): 	at io.flutter.embedding.engine.dart.DartMessenger$$ExternalSyntheticLambda0.run(Unknown Source:12)
E/BasicMessageChannel#dev.flutter.pigeon.AndroidVideoPlayerApi.play( 8234): 	at android.os.Handler.handleCallback(Handler.java:938)
E/BasicMessageChannel#dev.flutter.pigeon.AndroidVideoPlayerApi.play( 8234): 	at android.os.Handler.dispatchMessage(Handler.java:99)
E/BasicMessageChannel#dev.flutter.pigeon.AndroidVideoPlayerApi.play( 8234): 	at android.os.Looper.loopOnce(Looper.java:210)
E/BasicMessageChannel#dev.flutter.pigeon.AndroidVideoPlayerApi.play( 8234): 	at android.os.Looper.loop(Looper.java:299)
E/BasicMessageChannel#dev.flutter.pigeon.AndroidVideoPlayerApi.play( 8234): 	at android.app.ActivityThread.main(ActivityThread.java:8319)
E/BasicMessageChannel#dev.flutter.pigeon.AndroidVideoPlayerApi.play( 8234): 	at java.lang.reflect.Method.invoke(Native Method)
E/BasicMessageChannel#dev.flutter.pigeon.AndroidVideoPlayerApi.play( 8234): 	at com.android.internal.os.RuntimeInit$MethodAndArgsCaller.run(RuntimeInit.java:556)
E/BasicMessageChannel#dev.flutter.pigeon.AndroidVideoPlayerApi.play( 8234): 	at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:1038)
flutter doctor -v
[✓] Flutter (Channel stable, 3.3.8, on macOS 13.0.1 22A400 darwin-arm, locale en-GB)
    • Flutter version 3.3.8 on channel stable at /Users/nexus/dev/sdks/flutter
    • Upstream repository https://github.com/flutter/flutter.git
    • Framework revision 52b3dc25f6 (2 weeks ago), 2022-11-09 12:09:26 +0800
    • Engine revision 857bd6b74c
    • Dart version 2.18.4
    • DevTools version 2.15.0

[✓] Android toolchain - develop for Android devices (Android SDK version 33.0.0)
    • Android SDK at /Users/nexus/Library/Android/sdk
    • Platform android-33, build-tools 33.0.0
    • Java binary at: /Users/nexus/Library/Application Support/JetBrains/Toolbox/apps/AndroidStudio/ch-0/213.7172.25.2113.9123335/Android Studio.app/Contents/jre/Contents/Home/bin/java
    • Java version OpenJDK Runtime Environment (build 11.0.13+0-b1751.21-8125866)
    • All Android licenses accepted.

[✓] Xcode - develop for iOS and macOS (Xcode 14.1)
    • Xcode at /Applications/Xcode.app/Contents/Developer
    • Build 14B47b
    • CocoaPods version 1.11.3

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

[!] Android Studio
    • Android Studio at /Applications/Android Studio Preview.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
    ✗ Unable to find bundled Java version.
    • Try updating or re-installing Android Studio.

[✓] Android Studio (version 2021.3)
    • 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 11.0.13+0-b1751.21-8125866)

[!] Android Studio
    • Android Studio at /Applications/Android Studio Preview 2.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
    ✗ Unable to find bundled Java version.
    • Try updating or re-installing Android Studio.

[✓] Android Studio (version 2021.3)
    • Android Studio at /Users/nexus/Library/Application Support/JetBrains/Toolbox/apps/AndroidStudio/ch-0/213.7172.25.2113.9123335/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 11.0.13+0-b1751.21-8125866)

[✓] Android Studio (version 2021.3)
    • Android Studio at /Users/nexus/Library/Application Support/JetBrains/Toolbox/apps/AndroidStudio/ch-0/213.7172.25.2113.9014738/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 11.0.13+0-b1751.21-8125866)

[✓] VS Code (version 1.73.1)
    • VS Code at /Applications/Visual Studio Code.app/Contents
    • Flutter extension version 3.52.0

[✓] Connected device (4 available)
    • M2007J20CG (mobile)    • 5dd3be00                             • android-arm64  • Android 12 (API 31)
    • iPhone 14 Pro (mobile) • 4F72110C-F38B-4CF9-93C4-4D6042148D28 • ios            • com.apple.CoreSimulator.SimRuntime.iOS-16-1 (simulator)
    • macOS (desktop)        • macos                                • darwin-arm64   • macOS 13.0.1 22A400 darwin-arm
    • Chrome (web)           • chrome                               • web-javascript • Google Chrome 107.0.5304.110

[✓] HTTP Host Availability
    • All required HTTP hosts are available

! Doctor found issues in 2 categories.
[!] Flutter (Channel master, 3.6.0-7.0.pre.45, on macOS 13.0.1 22A400 darwin-arm64, locale en-GB)
    • Flutter version 3.6.0-7.0.pre.45 on channel master at /Users/nexus/dev/sdks/flutters
    ! Warning: `flutter` on your path resolves to /Users/nexus/dev/sdks/flutter/bin/flutter, which is not inside your current Flutter SDK checkout at /Users/nexus/dev/sdks/flutters. Consider adding /Users/nexus/dev/sdks/flutters/bin to the front of your path.
    ! Warning: `dart` on your path resolves to /Users/nexus/dev/sdks/flutter/bin/dart, which is not inside your current Flutter SDK checkout at /Users/nexus/dev/sdks/flutters. Consider adding /Users/nexus/dev/sdks/flutters/bin to the front of your path.
    • Upstream repository https://github.com/flutter/flutter.git
    • Framework revision d0352f55db (6 hours ago), 2022-11-23 20:01:26 -0500
    • Engine revision 9b2895724c
    • Dart version 2.19.0 (build 2.19.0-424.0.dev)
    • DevTools version 2.19.0
    • If those were intentional, you can disregard the above warnings; however it is recommended to use "git" directly to perform update checks and upgrades.

[✓] Android toolchain - develop for Android devices (Android SDK version 33.0.0)
    • Android SDK at /Users/nexus/Library/Android/sdk
    • Platform android-33, build-tools 33.0.0
    • Java binary at: /Users/nexus/Library/Application Support/JetBrains/Toolbox/apps/AndroidStudio/ch-0/213.7172.25.2113.9123335/Android Studio.app/Contents/jre/Contents/Home/bin/java
    • Java version OpenJDK Runtime Environment (build 11.0.13+0-b1751.21-8125866)
    • All Android licenses accepted.

[✓] Xcode - develop for iOS and macOS (Xcode 14.1)
    • Xcode at /Applications/Xcode.app/Contents/Developer
    • Build 14B47b
    • CocoaPods version 1.11.3

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

[!] Android Studio
    • Android Studio at /Applications/Android Studio Preview.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
    ✗ Unable to find bundled Java version.
    • Try updating or re-installing Android Studio.

[✓] Android Studio (version 2021.3)
    • 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 11.0.13+0-b1751.21-8125866)

[!] Android Studio
    • Android Studio at /Applications/Android Studio Preview 2.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
    ✗ Unable to find bundled Java version.
    • Try updating or re-installing Android Studio.

[✓] Android Studio (version 2021.3)
    • Android Studio at /Users/nexus/Library/Application Support/JetBrains/Toolbox/apps/AndroidStudio/ch-0/213.7172.25.2113.9123335/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 11.0.13+0-b1751.21-8125866)

[✓] Android Studio (version 2021.3)
    • Android Studio at /Users/nexus/Library/Application Support/JetBrains/Toolbox/apps/AndroidStudio/ch-0/213.7172.25.2113.9014738/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 11.0.13+0-b1751.21-8125866)

[✓] VS Code (version 1.73.1)
    • VS Code at /Applications/Visual Studio Code.app/Contents
    • Flutter extension version 3.52.0

[✓] Connected device (4 available)
    • M2007J20CG (mobile)    • 5dd3be00                             • android-arm64  • Android 12 (API 31)
    • iPhone 14 Pro (mobile) • 4F72110C-F38B-4CF9-93C4-4D6042148D28 • ios            • com.apple.CoreSimulator.SimRuntime.iOS-16-1 (simulator)
    • macOS (desktop)        • macos                                • darwin-arm64   • macOS 13.0.1 22A400 darwin-arm64
    • Chrome (web)           • chrome                               • web-javascript • Google Chrome 107.0.5304.110

[✓] HTTP Host Availability
    • All required HTTP hosts are available

! Doctor found issues in 3 categories.

More Details About Repo
Owner Name flutter
Repo Name flutter
Full Name flutter/flutter
Language Dart
Created Date 2015-03-06
Updated Date 2022-12-10
Star Count 147243
Watcher Count 3561
Fork Count 23950
Issue Count 11325

YOU MAY BE INTERESTED

Issue Title Created Date Comment Count Updated Date
A certain set of Pokemon are not colored properly in battle 1 2020-10-13 2022-11-25
[Bug][Manager] Fix the deserialization error below jackson version 2.13 0 2022-11-01 2022-10-30
File won't open in Global Mapper 2 2022-05-26 2022-11-29
[BUG] 源码安装后启动失败。Debian testing 4 2022-10-09 2022-12-01
Just to have a confirmation that is it mandatory to have admin credentials? 2 2021-01-15 2022-10-12
[FO4] Load order is being ignored 8 2021-05-30 2022-10-22
advance Perl::Tidy pin? 0 2022-03-21 2022-07-03
Support for alpha/transparency per apple interoperability proposal 5 2021-03-12 2022-11-23
[BUG] the progress bar between ubuntu 20.04 and win10 is different 3 2021-12-07 2022-12-09
json endpoint skips NAs when returned df contains some NAs 1 2018-06-16 2022-12-09
Linux Mint: How to continue the scan progress after getting stuck at one specific file? 2 2021-12-16 2022-11-06
Detection of potentially safe log4j 1.x after manual mitigation 1 2021-12-20 2022-11-06
Scan `.jpi` and `.hpi` filetypes 1 2021-12-20 2022-11-06
assembly descriptor contains a filesystem-root relative reference, which is not cross platform compatible 1 2021-12-17 2022-11-06
Android Emulator Issue via Windows 10 1 2021-03-08 2022-11-25
Improve the documentation/replace docpress 19 2020-05-26 2022-11-22
Add performance tests 1 2019-03-23 2022-11-22
[Feature Request]table加tooltip在render不生效 0 2021-07-13 2022-10-13
Class fixture constructor called multiple times 5 2021-07-10 2022-10-04
iwd2 wyverns not spitting fast enough 0 2021-08-01 2022-10-17
Customize artifact creation with existing transformers 1 2019-09-24 2022-12-06
dff example fails in python 2.7 when the clock process is changed. 2 2018-01-23 2022-09-21
A question about 'math.bignumber()' 2 2021-08-25 2022-10-31
NPCs don't have base trait flags on any mutations 2 2022-06-10 2022-11-20
咨询,是否有参数可以控制生成的skyline 3D模型 的倒角 2 2022-06-14 2022-12-02
Re-evaluate SPIRE Server API authorization 0 2022-11-17 2022-12-10
coll() function doesn't accept the strength argument from stri_opts_collator 2 2021-03-23 2022-11-04
Implement ranking functions on top of `vec_rank()` 0 2022-08-22 2022-10-16
impossible "not in edt" state 2 2022-10-11 2022-11-28
[SUBMIT] How to link your Strapi notification systems with Novu for central management 1 2022-10-31 2022-12-09
Being able to initialise a fully populated ROM::Struct 23 2020-09-15 2022-12-05
No Tracking 4 2021-03-10 2022-01-15
EPIC: MVP for Amazon Keyspaces for Apache Cassandra 1 2022-04-25 2022-11-06
Activation Event `*` causes `ms-vscode.cpptools` to load in every directory 4 2022-03-23 2022-12-02
can't build to sites/kit.svelte.dev 2 2022-10-04 2022-12-01
Add converters from Pair and Triple to List types. 2 2021-06-02 2022-12-08
Compiler hangs when comparing functions with extensible records in type signature 1 2020-05-14 2022-11-18
Unknown or incomplete command when join BungeeCord server 2 2022-01-29 2022-11-12
Add Documentation website link to about section 1 2021-02-25 2022-11-27
There is a win10 store version which is acturally a spyware 20 2020-11-26 2022-11-27
parity_wasm are different versions 3 2022-06-07 2022-12-08
schedulers/balance_region: use heap to speedup select store for transferpeer 5 2022-06-13 2022-10-24
Support show bytes sent/received on the connection 8 2022-11-29 2022-11-29
Web Editor Shows Error on Use of Nullish coalescing operator 2 2022-04-25 2022-12-02
Some questions on building CGAL library 1 2022-03-29 2022-03-24
` .\vcpkg.exe remove opencv[contrib]` faild. 6 2022-03-29 2022-11-12
[New Port Request] Caliper 0 2022-03-29 2022-03-24
[New Port Request] <xmlrpc-c> 1 2022-03-29 2022-09-14
Any work-around for integer overflow in applying R's write_parquet()? 1 2021-11-27 2022-11-22
Require code_verifier if code_challenge provided 2 2021-10-05 2022-11-06