# how to add gatling gradle plugin with scalaVersion extension

**URL:** <https://community.gatling.io/t/how-to-add-gatling-gradle-plugin-with-scalaversion-extension/5958>\
**Category:** Gatling (Open-Source)\
**Created:** [January 14, 2021, 11:42am UTC](https://community.gatling.io/t/how-to-add-gatling-gradle-plugin-with-scalaversion-extension/5958 "2021-01-14T11:42:00Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![RaviG](https://avatars.discourse-cdn.com/v4/letter/r/edb3f5/32.png) [@RaviG](https://community.gatling.io/u/RaviG)\
**Post date:** [January 14, 2021, 11:42am UTC](https://community.gatling.io/t/how-to-add-gatling-gradle-plugin-with-scalaversion-extension/5958/1 "2021-01-14T11:42:00Z")

</div>

Hi,

My project written in kotlin and gradle build file written in kotlin DSL

My build file look like below  
**loadtesting.gradle.kts**

plugins {  
id( “io.gatling.gradle”) version “3.5.0”  
}

when i build it says

_A problem occurred configuring project ‘:loadtesting’._  
_\> Could not resolve all dependencies for configuration ‘:loadtesting:detachedConfiguration1’._  
_\> Conflict(s) found for the following module(s):_  
_- org.scala-lang:scala-library between versions 2.13.3, 2.13.0, 2.13.2 and 2.13.1_  
_- com.typesafe:config between versions 1.4.1 and 1.4.0_  
_- org.scala-lang:scala-reflect between versions 2.13.3 and 2.13.0_  
_Run with:_  
_–scan or_  
_:loadtesting:dependencyInsight --configuration detachedConfiguration1 --dependency org.scala-lang:scala-library_  
_to get more insight on how to solve the conflict._

Could someone guild me how to pass scala version to kotlin gradle build file (not groovy)

Thanks in advance  
Ravi G

---

<div class="post-metadata">

**Author:** ![slandelle](https://dub1.discourse-cdn.com/flex013/user_avatar/community.gatling.io/slandelle/32/4_2.png) [@slandelle](https://community.gatling.io/u/slandelle)\
**Post date:** [January 14, 2021, 12:26pm UTC](https://community.gatling.io/t/how-to-add-gatling-gradle-plugin-with-scalaversion-extension/5958/2 "2021-01-14T12:26:53Z")

</div>

Unresolved dependencies usually means a network issue when trying to download artifacts from maven central.  
If you’re in a corporate network where you’re required to go through a proxy, make sure to confirm it.  
If you’re required to use an internal repository such as Nexus or Artifactory, make sure to configure it.

---

<div class="post-metadata">

**Author:** ![RaviG](https://avatars.discourse-cdn.com/v4/letter/r/edb3f5/32.png) [@RaviG](https://community.gatling.io/u/RaviG)\
**Post date:** [January 15, 2021, 1:10am UTC](https://community.gatling.io/t/how-to-add-gatling-gradle-plugin-with-scalaversion-extension/5958/3 "2021-01-15T01:10:40Z")

</div>

i found the cause of the issue and adding it here so that it can helpful for others. in my build file it has

dependencyManagement {  
resolutionStrategy {  
failOnVersionConflict()  
}

}

gatling plugin finds multiple scala versions and resolutionStrategy throws above error.

Regards  
RaviG

---

<div class="post-metadata">

**Author:** ![slandelle](https://dub1.discourse-cdn.com/flex013/user_avatar/community.gatling.io/slandelle/32/4_2.png) [@slandelle](https://community.gatling.io/u/slandelle)\
**Post date:** [January 15, 2021, 7:17am UTC](https://community.gatling.io/t/how-to-add-gatling-gradle-plugin-with-scalaversion-extension/5958/4 "2021-01-15T07:17:42Z")

</div>

Such check is completely overkill and doesn’t work in practice as transitive dependencies can perfectly pull different yet compatible versions.
