#  PragProg Customers Kotlin and Android Development: pg. 8 Build Gradle error: Could not get unknown property 'kotlin\_version' 

**URL:** <https://forum.devtalk.com/t/pragprog-customers-kotlin-and-android-development-pg-8-build-gradle-error-could-not-get-unknown-property-kotlin-version/70934>\
**Category:** PragProg Customers\
**Tags:** book-kotlin-and-android-development-featuring-jetpack, question\
**Created:** [27 August 2022 14:00 UTC](https://forum.devtalk.com/t/pragprog-customers-kotlin-and-android-development-pg-8-build-gradle-error-could-not-get-unknown-property-kotlin-version/70934 "2022-08-27T14:00:29Z")\
**Posts on this page:** 1\
**Showing post:** 2

<div class="post-metadata">

**Author:** ![mfazio23](https://forum.devtalk.com/user_avatar/forum.devtalk.com/mfazio23/32/528_2.png) [@mfazio23](https://forum.devtalk.com/u/mfazio23)\
**Post date:** [28 August 2022 01:29 UTC](https://forum.devtalk.com/t/pragprog-customers-kotlin-and-android-development-pg-8-build-gradle-error-could-not-get-unknown-property-kotlin-version/70934/2 "2022-08-28T01:29:57Z")

</div>

Hey Dave!  
This was a fun change Google made just after the book was published: the `kotlin_version` property is no longer automatically included when you create a project.

What used to happen is that you’d get a `buildscript { ... }` block in your project-level `build.gradle` file with an `ext { ... }` inside. This block contained any variables you wanted to use in your Gradle scripts.

You can either create this section in that project-level `build.gradle` file:

```nohighlight
buildscript {
    ext {
        kotlin_version = '1.7.10'
        // Other variables can live here
    }
    // Other blocks can be here
}

```

Otherwise, you can change the `kotlin-stdlib-jdk8` dependency to include the Kotlin version rather than use the variable:  
`implementation "org.jetbrains.kotlin:kotlin-stdlib-jdk8:1.7.10"`

Also, with newer versions of Kotlin, you should be able to exclude the explicit Kotlin dependency altogether.

Let me know if that works!  
Michael

---

_[View the full topic](https://forum.devtalk.com/t/pragprog-customers-kotlin-and-android-development-pg-8-build-gradle-error-could-not-get-unknown-property-kotlin-version/70934)._
