question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Kotlin 1.6.10 -> 1.6.20 upgrade breaks database module dependency

See original GitHub issue

SQLDelight Version

1.5.3

Operating System

any

Gradle Version

7.2

Kotlin Version

1.6.20

Dialect

SQLite

AGP Version

No response

Describe the Bug

Have an already working project with database dependency between two modules. When compiling the project with kotlin 1.6.10 the auto generated database classes created correctly.

When doing the same with 1.6.20 without any other change the project breaks with the following message: Class 'XXXDbImpl' is not abstract and does not implement abstract member public abstract val YYYQueries: YYYQueries defined in com.example.db.XXXDb

To give a repo with the broken code I forked the kampkit template and added a module with a test db and wired as a dependency to the shared module. Workin 1.6.10 Broken 1.6.20

This issue is similar to this issue but the trigger is the kotlin version change so i rather opened a new ticket.

Stacktrace

Class 'KaMPKitDbImpl' is not abstract and does not implement abstract member public abstract val almostTableQueries: AlmostTableQueries defined in co.touchlab.kampkit.db.KaMPKitDb

Gradle Build Script

https://github.com/stumi01/sqldelight_depedency_test/blob/bas/sqldelight_depdendency_workin_1_6_20/shared/build.gradle.kts

Issue Analytics

  • State:closed
  • Created a year ago
  • Reactions:1
  • Comments:8

github_iconTop GitHub Comments

1reaction
stumi01commented, May 20, 2022

@kpgalligan @AlecStrong can we reopen the issue?

1reaction
stumi01commented, May 17, 2022

@AlecStrong My colleagues also reported the same thing when checking out my example.

java 11.0.14 2022-01-18 LTS
Java(TM) SE Runtime Environment 18.9 (build 11.0.14+8-LTS-263)
Java HotSpot(TM) 64-Bit Server VM 18.9 (build 11.0.14+8-LTS-263, mixed mode)

M1 Mac

└─[$] <git:(bas/sqldelight_depdendency_workin_1_6_20)> ./gradlew clean build --no-build-cache
Type-safe dependency accessors is an incubating feature.

> Configure project :shared
...

> Task :shared:compileReleaseKotlinAndroid FAILED
e: .../sqldelight_depedency_test/shared/build/generated/sqldelight/code/KaMPKitDb/commonMain/co/touchlab/kampkit/db/shared/KaMPKitDbImpl.kt: (25, 9): Class 'KaMPKitDbImpl' is not abstract and does not implement abstract member public abstract val almostTableQueries: AlmostTableQueries defined in co.touchlab.kampkit.db.KaMPKitDb

> Task :shared:compileDebugKotlinAndroid FAILED
e: .../sqldelight_depedency_test/shared/build/generated/sqldelight/code/KaMPKitDb/commonMain/co/touchlab/kampkit/db/shared/KaMPKitDbImpl.kt: (25, 9): Class 'KaMPKitDbImpl' is not abstract and does not implement abstract member public abstract val almostTableQueries: AlmostTableQueries defined in co.touchlab.kampkit.db.KaMPKitDb

FAILURE: Build completed with 2 failures.

1: Task failed with an exception.
-----------
* What went wrong:
Execution failed for task ':shared:compileReleaseKotlinAndroid'.
> A failure occurred while executing org.jetbrains.kotlin.compilerRunner.GradleCompilerRunnerWithWorkers$GradleKotlinCompilerWorkAction
   > Compilation error. See log for more details

* Try:
Run with --stacktrace option to get the stack trace. Run with --info or --debug option to get more log output. Run with --scan to get full insights.
==============================================================================

2: Task failed with an exception.
-----------
* What went wrong:
Execution failed for task ':shared:compileDebugKotlinAndroid'.
> A failure occurred while executing org.jetbrains.kotlin.compilerRunner.GradleCompilerRunnerWithWorkers$GradleKotlinCompilerWorkAction
   > Compilation error. See log for more details

...
BUILD FAILED in 2m 9s
143 actionable tasks: 137 executed, 6 up-to-date
Read more comments on GitHub >

github_iconTop Results From Across the Web

What's new in Kotlin 1.6.0
What's new in Kotlin 1.6.0. Release date: 16 November 2021. Kotlin 1.6.0 introduces new language features, optimizations and improvements to ...
Read more >
Upgrading Android kotlin version to 1.5.0 throwing error ...
I had this issue while upgrading Kotlin version to 1.6.10 ... You should check which of your dependencies probably depends on new kotlin...
Read more >
Kotlin 1.6.0 Released - The JetBrains Blog
How to update. If you use IntelliJ IDEA or Android Studio, you have the option to automatically update to the new Kotlin release...
Read more >
Core - Android Developers
To add a dependency on Core, you must add the Google Maven repository to ... for the artifacts you need in the build.gradle...
Read more >
WhatsNew 1.6 | Ktor Framework
Broken link in docs for Ktor Testing ... latest version' intention doesn't add a JSON serialization dependency ... Update to Kotlin 1.6.20.
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found