Google core libraries for Java
This report summarizes scanner evidence for google/guava, a Java project with 51,914 GitHub stars. SynthScan examined 814,244 lines of code across 3336 source files, recording 106 pattern matches distributed across 6 syntactic categories. The legacy adjusted pattern signal is 0.4 (Low pattern signal); it is not an authorship estimate.
Use the findings to ask whether maintainers can explain intent, verify dependencies, simplify unnecessary scaffolding, and focus review effort. Risk Payload v1 adds ownership, supply-chain, over-engineering, and review-effort vectors when available. These are prompts for human verification, not probabilities, security findings, or measured maintenance costs.
Use each vector to guide manual verification of the underlying findings.
Payload schema: 1.0.0 · Engine: 2.0.0 · Scoring: heuristic-density-v1 · Scan date: 2026-10-31.
Can maintainers explain intent, assumptions, and trade-offs? 78 finding(s).
Are imports declared and package/API names verified? 28 finding(s).
Are wrappers, guards, and repeated structures necessary? 0 finding(s).
Which changes need focused human review? 106 finding(s).
This chart tracks the legacy adjusted pattern score across scan runs. Changes can reflect source changes, scan coverage, or detector/scoring versions; they do not measure AI adoption or prove that a team refactored code. Compare runs only when their scoring versions are compatible. The dashed line tracks the raw pattern-hit count.
Groups findings by configured severity weight. Severity is not a confidence estimate, security rating, or proof that a package is missing. Verify imports against the project's manifests and inspect each finding in its local design context.
This horizontal bar chart shows where configured pattern scores accumulate across directories. Treat the bars as locations to inspect, not as evidence of authorship or code quality. Use the file-level findings to decide whether a directory needs a focused ownership, dependency, complexity, or review check.
The scanner identified 106 distinct pattern matches across 6 syntactic categories. Each entry below represents a discrete location in the source code where the engine recorded a detector match to inspect in context. Expand any category row to inspect the individual file paths, line numbers, code snippets, and the lexical context (CODE, COMMENT, or STRING) in which each match was detected.
Reading the findings table: The Severity column indicates the configured finding weight (CRITICAL / HIGH / MEDIUM / LOW). The Context column identifies whether the match occurred inside executable code, an inline comment, or a string literal — legacy comment-context matches receive a ×1.5 score weight. The ⚡ bolt icon marks clustered matches: three or more patterns within a 10-line window, each receiving an additional ×1.5 density multiplier under the legacy scoring model.
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| CRITICAL⚡ | …com/google/common/testing/FreshValueGeneratorTest.java | 438 | com.google.common.base.Optional.absent(), | CODE |
| CRITICAL⚡ | …com/google/common/testing/FreshValueGeneratorTest.java | 441 | com.google.common.base.Optional.of("2"), | CODE |
| CRITICAL⚡ | …com/google/common/testing/FreshValueGeneratorTest.java | 447 | com.google.common.base.Optional.absent(), | CODE |
| CRITICAL⚡ | …com/google/common/testing/FreshValueGeneratorTest.java | 451 | com.google.common.base.Optional.of(OneConstantEnum.CONSTANT1), | CODE |
| CRITICAL | …src/com/google/common/testing/FreshValueGenerator.java | 555 | return com.google.common.base.Optional.absent(); | CODE |
| CRITICAL | …src/com/google/common/testing/FreshValueGenerator.java | 560 | return com.google.common.base.Optional.of(value); | CODE |
| CRITICAL | …/src/com/google/common/testing/ArbitraryInstances.java | 234 | .put(com.google.common.base.Optional.class, com.google.common.base.Optional.absent()) | CODE |
| CRITICAL | …-tests/test/com/google/common/collect/StreamsTest.java | 79 | assertThat(stream(com.google.common.base.Optional.absent())).isEmpty(); | CODE |
| CRITICAL | …-tests/test/com/google/common/collect/StreamsTest.java | 80 | assertThat(stream(com.google.common.base.Optional.of("a"))).containsExactly("a"); | CODE |
| CRITICAL | guava/src/com/google/common/base/Defaults.java | 45 | * `c.g.c.primitives.Primitives.wrap(type).cast(...)`, and we can't depend on `primitives` from | COMMENT |
| CRITICAL⚡ | …com/google/common/testing/FreshValueGeneratorTest.java | 434 | com.google.common.base.Optional.absent(), | CODE |
| CRITICAL⚡ | …com/google/common/testing/FreshValueGeneratorTest.java | 437 | com.google.common.base.Optional.of("2"), | CODE |
| CRITICAL⚡ | …com/google/common/testing/FreshValueGeneratorTest.java | 443 | com.google.common.base.Optional.absent(), | CODE |
| CRITICAL⚡ | …com/google/common/testing/FreshValueGeneratorTest.java | 447 | com.google.common.base.Optional.of(OneConstantEnum.CONSTANT1), | CODE |
| CRITICAL | …src/com/google/common/testing/FreshValueGenerator.java | 526 | return com.google.common.base.Optional.absent(); | CODE |
| CRITICAL | …src/com/google/common/testing/FreshValueGenerator.java | 531 | return com.google.common.base.Optional.of(value); | CODE |
| CRITICAL | …/src/com/google/common/testing/ArbitraryInstances.java | 225 | .put(com.google.common.base.Optional.class, com.google.common.base.Optional.absent()) | CODE |
| CRITICAL | android/guava/src/com/google/common/base/Defaults.java | 45 | * `c.g.c.primitives.Primitives.wrap(type).cast(...)`, and we can't depend on `primitives` from | COMMENT |
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| LOW | …tlib/src/com/google/common/testing/GcFinalization.java | 121 | @NullMarked | COMMENT |
| LOW | …ava-tests/test/com/google/common/collect/MapsTest.java | 1301 | // Map<Number, Number> looseValued1 = transformEntries(map5, transformer); | COMMENT |
| LOW | …com/google/common/util/concurrent/MonitorTestCase.java | 241 | // TODO: Test waitFor(Guard, long, TimeUnit). | COMMENT |
| LOW | …FinalizableReferenceQueueClassLoaderUnloadingTest.java | 81 | ClassLoader myLoader = getClass().getClassLoader(); | COMMENT |
| LOW | util/gradle_integration_tests.sh | 21 | --projects '!guava-testlib,!guava-tests,!guava-bom,!guava-gwt' \ | COMMENT |
| LOW | …com/google/common/escape/ArrayBasedUnicodeEscaper.java | 101 | this.replacements = escaperMap.getReplacementArray(); | COMMENT |
| LOW | guava/src/com/google/common/collect/Iterables.java | 661 | * stream.filter(predicate).findFirst().orElse(defaultValue)} | COMMENT |
| LOW | guava/src/com/google/common/collect/Maps.java | 281 | } | COMMENT |
| LOW | guava/src/com/google/common/collect/CompactHashMap.java | 121 | static final double HASH_FLOODING_FPP = 0.001; | COMMENT |
| LOW | guava/src/com/google/common/collect/CompactHashMap.java | 141 | // int hash; | COMMENT |
| LOW | guava/src/com/google/common/collect/CompactHashMap.java | 441 | COMMENT | |
| LOW | guava/src/com/google/common/eventbus/Dispatcher.java | 141 | // 1. Subscribers to events posted on different threads can be interleaved with each other | COMMENT |
| LOW | …e/common/util/concurrent/AbstractScheduledService.java | 621 | } catch (Throwable e) { | COMMENT |
| LOW | …google/common/util/concurrent/AbstractFutureState.java | 101 | // Timed Get | COMMENT |
| LOW | …ava/src/com/google/common/util/concurrent/Futures.java | 81 | * @author Sven Mawson | COMMENT |
| LOW | …ava/src/com/google/common/util/concurrent/Futures.java | 101 | // 'inputFuture' field is read and where we will have to consider visibility of the write | COMMENT |
| LOW | …ava/src/com/google/common/util/concurrent/Monitor.java | 201 | * @author Martin Buchholz | COMMENT |
| LOW | …ava/src/com/google/common/util/concurrent/Monitor.java | 221 | // up strongly favoring the current interface. | COMMENT |
| LOW | …ava/src/com/google/common/util/concurrent/Monitor.java | 241 | // | COMMENT |
| LOW | …/google/common/util/concurrent/ExecutionSequencer.java | 221 | // if the future we return is cancelled, we don't begin execution of the next task until after | COMMENT |
| LOW | …/google/common/util/concurrent/ExecutionSequencer.java | 241 | // 1. not to execute a new callable until the old one has returned | COMMENT |
| LOW | guava/src/com/google/common/hash/BloomFilter.java | 541 | public static <T extends @Nullable Object> BloomFilter<T> create( | COMMENT |
| LOW | guava/src/com/google/common/reflect/TypeToken.java | 1281 | // If both runtimeType and subclass are not parameterized, return subclass | COMMENT |
| LOW | guava/src/com/google/common/io/MoreFiles.java | 421 | // Interestingly, unlike File.getCanonicalFile(), Path/Files provides no way of getting the | COMMENT |
| LOW | guava/src/com/google/common/io/MoreFiles.java | 721 | if (parent != null) { | COMMENT |
| LOW | …src/com/google/common/math/PairedStatsAccumulator.java | 41 | private final StatsAccumulator xStats = new StatsAccumulator(); | COMMENT |
| LOW | guava/src/com/google/common/primitives/Ints.java | 561 | public static void rotate(int[] array, int distance, int fromIndex, int toIndex) { | COMMENT |
| LOW | …tlib/src/com/google/common/testing/GcFinalization.java | 121 | @NullMarked | COMMENT |
| LOW | …ava-tests/test/com/google/common/collect/MapsTest.java | 1281 | Map<? extends Number, Double> wildcarded = transformEntries(map0, transformer); | COMMENT |
| LOW | …com/google/common/util/concurrent/MonitorTestCase.java | 241 | // TODO: Test hasQueuedThreads(). | COMMENT |
| LOW | …FinalizableReferenceQueueClassLoaderUnloadingTest.java | 81 | ClassLoader myLoader = getClass().getClassLoader(); | COMMENT |
| LOW | …com/google/common/escape/ArrayBasedUnicodeEscaper.java | 101 | this.replacements = escaperMap.getReplacementArray(); | COMMENT |
| LOW | …oid/guava/src/com/google/common/collect/Iterables.java | 681 | * stream.filter(predicate).findFirst().orElse(defaultValue)} | COMMENT |
| LOW | …uava/src/com/google/common/collect/CompactHashMap.java | 121 | * implementation. Experimentally determined. | COMMENT |
| LOW | …uava/src/com/google/common/collect/CompactHashMap.java | 141 | // } | COMMENT |
| LOW | …d/guava/src/com/google/common/eventbus/Dispatcher.java | 141 | // 1. Subscribers to events posted on different threads can be interleaved with each other | COMMENT |
| LOW | …e/common/util/concurrent/AbstractScheduledService.java | 601 | // correct order. | COMMENT |
| LOW | …google/common/util/concurrent/AbstractFutureState.java | 101 | // have observed 12 micros on 64-bit linux systems to wake up a parked thread). So if the | COMMENT |
| LOW | …ava/src/com/google/common/util/concurrent/Futures.java | 81 | * @author Sven Mawson | COMMENT |
| LOW | …ava/src/com/google/common/util/concurrent/Futures.java | 101 | // 'inputFuture' field is read and where we will have to consider visibility of the write | COMMENT |
| LOW | …ava/src/com/google/common/util/concurrent/Monitor.java | 201 | * @author Martin Buchholz | COMMENT |
| LOW | …ava/src/com/google/common/util/concurrent/Monitor.java | 221 | // up strongly favoring the current interface. | COMMENT |
| LOW | …ava/src/com/google/common/util/concurrent/Monitor.java | 241 | // | COMMENT |
| LOW | …/google/common/util/concurrent/ExecutionSequencer.java | 221 | // if the future we return is cancelled, we don't begin execution of the next task until after | COMMENT |
| LOW | …/google/common/util/concurrent/ExecutionSequencer.java | 241 | // 1. not to execute a new callable until the old one has returned | COMMENT |
| LOW | …oid/guava/src/com/google/common/reflect/TypeToken.java | 1281 | // If both runtimeType and subclass are not parameterized, return subclass | COMMENT |
| LOW | android/guava/src/com/google/common/io/MoreFiles.java | 421 | */ | COMMENT |
| LOW | android/guava/src/com/google/common/io/MoreFiles.java | 721 | Path parent = path.getParent(); | COMMENT |
| LOW | …src/com/google/common/math/PairedStatsAccumulator.java | 41 | private final StatsAccumulator xStats = new StatsAccumulator(); | COMMENT |
| LOW | …droid/guava/src/com/google/common/primitives/Ints.java | 561 | public static void rotate(int[] array, int distance, int fromIndex, int toIndex) { | COMMENT |
| LOW | .github/dependabot.yml | 1 | version: 2 | COMMENT |
| LOW | .github/workflows/scorecard.yml | 41 | with: | COMMENT |
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| LOW | …/com/google/common/util/concurrent/JSR166TestCase.java | 34 | * <li>If you override {@link #tearDown}, make sure to invoke {@code super.tearDown} within it. | COMMENT |
| MEDIUM | …om/google/common/util/concurrent/ListenableFuture.java | 115 | * nullness annotations in particular will outweigh the costs. (And it's worth noting that we have | COMMENT |
| MEDIUM | guava/src/com/google/common/collect/StandardTable.java | 294 | * then) or rowEntry would have been initialized by next() (as discussed above). | COMMENT |
| MEDIUM | …/com/google/common/util/concurrent/ServiceManager.java | 83 | * <p>Here is a simple example of how to use a {@code ServiceManager} to start a server. | COMMENT |
| MEDIUM | …om/google/common/util/concurrent/ListenableFuture.java | 115 | * nullness annotations in particular will outweigh the costs. (And it's worth noting that we have | COMMENT |
| MEDIUM | …/google/common/util/concurrent/ExecutionSequencer.java | 438 | // requireNonNull is safe, as discussed above. | COMMENT |
| MEDIUM | guava/src/com/google/common/math/LongMath.java | 1314 | // correct for Long.MAX_VALUE as discussed above: roundCeilingAsDouble must be 2^63, but | COMMENT |
| MEDIUM | guava/src/com/google/common/base/Joiner.java | 227 | // We might not have seen the expected number of elements, as discussed above. | COMMENT |
| MEDIUM | guava/src/com/google/common/base/Functions.java | 60 | * <p>As discussed above, prefer to use the method reference {@code Object::toString} instead, | COMMENT |
| LOW | …/com/google/common/util/concurrent/JSR166TestCase.java | 34 | * <li>If you override {@link #tearDown}, make sure to invoke {@code super.tearDown} within it. | COMMENT |
| MEDIUM | …guava/src/com/google/common/collect/StandardTable.java | 292 | * then) or rowEntry would have been initialized by next() (as discussed above). | COMMENT |
| MEDIUM | …/com/google/common/util/concurrent/ServiceManager.java | 83 | * <p>Here is a simple example of how to use a {@code ServiceManager} to start a server. | COMMENT |
| MEDIUM | …om/google/common/util/concurrent/ListenableFuture.java | 115 | * nullness annotations in particular will outweigh the costs. (And it's worth noting that we have | COMMENT |
| MEDIUM | …/google/common/util/concurrent/ExecutionSequencer.java | 438 | // requireNonNull is safe, as discussed above. | COMMENT |
| MEDIUM | android/guava/src/com/google/common/math/LongMath.java | 1314 | // correct for Long.MAX_VALUE as discussed above: roundCeilingAsDouble must be 2^63, but | COMMENT |
| MEDIUM | android/guava/src/com/google/common/base/Functions.java | 60 | * <p>As discussed above, prefer to use the method reference {@code Object::toString} instead, | COMMENT |
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| MEDIUM | …tlib/src/com/google/common/testing/GcFinalization.java | 131 | // we try hard to make them robust in practice. We could additionally try to add in a system | COMMENT |
| MEDIUM | …/google/common/util/concurrent/AbstractFutureTest.java | 365 | // and the approximate actual delay, to be robust to variance in thread scheduling. | COMMENT |
| MEDIUM | guava/src/com/google/common/collect/CompactHashMap.java | 155 | // Essentially, then, `table[h]` gives us the start of a linked list in `entries`, where every | COMMENT |
| MEDIUM | guava/src/com/google/common/base/Splitter.java | 257 | * <p><b>Note:</b> if {@link #fixedLength} is used in conjunction with {@link #limit}, the final | COMMENT |
| MEDIUM | …tlib/src/com/google/common/testing/GcFinalization.java | 131 | // we try hard to make them robust in practice. We could additionally try to add in a system | COMMENT |
| MEDIUM | …/google/common/util/concurrent/AbstractFutureTest.java | 365 | // and the approximate actual delay, to be robust to variance in thread scheduling. | COMMENT |
| MEDIUM | …uava/src/com/google/common/collect/CompactHashMap.java | 151 | // Essentially, then, `table[h]` gives us the start of a linked list in `entries`, where every | COMMENT |
| MEDIUM | android/guava/src/com/google/common/base/Splitter.java | 257 | * <p><b>Note:</b> if {@link #fixedLength} is used in conjunction with {@link #limit}, the final | COMMENT |
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| LOW | …ests/test/com/google/common/net/UrlEscaperTesting.java | 102 | assertThat(e.escape("foo@bar.com")).isEqualTo("foo@bar.com"); | CODE |
| LOW | …-tests/test/com/google/common/net/UrlEscapersTest.java | 63 | assertThat(e.escape("foo@bar.com")).isEqualTo("foo%40bar.com"); | CODE |
| LOW | …-tests/test/com/google/common/io/SourceSinkTester.java | 44 | "Lorem ipsum dolor sit amet, consectetur adipiscing " | CODE |
| LOW | …-tests/test/com/google/common/io/SourceSinkTester.java | 44 | "Lorem ipsum dolor sit amet, consectetur adipiscing " | CODE |
| LOW | …-tests/test/com/google/common/io/SourceSinkTester.java | 73 | .put("lorem ipsum", LOREM_IPSUM) | CODE |
| LOW | …ests/test/com/google/common/net/UrlEscaperTesting.java | 102 | assertThat(e.escape("foo@bar.com")).isEqualTo("foo@bar.com"); | CODE |
| LOW | …-tests/test/com/google/common/net/UrlEscapersTest.java | 63 | assertThat(e.escape("foo@bar.com")).isEqualTo("foo%40bar.com"); | CODE |
| LOW | …-tests/test/com/google/common/io/SourceSinkTester.java | 44 | "Lorem ipsum dolor sit amet, consectetur adipiscing " | CODE |
| LOW | …-tests/test/com/google/common/io/SourceSinkTester.java | 44 | "Lorem ipsum dolor sit amet, consectetur adipiscing " | CODE |
| LOW | …-tests/test/com/google/common/io/SourceSinkTester.java | 73 | .put("lorem ipsum", LOREM_IPSUM) | CODE |
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| LOW | guava/src/com/google/common/escape/Escapers.java | 54 | // TODO: Fix tests not to call this directly and make it throw an error. | COMMENT |
| LOW | …droid/guava/src/com/google/common/escape/Escapers.java | 54 | // TODO: Fix tests not to call this directly and make it throw an error. | COMMENT |