kdoctor icon indicating copy to clipboard operation
kdoctor copied to clipboard

Android Studio: Cannot detect installed Kotlin Multiplatform Mobile Plugin

Open wumo opened this issue 1 year ago • 1 comments

Running kdoctor shows:

[x] Android Studio
    * Android Studio (2021.3)
      Location: /Users/wumo/Library/Application Support/JetBrains/Toolbox/apps/AndroidStudio/ch-0/213.7172.25.2113.9014738/Android Studio.app
      Bundled Java: openjdk 11.0.13 2021-10-19
      Kotlin Plugin: 213-1.7.10-release-for-android-studio-AS6777.52
      Kotlin Multiplatform Mobile Plugin: not installed
          Install Kotlin Multiplatform Mobile plugin - https://plugins.jetbrains.com/plugin/14936-kotlin-multiplatform-mobile

But the plugin is installed: WeChatWorkScreenshot_7919f94a-38d4-4240-a4b2-9fc3a88af95a

wumo avatar Sep 21 '22 10:09 wumo

Same issue for me.

Partial kdoctor output:

[x] Android Studio
    * Android Studio (2021.3)
      Location: /Users/wblondel/Library/Application Support/JetBrains/Toolbox/apps/AndroidStudio/ch-0/213.7172.25.2113.9014738/Android Studio.app
      Bundled Java: openjdk 11.0.13 2021-10-19
      Kotlin Plugin: 213-1.7.10-release-for-android-studio-AS6777.52
      Kotlin Multiplatform Mobile Plugin: not installed
          Install Kotlin Multiplatform Mobile plugin - https://plugins.jetbrains.com/plugin/14936-kotlin-multiplatform-mobile

Installed plugin: image

macOS 12.6 on M1

wblondel avatar Oct 02 '22 07:10 wblondel

@wumo @wblondel Maybe you've multiple Android Studio installed, and the one you're running is not the same one mentioned in the error you're getting?

findjigar avatar Oct 20 '22 15:10 findjigar

@findjigar No, only one version android studio is installed. I also check the android studio app listed in kdoctor and kotlin multiplatform mobile plugin is installed.

wumo avatar Oct 20 '22 16:10 wumo

Hi, I have the same issue and I believe kdoctor does not check the location of kmm plugin correctly.

As I tested, kdocter looks for plugins installed in a default location like:

  • $HOME/Library/Application Support/JetBrains/Toolbox/apps/AndroidStudio/ch-1/222.4345.14.2221.9178080/Android Studio Preview.app/Contents
  • $HOME/Library/Application Support/Google/AndroidStudioPreview2022.2

but, with JetBrains Toolbox App, the kmm plugin was actually installed in the "$location.plugins" directory like:

$HOME/Library/Application Support/JetBrains/Toolbox/apps/AndroidStudio/ch-1/222.4345.14.2221.9178080/Android Studio Preview.app.plugins

So I guess https://github.com/mhorioka/kdoctor/blob/3d15c6f34790fa85097bad35108d32759fc7f223/kdoctor/src/macosMain/kotlin/org/jetbrains/kotlin/doctor/entity/Application.kt needs to be updated.

mhorioka avatar Oct 23 '22 16:10 mhorioka

I have the same issue and I have installed Android Studio trough Jetbrains Toolbox

jQrgen avatar Nov 02 '22 13:11 jQrgen

Yep, same for me. The issue is still there, someone should review the PR 😁

Sartoric avatar Nov 07 '22 13:11 Sartoric

I've fixed the issue during refactoring kdoctor. Should be OK in the next release

If you want, you can try to run it via ./gradlew runDebugExecutableMacosX64 on wip branch

terrakok avatar Nov 07 '22 15:11 terrakok