Skip to content

Commit 6e9b89e

Browse files
committed
Another reflection fix try
1 parent c4a39c9 commit 6e9b89e

File tree

1 file changed

+5
-3
lines changed

1 file changed

+5
-3
lines changed

modules/Core/build.gradle

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -219,14 +219,16 @@ task createSkeleton() {
219219

220220
task cacheReflections {
221221
description = 'Caches reflection output to make regular startup faster. May go stale and need cleanup at times.'
222-
inputs.files sourceSets.main.output
222+
// TODO: The extra "org" qualifier excludes test classes otherwise sucked up in Jenkins, causing issues. Redo later
223+
File dirToReflect = new File(sourceSets.main.output.classesDir, "org")
224+
inputs.files dirToReflect
223225
outputs.file file(sourceSets.main.output.classesDir.toString() + "/reflections.cache")
224226
dependsOn classes
225227
doFirst {
226228
// Without the .mkdirs() we might hit a scenario where the classes dir doesn't exist yet
227-
file(sourceSets.main.output.classesDir.toString()).mkdirs()
229+
dirToReflect.mkdirs()
228230
Reflections reflections = new ConfigurationBuilder()
229-
.addUrls(sourceSets.main.output.classesDir.toURI().toURL())
231+
.addUrls(dirToReflect.toURI().toURL())
230232
.setScanners(new TypeAnnotationsScanner(), new SubTypesScanner())
231233
.build()
232234
reflections.save(sourceSets.main.output.classesDir.toString() + "/reflections.cache")

0 commit comments

Comments
 (0)