Skip to content

Update ktlint to 1.x #10894

@TobiGr

Description

@TobiGr

Problem

ktlint is currently failing our vulnerability / snyk pipelines. One of its dependencies is vulnerable (CVE-2023-6378). This has no implications on NewPipe itself, because ktlint is used to format code while developing.

Upgrading ktlint is easy and requires following changes:

  • within build.gradle: ktlint 'com.pinterest:ktlint:0.45.2' -> ktlint 'com.pinterest.ktlint:ktlint-cli:1.x.x'
  • Adapting Kotlin code to current style guides:
    • Rename: org.schabi.newpipe.info_list -> org.schabi.newpipe.infoList
    • Fix some variable naming schemes

The problem is that all Kotlin files are going to be reformatted which causes merge conflicts with all PRs touching Kotlin code

Proposed solution

Wait with upgrade until most PRs are merged, update it before starting the rewrite

Metadata

Metadata

Assignees

No one assigned

    Labels

    code qualityImprovements to the codebase to improve the code qualitydependencyIssues and PRs related to dependenciesdiscussionThis needs to be discussed before anything is done

    Type

    No type

    Projects

    Status

    Done

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions