Skip to content

Commit 0fc611e

Browse files
Excavator: Upgrades Baseline to the latest version
1 parent c33c779 commit 0fc611e

File tree

5 files changed

+10
-11
lines changed

5 files changed

+10
-11
lines changed

.baseline/checkstyle/checkstyle.xml

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -422,6 +422,7 @@
422422
<property name="allowEmptyMethods" value="true"/>
423423
<property name="allowEmptyTypes" value="true"/>
424424
<property name="allowEmptyLoops" value="true"/>
425+
<property name="allowEmptyLambdas" value="true"/>
425426
<property name="ignoreEnhancedForColon" value="false"/>
426427
<message key="ws.notFollowed" value="WhitespaceAround: ''{0}'' is not followed by whitespace. Empty blocks may only be represented as '{}' when not part of a multi-block statement (4.1.3)"/>
427428
<message key="ws.notPreceded" value="WhitespaceAround: ''{0}'' is not preceded with whitespace."/>
@@ -435,7 +436,7 @@
435436
</module>
436437
<module name="CyclomaticComplexity"/> <!-- Java Coding Guidelines: Reduce Cyclomatic Complexity -->
437438
<module name="DesignForExtension"> <!-- Java Coding Guidelines: Design for extension -->
438-
<property name="ignoredAnnotations" value="Test, Before, BeforeEach, After, AfterEach, BeforeClass, BeforeAll, AfterClass, AfterAll"/>
439+
<property name="ignoredAnnotations" value="ParameterizedTest, Test, Before, BeforeEach, After, AfterEach, BeforeClass, BeforeAll, AfterClass, AfterAll"/>
439440
</module>
440441
<module name="JavadocMethod"> <!-- Java Style Guide: Where Javadoc is used -->
441442
<property name="scope" value="public"/>
@@ -468,7 +469,7 @@
468469
<module name="NestedTryDepth"/> <!-- Java Coding Guide: Try/catch blocks: never nested -->
469470
<module name="NonEmptyAtclauseDescription"/> <!-- Java Style Guide: At-clauses -->
470471
<module name="ParameterName"> <!-- Java Style Guide: Parameter names -->
471-
<property name="format" value="^[a-z][a-zA-Z0-9]+$"/>
472+
<property name="format" value="^_?[a-z][a-zA-Z0-9]+$"/>
472473
<message key="name.invalidPattern" value="Parameter name ''{0}'' must match pattern ''{1}''."/>
473474
</module>
474475
<module name="SingleLineJavadoc"/> <!-- Java Style Guide: General form -->

build.gradle

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -28,7 +28,7 @@ buildscript {
2828
classpath 'com.netflix.nebula:gradle-info-plugin:5.1.0'
2929
classpath 'com.netflix.nebula:nebula-publishing-plugin:13.6.1'
3030
classpath 'com.jfrog.bintray.gradle:gradle-bintray-plugin:1.8.4'
31-
classpath 'com.palantir.baseline:gradle-baseline-java:0.65.0'
31+
classpath 'com.palantir.baseline:gradle-baseline-java:2.10.0'
3232
classpath 'com.palantir.gradle.conjure:gradle-conjure:4.13.1'
3333
classpath 'com.palantir.gradle.gitversion:gradle-git-version:0.12.2'
3434
classpath 'gradle.plugin.org.inferred:gradle-processors:3.1.0'

conjure-python-core/src/main/java/com/palantir/conjure/python/PythonAliasTopologicalSorter.java

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -90,7 +90,7 @@ static class AliasEdgeVisitor implements Type.Visitor<List<AliasSnippet>> {
9090
}
9191

9292
@Override
93-
public List<AliasSnippet> visitPrimitive(PrimitiveType value) {
93+
public List<AliasSnippet> visitPrimitive(PrimitiveType _value) {
9494
return Collections.emptyList();
9595
}
9696

@@ -126,7 +126,7 @@ public List<AliasSnippet> visitReference(TypeName value) {
126126
}
127127

128128
@Override
129-
public List<AliasSnippet> visitExternal(ExternalReference value) {
129+
public List<AliasSnippet> visitExternal(ExternalReference _value) {
130130
return Collections.emptyList();
131131
}
132132

conjure-python-core/src/test/java/com/palantir/conjure/python/ConjureSubfolderRunner.java

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -16,6 +16,7 @@
1616

1717
package com.palantir.conjure.python;
1818

19+
import com.palantir.logsafe.exceptions.SafeRuntimeException;
1920
import java.io.File;
2021
import java.lang.annotation.ElementType;
2122
import java.lang.annotation.Retention;
@@ -111,15 +112,15 @@ private Object createTestClassInstance()
111112

112113
private ParentFolder getParentFolder(ParentFolder annotation) {
113114
if (annotation == null) {
114-
throw new RuntimeException("The class must be annotated with @ParentFolder");
115+
throw new SafeRuntimeException("The class must be annotated with @ParentFolder");
115116
}
116117

117118
return annotation;
118119
}
119120

120121
private FrameworkMethod validateMethod(List<FrameworkMethod> annotated) {
121122
if (annotated.size() != 1) {
122-
throw new RuntimeException("There must be exactly one @ConjureSubfolderRunner.Test method");
123+
throw new SafeRuntimeException("There must be exactly one @ConjureSubfolderRunner.Test method");
123124
}
124125

125126
FrameworkMethod method = annotated.get(0);

conjure-python/src/main/java/com/palantir/conjure/python/cli/ConjurePythonCli.java

Lines changed: 1 addition & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -29,7 +29,6 @@
2929
import java.io.File;
3030
import java.io.IOException;
3131
import java.nio.file.Paths;
32-
import java.util.List;
3332
import java.util.Optional;
3433
import picocli.CommandLine;
3534

@@ -89,9 +88,7 @@ public static final class GenerateCommand implements Runnable {
8988
description = "Generate a `conda_recipe/meta.yaml`")
9089
private boolean writeCondaRecipe;
9190

92-
@CommandLine.Unmatched
93-
@SuppressWarnings("UnusedVariable")
94-
private List<String> unmatchedOptions;
91+
9592

9693
@Override
9794
public void run() {

0 commit comments

Comments
 (0)