-
Notifications
You must be signed in to change notification settings - Fork 4.8k
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
Option to fail build if a subproject is included but there is no build file #17540
Comments
Example of where it crops up Luckily the problem won't happen now that I'm switching the build files back to a static name, but previously just because of a misnamed file the tests weren't running at all |
We may reconsider it in the future but we don't plan to add anything like that right now. |
To clarify: a project with no build file is a supported setup even though it is not a recommended one. |
@ljacomet Things can change for Gradle 8 right? I'd look through a UX lens - very easy to opt into an emtpy build file, even with just a |
I understand what you are asking but the existing behavior also has reasons. And those are unlikely to go away in Gradle 8 though these are simplifications we might aim for at a later stage. If you do something like |
Expected Behavior
Build fails if
include
points to a path with no build.gradleCurrent Behavior
Build succeeds even though the build configuration is broken
Context
It's fairly easy to cause a build.gradle to disappear, most often by moving a folder. If updating settings.gradle is forgotten, it's hard to detect since the build will often continue, the project will be a no-op. While the default behavior probably couldn't be changed, having an option to fail for these cases seems helpful since we can't imagine many if any use cases for
include
a path that doesn't have any logic.The text was updated successfully, but these errors were encountered: