Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Nested composite builds are not "flattened" #28899

Open
reline opened this issue Apr 22, 2024 · 2 comments
Open

Nested composite builds are not "flattened" #28899

reline opened this issue Apr 22, 2024 · 2 comments
Labels
a:bug in:composite-builds including BuildIdentifier

Comments

@reline
Copy link

reline commented Apr 22, 2024

Current Behavior

A nested composite build is not in the list of included builds for the root project.

Expected Behavior

When a composite build is included in another composite build, both builds have the same parent. In other words, the nested composite build structure is flattened.

https://docs.gradle.org/8.7/userguide/composite_builds.html#included_builds

Context (optional)

No response

Steps to Reproduce

// settings.gradle.kts
includeBuild("core")
// build.gradle.kts
println("Root project included builds: ${gradle.includedBuilds.joinToString(",") { it.name }}")
// core/settings.gradle.kts
includeBuild("../thirdparty")
// core/build.gradle.kts
println("Core project included builds: ${gradle.includedBuilds.joinToString(",") { it.name }}")
$ ./gradlew --dry-run

> Configure project :core
Core project included builds: thirdparty

> Configure project :
Root project included builds: core
:help SKIPPED

BUILD SUCCESSFUL in 764ms

Minimum reproducible example here: https://github.com/reline/gradle-nested-composite-build

Gradle version

8.7

Build scan URL (optional)

No response

Your Environment (optional)

No response

@ov7a
Copy link
Member

ov7a commented Apr 22, 2024

This issue needs a decision from the team responsible for that area. They have been informed. Response time may vary.


This is indeed inconsistent, so the team will decide if we should change the output or just update the docs.

@ov7a ov7a added in:composite-builds including BuildIdentifier 👋 team-triage Issues that need to be triaged by a specific team and removed to-triage labels Apr 22, 2024
@mlopatkin
Copy link
Member

This documentation issue is confirmed.


We have several places where "flattening" can happen, so maybe the docs are talking about something else, like gradle.parent. We need to figure that out and clarify.

@mlopatkin mlopatkin removed the 👋 team-triage Issues that need to be triaged by a specific team label Apr 23, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
a:bug in:composite-builds including BuildIdentifier
Projects
None yet
Development

No branches or pull requests

3 participants