Skip to content
New issue

Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? # to your account

Plugin not longer working after Kotlin 1.1.2 update. #80

Closed
ethauvin opened this issue Apr 28, 2017 · 13 comments
Closed

Plugin not longer working after Kotlin 1.1.2 update. #80

ethauvin opened this issue Apr 28, 2017 · 13 comments

Comments

@ethauvin
Copy link

All the Kobalt projects that I have updated to Kotlin 1.1.2, per IDEA's popup recommendation, are no longer functional.

They get into the following loop over and over:

2017-04-27 16_55_52-kobalt-exec - k__kotlin_kobalt-exec - execplugin kt - intellij idea 2017 1 2
2017-04-27 16_56_12-kobalt-exec - k__kotlin_kobalt-exec - execplugin kt - intellij idea 2017 1 2
2017-04-27 16_56_30-kobalt-exec - k__kotlin_kobalt-exec - execplugin kt - intellij idea 2017 1 2
2017-04-27 16_58_20-kobalt-exec - k__kotlin_kobalt-exec - execplugin kt - intellij idea 2017 1 2

I've tried selecting as Kotlin (Kobalt) module but that just throws an error.

@ethauvin
Copy link
Author

ethauvin commented Apr 28, 2017

Fix didn't help. The only difference I could see is that now I can select as Kotlin (Kobalt) module, which does stop the loop behavior, but now it is not resolving dependencies:

2017-04-28 09_19_06-kobalt-exec - k__kotlin_kobalt-exec - kobalt-exec - src_main_kotlin_net

@ethauvin
Copy link
Author

ethauvin commented May 1, 2017

Any progress on this? Still can't use the plugin while it's looping like that.

@cbeust
Copy link
Owner

cbeust commented May 1, 2017

For what it's worth, everything seems to be working for me (both on MacOS and Windows).

@dmitry-zhuravlev, any idea what's going on with Eriks' configuration?

@ethauvin
Copy link
Author

ethauvin commented May 1, 2017

To be sure I created a new project:

kobaltw --init kotlin

And imported it into IDEA:

2017-05-01 11_19_41-plugin-test - k__test_plugin-test - intellij idea 2017 1 2
2017-05-01 11_20_06-plugin-test - k__test_plugin-test - intellij idea 2017 1 2
2017-05-01 11_20_18-plugin-test - k__test_plugin-test - intellij idea 2017 1 2
2017-05-01 11_21_55-plugin-test - k__test_plugin-test - plugin-test - _src_main_kotlin_com_ex
2017-05-01 11_22_32-plugin-test - k__test_plugin-test - plugin-test - _src_main_kotlin_com_ex

@dmitry-zhuravlev
Copy link
Collaborator

@ethauvin I think the problem here that you choose not proper Kotlin lib configurator.
The proper one is as Kotlin (Kobalt) module. The rest configurators have no idea about Kobalt project and cannot adjust the Build.kt in corresponding way.

Also there was a dissucussion with @cbeust about sending Kotlin libs directly to plugin when refresh button pressed: #79 (comment)
In case if we implement such behaviour the Configure Kotlin tooltip will be not needed anymore.
But this is not work yet....

@cbeust
Copy link
Owner

cbeust commented May 2, 2017

@dmitry-zhuravlev But until this is done automatically, just specifying kotlin-stdlib and kotlin-runtime in your dependencies should work as well, right?

@dmitry-zhuravlev
Copy link
Collaborator

just specifying kotlin-stdlib and kotlin-runtime in your dependencies should work as well, right?

Yep, this is what exactly what as Kotlin (Kobalt) module do. But also can be done manually simple by editing Build.kt dependencies section.

FYI just created some PR to Kotlin plugin: JetBrains/kotlin#1067
this will help to hide as Kotlin (Java) module and as Kotlin (JavaScript) module. It would be good if JB accept it and this will hide default configurators just to not confuse users.

@ethauvin
Copy link
Author

ethauvin commented May 2, 2017

@dmitry-zhuravlev As stated in #80 (comment), choosing as Kotlin (Kobalt) module does not work either. It does stop the looping but no longer finds Kobalt's own libraries.

@ethauvin
Copy link
Author

ethauvin commented May 2, 2017

Here it is in pictures:

2017-05-02 09_26_49-kobalt-exec - k__kotlin_kobalt-exec - kobalt-exec - src_main_kotlin_net
2017-05-02 09_27_06-configure kotlin in project
2017-05-02 09_27_56-kobalt-exec - k__kotlin_kobalt-exec - build kt - _kobalt_src_build kt - i
2017-05-02 09_28_12-kobalt-exec - k__kotlin_kobalt-exec - build kt - _kobalt_src_build kt - i
2017-05-02 09_29_50-kobalt-exec - k__kotlin_kobalt-exec - kobalt-exec - src_main_kotlin_net

Basically still unusable.

@dmitry-zhuravlev
Copy link
Collaborator

Hmm... But on the last screenshot I see that some classes from com.beust.* and com.google.* packages are not resolved. I guess that this should be from compileOnly("com.beust:$kobaltDependency:") dependency.
I tried to add compile("org.jetbrains.kotlin:kotlin-stdlib:1.1.2-2") in Build.kt and all classes from the standard Kotlin lib resolved fine.

@cbeust did Kobalt server even send compileOnly dependencies to plugin?
@ethauvin can you try to change from compileOnly to compile and press "Import changes" on tooltip?

@ethauvin
Copy link
Author

ethauvin commented May 3, 2017

Yes, that fixed the issue. Makes no sense, compileOnly was implemented weeks ago, and there weren't any issues until I updated the Kotlin runtime.

@ethauvin
Copy link
Author

ethauvin commented May 9, 2017

@cbeust can you make sure that compileOnly deps are sent to the plugin? I'd do it, but I know nothing about the server portion of kobalt.

@cbeust
Copy link
Owner

cbeust commented May 9, 2017

Will do but you can already quickly check yourself:

./kobaltw --server --force --log 2

Then push the Sync button in IDE, the server should give you the list of dependencies it's sending to the IDE.

# for free to join this conversation on GitHub. Already have an account? # to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants