Skip to content
New issue

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

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

Already on GitHub? Sign in to your account

Getting NoSuchMethodError kotlin.collections.ArraysKt.copyInto Exception #518

Closed
1 of 7 tasks
AbhiInfy opened this issue Jul 18, 2020 · 4 comments
Closed
1 of 7 tasks
Labels
lang:kotlin question M-T: User needs support to use the project

Comments

@AbhiInfy
Copy link

AbhiInfy commented Jul 18, 2020

Issue Type

TODO:
Place an x in one of the [ ].

  • Bug
  • Enhancement / Feature request
  • Question
  • Documentation

Description

TODO:
(Describe your issue here)
Getting NoSuchMethodError kotlin.collections.ArraysKt.copyInto([B[BIII) while starting application
Description:

An attempt was made to call a method that does not exist. The attempt was made from the following location:

okio.Segment.writeTo(Segment.kt:169)

The following method did not exist:

kotlin.collections.ArraysKt.copyInto([B[BIII)[B

The method's class, kotlin.collections.ArraysKt, is available from the following locations:

jar:file:/C:/Users/**/.m2/repository/org/jetbrains/kotlin/kotlin-stdlib/1.2.71/kotlin-stdlib-1.2.71.jar!/kotlin/collections/ArraysKt.class

It was loaded from the following location:

file:/C:/Users/**/.m2/repository/org/jetbrains/kotlin/kotlin-stdlib/1.2.71/kotlin-stdlib-1.2.71.jar

Action:

Correct the classpath of your application so that it contains a single, compatible version of kotlin.collections.ArraysKt

I am trying to run com.slack.api.Slack application by IntelliJ IDE in Java to send the message in slack. I am using Java 1.8 and SpringBoot

(only for a bug report)

TODO:
If this is a bug report, filling out the following details about bugs will help us solve your issue sooner.

The issue is reproducible in:

  • Module Version: TODO: x.y.z
  • JDK Version: TODO: Run java -version and pates the result here
  • OS Version etc: TODO: if the issue happens only with specific OS

The steps to reproduce are:
1.
2.
3.

The expected result is:
TODO: What you expected to happen

The actual result is:
TODO: What actually happened

Requirements (place an x in each of the [ ])

TODO:

  • I've read and understood the Contributing guidelines and have done my best effort to follow them.
  • I've read and agree to the Code of Conduct.
  • I've searched for any related issues and avoided creating a duplicate issue.
@seratch
Copy link
Member

seratch commented Jul 18, 2020

@AbhiInfy

NoSuchMethodError kotlin.collections.ArraysKt.copyInto([B[BIII)

The error message indicates your build settings (or IDE settings) have some binary-compatibility issue with the Kotlin standard library.

kotlin-stdlib/1.2.71

This SDK requires okhttp library, which depends on Kotlin 1.3.x. Try Kotlin 1.3.x instead.

@seratch seratch added lang:kotlin question M-T: User needs support to use the project labels Jul 18, 2020
@seratch
Copy link
Member

seratch commented Jul 24, 2020

Let me know if you need further help here. Please allow me to close this issue after waiting for your response for a few more days.

@seratch
Copy link
Member

seratch commented Jul 30, 2020

Please allow me to close this issue after waiting for your response for a few more days.

Closing now. Please feel free to reopen if needed.

@seratch seratch closed this as completed Jul 30, 2020
@lwl5219
Copy link

lwl5219 commented Feb 8, 2021

This SDK requires okhttp library, which depends on Kotlin 1.3.x. Try Kotlin 1.3.x instead.

I replace the version with 1.3.70. It works for me.

$ mvn dependency:tree

[INFO] \- com.squareup.okhttp3:okhttp:jar:4.9.1:compile
[INFO]    +- com.squareup.okio:okio:jar:2.8.0:compile
[INFO]    |  \- org.jetbrains.kotlin:kotlin-stdlib-common:jar:1.4.0:compile
[INFO]    \- org.jetbrains.kotlin:kotlin-stdlib:jar:1.2.71:compile
[INFO]       \- org.jetbrains:annotations:jar:13.0:compile
<dependency>
    <groupId>com.squareup.okhttp3</groupId>
    <artifactId>okhttp</artifactId>
    <version>4.9.1</version>
</dependency>
<dependency>
    <groupId>org.jetbrains.kotlin</groupId>
    <artifactId>kotlin-stdlib</artifactId>
    <version>1.3.70</version>
</dependency>

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
lang:kotlin question M-T: User needs support to use the project
Projects
None yet
Development

No branches or pull requests

3 participants