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.

Kotlinter 3.7.0 removes needed star imports

See original GitHub issue

Kotlinter removes the star import here, which makes our builds fail:

import com.example.processor.*
import com.example.processor.LocationType.CITY
import com.example.processor.LocationType.COUNTRY

Here’s LocationType:

enum class LocationType {
    CITY,
    COUNTRY;
}

I refer to CITY, COUNTRY and LocationType in the calling code.

Issue Analytics

  • State:closed
  • Created 2 years ago
  • Reactions:4
  • Comments:17 (7 by maintainers)

github_iconTop GitHub Comments

1reaction
jeremymailencommented, Apr 8, 2022

Fixed via 3.10.0 release

1reaction
henrik242commented, Nov 15, 2021

Never mind, I still had disabledRules = arrayOf("import-ordering") in place, which overwrote any disabled_rules in .editorconfig. After removing disabledRules from the kotlinter config the .editorconfig worked, and still had the bug described here.

Read more comments on GitHub >

github_iconTop Results From Across the Web

org.jmailen.kotlinter - Gradle Plugin Portal
Created 10 September 2022. Lint and formatting for Kotlin using ktlint with configuration-free setup on JVM and Android projects. Other versions.
Read more >
kotlin - Ktlint doesn't allow wildcard import? (Using IntelliJ auto ...
Since I use IntelliJ, I often rely on auto import where many subpackages are grouped into a wildcard (*). Is this what ktline...
Read more >
Changelog and Migration Guide - Detekt
... Disable UnusedImports for the Detekt project - #4741; Remove Unnecesary ... required.set(true) // reports can also be enabled and disabled at the...
Read more >
org.jmailen.gradle » kotlinter-gradle - Maven Repository
Version Vulnerabilities Usages Date 3.10.x 3.10.0 Gradle Plugins 2 Apr 08, 2022 3.9.x 3.10.x 3.9.0 Gradle Plugins 2 Feb 22, 2022 3.9.x 3.8.x 3.8.0 Gradle Plugins...
Read more >
Order imports - OpenRewrite
OrderImports Group and order imports. ... Remove unnecessary imports. Usage. This recipe has no required configuration parameters and comes from a rewrite ...
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