Skip to content

Commit f25fa89

Browse files
Issue 851: Allow for multiple versions of jackson libraries (#241)
1 parent cdc2e97 commit f25fa89

2 files changed

Lines changed: 23 additions & 4 deletions

File tree

README.md

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -12,6 +12,11 @@ If you are making changes to the plugins, please see the [internal docs](https:/
1212
on how to do that, including how to develop and test locally and the versioning information.
1313

1414
## Release Notes
15+
### 7.3.1
16+
*Released* 11 February 2026
17+
(Earliest compatible LabKey version: 25.10)
18+
- [GitHub Issue 851](https://github.com/LabKey/internal-issues/issues/851) We need to allow for two versions of jackson as transitive dependencies of different libraries
19+
1520
### 7.3.0
1621
*Released* 8 January 2026
1722
(Earliest compatible LabKey version: 25.10)

src/main/groovy/org/labkey/gradle/task/CheckForVersionConflicts.groovy

Lines changed: 18 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -31,6 +31,9 @@ import java.util.regex.Matcher
3131
*/
3232
class CheckForVersionConflicts extends DefaultTask
3333
{
34+
@Input
35+
Set<String> MULTIPLE_VERSIONS_ALLOWED = Set.of("jackson-core", "jackson-databind")
36+
3437
enum ConflictAction {
3538
delete,
3639
fail,
@@ -89,8 +92,15 @@ class CheckForVersionConflicts extends DefaultTask
8992
nameWithClassifier += matcher.group(BuildUtils.ARTIFACT_CLASSIFIER_INDEX)
9093
if (nameVersionMap.containsKey(nameWithClassifier))
9194
{
92-
haveMultiples = true
93-
conflictMessages += "Multiple existing ${matcher.group(BuildUtils.ARTIFACT_NAME_INDEX)} ${extension} files."
95+
if (MULTIPLE_VERSIONS_ALLOWED.contains(nameWithClassifier))
96+
{
97+
this.logger.info("Multiple exsiting versions of ${matcher.group(BuildUtils.ARTIFACT_NAME_INDEX)} ${extension} found, but deemed acceptable.")
98+
}
99+
else
100+
{
101+
haveMultiples = true
102+
conflictMessages += "Multiple existing ${matcher.group(BuildUtils.ARTIFACT_NAME_INDEX)} ${extension} files."
103+
}
94104
}
95105
else if (matcher.group(BuildUtils.ARTIFACT_VERSION_INDEX) != null)
96106
{
@@ -120,8 +130,12 @@ class CheckForVersionConflicts extends DefaultTask
120130
String existingVersion = nameVersionMap.get(name).v1
121131
if (existingVersion != version)
122132
{
123-
existingFilesInConflict.add(nameVersionMap.get(name).v2)
124-
conflictMessages += "Conflicting version of ${matcher.group(BuildUtils.ARTIFACT_NAME_INDEX)} ${extension} file (${existingVersion} in directory vs. ${version} from build)."
133+
if (MULTIPLE_VERSIONS_ALLOWED.contains(name))
134+
this.logger.info("Multiple versions of ${matcher.group(BuildUtils.ARTIFACT_NAME_INDEX)} ${extension} file found, but deemed acceptable (${existingVersion} and ${version})")
135+
else {
136+
existingFilesInConflict.add(nameVersionMap.get(name).v2)
137+
conflictMessages += "Conflicting version of ${matcher.group(BuildUtils.ARTIFACT_NAME_INDEX)} ${extension} file (${existingVersion} in directory vs. ${version} from build)."
138+
}
125139
}
126140
}
127141
}

0 commit comments

Comments
 (0)