Business
Jobs
  • About Us
  • Solutions
    • Job Postings
      Post your job and receive qualified candidates in 48h.
    • Candidate Assessments
      500+ technical and psychological tests, plus anti-fraud.
    • Headhunting
      Tailor-made executive search from start to finish.
    • Payroll + EOR
      Payroll dispersal and EOR across 15+ LATAM countries.
  • Pricing
  • Jobs

0

471
Views
Conflicto de dependencia jetified-kotlin-reflect

Cuando construyo mi proyecto de Android, recibo el siguiente mensaje:

 w: Runtime JAR files in the classpath should have the same version. These files were found in the classpath: /home/janek/.gradle/caches/modules-2/files-2.1/org.jetbrains.kotlin/kotlin-stdlib-jdk7/1.3.10/4d147bf43060dc43d61b096e24da1e67dfe0c032/kotlin-stdlib-jdk7-1.3.10.jar (version 1.3) /home/janek/.gradle/caches/transforms-1/files-1.1/kotlin-reflect-1.0.6.jar/beba9d201a205f30041b70982540014d/jetified-kotlin-reflect-1.0.6.jar (version 1.0) /home/janek/.gradle/caches/modules-2/files-2.1/org.jetbrains.kotlin/kotlin-stdlib/1.3.11/4cbc5922a54376018307a731162ccaf3ef851a39/kotlin-stdlib-1.3.11.jar (version 1.3) /home/janek/.gradle/caches/modules-2/files-2.1/org.jetbrains.kotlin/kotlin-stdlib-common/1.3.11/d8b8e746e279f1c4f5e08bc14a96b82e6bb1de02/kotlin-stdlib-common-1.3.11.jar (version 1.3) w: Some runtime JAR files in the classpath have an incompatible version. Consider removing them from the classpath

Pero no tengo idea de por qué jetified-kotlin-reflect está ahí, ya que no es una dependencia y ni siquiera aparece en androidDependencies .

¿Sabes de dónde viene o cómo puedo solucionar este error?

over 4 years ago · Santiago Trujillo
1 answers
Answer question

0

Supongo que el complemento kotlin agregará automáticamente kotlin-relfection.jar si usa funciones de reflexión como la sintaxis literal de clase .

En la plataforma Java, el componente de tiempo de ejecución necesario para usar las funciones de reflexión se distribuye como un archivo JAR independiente (kotlin-reflect.jar). Esto se hace para reducir el tamaño requerido de la biblioteca en tiempo de ejecución para las aplicaciones que no utilizan funciones de reflexión. Si usa la reflexión, asegúrese de que el archivo .jar se agregue a la ruta de clase de su proyecto.

Arreglé las advertencias agregando explícitamente

 implementation "org.jetbrains.kotlin:kotlin-reflect:$kotlin_version"

a mi build.gradle.

over 4 years ago · Santiago Trujillo Report
Answer question
Find remote jobs

Discover the new way to find a job!

Top jobs
Top job categories
Business
Post vacancy Pricing Sales
Legal
Terms and conditions Privacy policy
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Show me some job opportunities
There's an error!