-
Notifications
You must be signed in to change notification settings - Fork 4.2k
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
chore: gradlefied spotless (do not merge) #50940
base: master
Are you sure you want to change the base?
Conversation
Resolves: "Could not get unknown property 'first' for project of type org.gradle.api.Project."
The latest updates on your projects. Learn more about Vercel for Git ↗︎
|
@@ -68,6 +68,7 @@ class AirbyteBulkConnectorExtension { | |||
// Use a temporary configuration to find the Micronaut version | |||
// in the transitive dependencies of the Bulk CDK base. | |||
def tempConfiguration = project.configurations.detachedConfiguration() | |||
// NOTE: I think this is failing: ("Could not get unknown property 'first' for project of type org.gradle.api.Project.") |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I was not able to debug this and I'll probably need assistance to do so. Commenting out cdk = '...'
worked but I think there's something else going on.
My best analysis is that in places like like 73, we are asking for .first
as if this is a collection or list object, where it is actually already a singular Project
object. That might be wrong, and I'm not at all clear why no one else would be running into this besides myself. Could be a version conflict or or issue on my local workspace, although I tried all the obvious things like aligning JDK and Gradle version... 🤔
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We could simply choose to not apply formatting on gradle-groovy files. I believe there's an effort underway led by @jdpgrailsdev to move to gradle-kotlin.
@@ -68,6 +68,7 @@ class AirbyteBulkConnectorExtension { | |||
// Use a temporary configuration to find the Micronaut version | |||
// in the transitive dependencies of the Bulk CDK base. | |||
def tempConfiguration = project.configurations.detachedConfiguration() | |||
// NOTE: I think this is failing: ("Could not get unknown property 'first' for project of type org.gradle.api.Project.") |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We could simply choose to not apply formatting on gradle-groovy files. I believe there's an effort underway led by @jdpgrailsdev to move to gradle-kotlin.
// targetExclude '**/generated/**/*' | ||
// } | ||
} | ||
} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
How do you get this to be fast? I've tried this and found it to be painfully slow and gave up. Which is why, in the past, the spotless plugin was applied only at the root project and targeted all **/*.java
files, but that wasn't a panacea either.
What
Bring spotless config and fixes into Gradle.
How
build.gradle
.pre-commit
.Enables
./gradlew spotlessApply
as well as the more targeted invocation:./gradlew :airbyte-integrations:connectors:destination-mssql-v2:spotlessApply