use of spotbugs from a buildSrc file #2841
Replies: 1 comment 1 reply
-
Look over on the gradle plugin. This one was answered as well as noted in upgrade notes for 5 to 6 migration. If you could post link back here and let us know once you are good to go so others can benefit.
Sent from my Verizon, Samsung Galaxy smartphone
Get Outlook for Android<https://aka.ms/AAb9ysg>
…________________________________
From: Don Walling ***@***.***>
Sent: Friday, January 26, 2024 7:11:03 PM
To: spotbugs/spotbugs ***@***.***>
Cc: Subscribed ***@***.***>
Subject: [spotbugs/spotbugs] use of spotbugs from a buildSrc file (Discussion #2841)
Hi,
I'm trying to update a project from spotbugs 5.2.5 to 6.0.7. It uses spotbugs from a buildSrc file. The 6.0.7 file (greatly simplified) looks like
`
import com.github.spotbugs.snom.Effort
plugins {
id 'com.diffplug.spotless'
}
spotbugs {
effort = Effort.MAX
}
`
At compile time I'm getting an error
script '/Users/donwalling/work/samplelib/buildSrc/src/main/groovy/java-conventions.gradle': 1: unable to resolve class com.github.spotbugs.snom.Effort @ line 1, column 1. import com.github.spotbugs.snom.Effort
It's not clear to me how to import the Effort class so that I can use the enum. In 5.2.5 the effort was a string, so the value "max" worked fine.
What am I overlooking?
Thanks,
Don
—
Reply to this email directly, view it on GitHub<#2841>, or unsubscribe<https://github.com/notifications/unsubscribe-auth/AAHODIZ43QIVPALVYXHCRR3YQRAZPAVCNFSM6AAAAABCM4PPJWVHI2DSMVQWIX3LMV43ERDJONRXK43TNFXW4OZWGEZTONBYG4>.
You are receiving this because you are subscribed to this thread.Message ID: ***@***.***>
|
Beta Was this translation helpful? Give feedback.
1 reply
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
Hi,
I'm trying to update a project from spotbugs 5.2.5 to 6.0.7. It uses spotbugs from a buildSrc file. The 6.0.7 file (greatly simplified) looks like
`
import com.github.spotbugs.snom.Effort
plugins {
id 'com.diffplug.spotless'
}
spotbugs {
effort = Effort.MAX
}
`
At compile time I'm getting an error
script '/Users/donwalling/work/samplelib/buildSrc/src/main/groovy/java-conventions.gradle': 1: unable to resolve class com.github.spotbugs.snom.Effort @ line 1, column 1. import com.github.spotbugs.snom.Effort
It's not clear to me how to import the Effort class so that I can use the enum. In 5.2.5 the
effort
was a string, so the value "max" worked fine.What am I overlooking?
Thanks,
Don
Beta Was this translation helpful? Give feedback.
All reactions