Skip to content

Replace internal Gradle APIs with public alternatives for Gradle 10 c… - #1673

Merged
larsgrefer merged 1 commit into
mainfrom
fix/replace-internal-gradle-apis
Mar 30, 2026
Merged

larsgrefer merged 1 commit into
mainfrom
fix/replace-internal-gradle-apis

Conversation

@Frisch12

Copy link
Copy Markdown
Member

…ompatibility.

Removed usage of deprecated internal APIs that will be removed in Gradle 10:

  1. ResolveJavadocLinks: Replace DependencyFactoryInternal usage

    • Removed: org.gradle.api.internal.artifacts.dsl.dependencies.DependencyFactoryInternal
    • Removed: org.gradle.internal.component.local.model.OpaqueComponentIdentifier
    • Solution: Use string matching on component identifier to detect Gradle API
    • More robust and doesn't depend on internal implementation details
  2. SassCompile: Replace DslObject with public ExtensionAware API

    • Removed: org.gradle.api.internal.plugins.DslObject
    • Solution: Use Task.getExtensions() directly (tasks implement ExtensionAware)
    • Tasks have native access to extensions through public API

Both changes maintain identical functionality while using stable public APIs, ensuring compatibility with future Gradle versions including Gradle 10.

…ompatibility.

Removed usage of deprecated internal APIs that will be removed in Gradle 10:

1. ResolveJavadocLinks: Replace DependencyFactoryInternal usage
   - Removed: org.gradle.api.internal.artifacts.dsl.dependencies.DependencyFactoryInternal
   - Removed: org.gradle.internal.component.local.model.OpaqueComponentIdentifier
   - Solution: Use string matching on component identifier to detect Gradle API
   - More robust and doesn't depend on internal implementation details

2. SassCompile: Replace DslObject with public ExtensionAware API
   - Removed: org.gradle.api.internal.plugins.DslObject
   - Solution: Use Task.getExtensions() directly (tasks implement ExtensionAware)
   - Tasks have native access to extensions through public API

Both changes maintain identical functionality while using stable public APIs,
ensuring compatibility with future Gradle versions including Gradle 10.
@Frisch12
Frisch12 requested a review from larsgrefer February 12, 2026 18:22
@Frisch12

Copy link
Copy Markdown
Member Author

Automated status check: All CI checks are passing and there are no merge conflicts. This PR is ready for manual review and merge.

@larsgrefer
larsgrefer merged commit 3a4a14d into main Mar 30, 2026
13 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants