# ktlint 2.0.0-ALPHA-4 - Product: ktlint (https://whatsnew.fyi/product/ktlint) - Vendor: Pinterest - Date: 2026-08-21 - Version: 2.0.0-ALPHA-4 - Original notes: https://github.com/ktlint/ktlint/releases/tag/2.0.0-ALPHA-4 - Permalink: https://whatsnew.fyi/product/ktlint/releases/2.0.0-alpha-4 - Labels: Pre-release What's New is an index, not a publisher: every entry below links to the vendor's own release notes, which are the authoritative source. Entries are labelled where they are hand-curated sample data, pre-releases, or drawn from a secondary source such as a developer blog. Reuse: the summaries, labels and curation here are © What's New. Quote freely with attribution and a link back; wholesale republication of the corpus is not permitted — terms: https://whatsnew.fyi/terms. The vendors' own release notes remain their publishers'. --- - **changed** — Change Maven coordinates from com.pinterest.ktlint to io.github.ktlint - **changed** — Execute all rules on same AST Node before proceeding to next AST Node - **added** — Add RuleV2 to enforce autocorrect approve visitor - **added** — Add rule call-expression-wrapping and improve wrapping in chain-method-continuation and function-literal - **added** — Add blank line check between package and import statements - **added** — Add experimental rule lambda-return - **changed** — Update Kotlin to v2.4.0 and set Java compilation to 26 - **changed** — Enable rule blank-line-before-declaration by default for android_studio - **added** — Add experimental rules for blank lines between sections - **added** — Add GraalVM native-image binaries to release for Linux, macOS, and Windows - **added** — Add experimental rule no-blank-line-at-start-of-file - **fixed** — Handle trailing comments on when entries in BlankLineBetweenWhenConditions - **fixed** — Keep no-unused-import as opt-in - **fixed** — Fix handling of EOL-comment in paren-spacing - **fixed** — Respect suppressions on ktlint:standard:max-line-length - **fixed** — Keep EOL comments on same line as when condition - **fixed** — Do not remove UTF BOM character - **fixed** — Do not wrap an annotated expression before a lambda expression - **fixed** — Fix writing formatted code containing a percent character provided via --stdin IMPORTANT: This project is no longer maintained by Pinterest. As a result the Maven coordinates of the project have changed from `com.pinterest.ktlint` to `io.github.ktlint`. Read more in the [documentation](https://ktlint.github.io/ktlint/dev-snapshot/api/migrate-to-ktlint-2.x/). Note: Earlier alpha versions are not available as GitHub, nor as Maven Central download due to problems in fixing the release pipeline. ###### 🆕 Features * Execute all rules on same AST Node before proceeding to next AST Node (possibly breaking change) - [#3252](https://github.com/ktlint/ktlint/pull/3252), by @paul-dingemans Due to changing the order in which rules are executed, this is a potentially breaking change when rules are not well written. Normal rules only manipulate the AST for nodes that have not yet been visited. In case a rule for a given AST Node decides to manipulate an AST Node that already has been visited before, this might result in a failure. * Add RuleV2 to enforce autocorrect approve visitor - [#3241](https://github.com/ktlint/ktlint/pull/3241), by @paul-dingemans * Add rule `call-expression-wrapping`, and improve wrapping in `chain-method-continuation` and `function-literal` - [#3253](https://github.com/ktlint/ktlint/pull/3253), by @paul-dingemans * Add blank line check between package and import statements - [#3266](https://github.com/ktlint/ktlint/pull/3266), by @maheen8q * Add experimental rule `lambda-return` - [#3274](https://github.com/ktlint/ktlint/pull/3274), by @paul-dingemans * Update kotlin to v2.4.0 / set java compilation to 26 - [#3316](https://github.com/ktlint/ktlint/pull/3316), by @paul-dingemans * Enable rule `blank-line-before-declaration` by default for `android_studio` - [#3318](https://github.com/ktlint/ktlint/pull/3318), by @paul-dingemans * Add experimental rules for blank lines between sections - [#3319](https://github.com/ktlint/ktlint/pull/3319), by @paul-dingemans * feat: add GraalVM native-image binaries to release (linux, macOS, Windows) - [#3284](https://github.com/ktlint/ktlint/pull/3284), by @zeitlinger * Add experimental rule no-blank-line-at-start-of-file - [#3361](https://github.com/ktlint/ktlint/pull/3361), by @paul-dingemans ###### 🔧 Fixes * Handle trailing comments on when entries in `BlankLineBetweenWhenConditions` - [#3177](https://github.com/ktlint/ktlint/pull/3177), by @jonapoul * Keep `no-unused-import` as opt-in - [#3192](https://github.com/ktlint/ktlint/pull/3192), by @paul-dingemans * Fix handling of EOL-comment in `paren-spacing` - [#3236](https://github.com/ktlint/ktlint/pull/3236), by @SubhrajyotiSen * Fix Square brackets spacing rule heading level - [#3244](https://github.com/ktlint/ktlint/pull/3244), by @moon-dylan * Respect suppressions on "ktlint:standard:max-line-length" - [#3255](https://github.com/ktlint/ktlint/pull/3255), by @paul-dingemans * Keep EOL comments on same line as when condition - [#3261](https://github.com/ktlint/ktlint/pull/3261), by @paul-dingemans * Do not remove UTF BOM character - [#3264](https://github.com/ktlint/ktlint/pull/3264), by @paul-dingemans * Do not wrap an annotated expression before a lambda expression - [#3268](https://github.com/ktlint/ktlint/pull/3268), by @paul-dingemans * Fix writing formatted code containing a "%" character provided via --stdin - [#3281](https://github.com/ktlint/ktlint/pull/3281), by @paul-dingemans * Do not join supertype with previous line when that line ends with and EOL comment - [#3312](https://github.com/ktlint/ktlint/pull/3312), by @paul-dingemans * Prevent throwing a NullPointerException after fixing EOL comment by `comment-spacing` rule - [#3314](https://github.com/ktlint/ktlint/pull/3314), by @paul-dingemans * Load `.editorconfig` correctly when `--stdin-path` is a relative path - [#3322](https://github.com/ktlint/ktlint/pull/3322), by @paul-dingemans * Fix call expression wrapping when function literal has an empty multiline block body. - [#3353](https://github.com/ktlint/ktl _[Truncated at 4000 characters — full notes: https://github.com/ktlint/ktlint/releases/tag/2.0.0-ALPHA-4]_