Repository Analysis

google/guava

Google core libraries for Java

0.4 Likely human-written View on GitHub
0.4
Adjusted Score
0.4
Raw Score
100%
Time Factor
2026-05-30
Last Push
51,482
Stars
Java
Language
808,833
Lines of Code
3288
Files
105
Pattern Hits
2026-05-31
Scan Date

Score History

Severity Breakdown

CRITICAL 16HIGH 0MEDIUM 22LOW 67

Pattern Findings

105 matches across 5 categories. Click a row to expand file-level details.

Hallucination Indicators16 hits · 200 pts
SeverityFileLineSnippet
CRITICAL…com/google/common/testing/FreshValueGeneratorTest.java440 com.google.common.base.Optional.absent(),
CRITICAL…com/google/common/testing/FreshValueGeneratorTest.java443 com.google.common.base.Optional.of("2"),
CRITICAL…com/google/common/testing/FreshValueGeneratorTest.java449 com.google.common.base.Optional.absent(),
CRITICAL…com/google/common/testing/FreshValueGeneratorTest.java453 com.google.common.base.Optional.of(OneConstantEnum.CONSTANT1),
CRITICAL…src/com/google/common/testing/FreshValueGenerator.java555 return com.google.common.base.Optional.absent();
CRITICAL…src/com/google/common/testing/FreshValueGenerator.java560 return com.google.common.base.Optional.of(value);
CRITICAL…/src/com/google/common/testing/ArbitraryInstances.java232 .put(com.google.common.base.Optional.class, com.google.common.base.Optional.absent())
CRITICAL…-tests/test/com/google/common/collect/StreamsTest.java79 assertThat(stream(com.google.common.base.Optional.absent())).isEmpty();
CRITICAL…-tests/test/com/google/common/collect/StreamsTest.java80 assertThat(stream(com.google.common.base.Optional.of("a"))).containsExactly("a");
CRITICAL…com/google/common/testing/FreshValueGeneratorTest.java436 com.google.common.base.Optional.absent(),
CRITICAL…com/google/common/testing/FreshValueGeneratorTest.java439 com.google.common.base.Optional.of("2"),
CRITICAL…com/google/common/testing/FreshValueGeneratorTest.java445 com.google.common.base.Optional.absent(),
CRITICAL…com/google/common/testing/FreshValueGeneratorTest.java449 com.google.common.base.Optional.of(OneConstantEnum.CONSTANT1),
CRITICAL…src/com/google/common/testing/FreshValueGenerator.java526 return com.google.common.base.Optional.absent();
CRITICAL…src/com/google/common/testing/FreshValueGenerator.java531 return com.google.common.base.Optional.of(value);
CRITICAL…/src/com/google/common/testing/ArbitraryInstances.java223 .put(com.google.common.base.Optional.class, com.google.common.base.Optional.absent())
Over-Commented Block55 hits · 55 pts
SeverityFileLineSnippet
LOW…tlib/src/com/google/common/testing/GcFinalization.java121public final class GcFinalization {
LOW…ava-tests/test/com/google/common/collect/MapsTest.java1301 // Map<Number, Number> looseValued1 = transformEntries(map5, transformer);
LOW…com/google/common/util/concurrent/MonitorTestCase.java241 // TODO: Test hasQueuedThreads().
LOW…FinalizableReferenceQueueClassLoaderUnloadingTest.java81 ClassLoader myLoader = getClass().getClassLoader();
LOWutil/gradle_integration_tests.sh21./mvnw \
LOW…com/google/common/escape/ArrayBasedUnicodeEscaper.java101 this.replacements = escaperMap.getReplacementArray();
LOWguava/src/com/google/common/collect/Iterables.java681 // Predicate<? super T> predicate,
LOWguava/src/com/google/common/collect/Maps.java281 }
LOWguava/src/com/google/common/collect/CompactHashMap.java141 // seen as fields of an imaginary `Entry` object like this:
LOWguava/src/com/google/common/collect/CompactHashMap.java441
LOWguava/src/com/google/common/eventbus/Dispatcher.java141 // 1. Subscribers to events posted on different threads can be interleaved with each other
LOW…e/common/util/concurrent/AbstractScheduledService.java621 } catch (Throwable e) {
LOW…google/common/util/concurrent/AbstractFutureState.java101
LOW…ava/src/com/google/common/util/concurrent/Futures.java81 */
LOW…ava/src/com/google/common/util/concurrent/Futures.java101 //
LOW…ava/src/com/google/common/util/concurrent/Monitor.java201 * @author Martin Buchholz
LOW…ava/src/com/google/common/util/concurrent/Monitor.java221 // up strongly favoring the current interface.
LOW…ava/src/com/google/common/util/concurrent/Monitor.java241 //
LOW…/google/common/util/concurrent/ExecutionSequencer.java221 // oldFuture completes.
LOW…/google/common/util/concurrent/ExecutionSequencer.java241 //
LOW…/google/common/util/concurrent/ExecutionSequencer.java421 * above))
LOWguava/src/com/google/common/hash/BloomFilter.java541 Funnel<? super T> funnel, long expectedInsertions) {
LOWguava/src/com/google/common/reflect/TypeToken.java1281 private Type resolveTypeArgsForSubclass(Class<?> subclass) {
LOWguava/src/com/google/common/io/MoreFiles.java421 // canonical (absolute, normalized, symlinks resolved, etc.) form of a path to a nonexistent
LOWguava/src/com/google/common/io/MoreFiles.java721 // "/foo" ("/")
LOW…src/com/google/common/math/PairedStatsAccumulator.java41 private final StatsAccumulator xStats = new StatsAccumulator();
LOWguava/src/com/google/common/primitives/Ints.java561 // There are several well-known algorithms for rotating part of an array (or, equivalently,
LOW…tlib/src/com/google/common/testing/GcFinalization.java121public final class GcFinalization {
LOW…ava-tests/test/com/google/common/collect/MapsTest.java1281 Map<? extends Number, Double> wildcarded = transformEntries(map0, transformer);
LOW…com/google/common/util/concurrent/MonitorTestCase.java241 // TODO: Test automatic signaling before leave, waitFor, and reentrant enterWhen.
LOW…FinalizableReferenceQueueClassLoaderUnloadingTest.java81 ClassLoader myLoader = getClass().getClassLoader();
LOW…com/google/common/escape/ArrayBasedUnicodeEscaper.java101 this.replacements = escaperMap.getReplacementArray();
LOW…oid/guava/src/com/google/common/collect/Iterables.java701 // Predicate<? super T> predicate,
LOWandroid/guava/src/com/google/common/collect/Maps.java281 // ends up being used to compute a "threshold" size, beyond which the internal table
LOW…uava/src/com/google/common/collect/CompactHashMap.java121
LOW…uava/src/com/google/common/collect/CompactHashMap.java141 // Entry next;
LOW…uava/src/com/google/common/collect/CompactHashMap.java441 // Loop over `oldTable` to construct its replacement, ``newTable`. The entries do not move, so
LOW…d/guava/src/com/google/common/eventbus/Dispatcher.java141 // 1. Subscribers to events posted on different threads can be interleaved with each other
LOW…e/common/util/concurrent/AbstractScheduledService.java601 // correct order.
LOW…google/common/util/concurrent/AbstractFutureState.java101 // * We want to be responsive to small timeouts, unpark() has non trivial latency overheads (I
LOW…ava/src/com/google/common/util/concurrent/Futures.java81 */
LOW…ava/src/com/google/common/util/concurrent/Futures.java101 //
LOW…ava/src/com/google/common/util/concurrent/Monitor.java201 * @author Martin Buchholz
LOW…ava/src/com/google/common/util/concurrent/Monitor.java221 // up strongly favoring the current interface.
LOW…ava/src/com/google/common/util/concurrent/Monitor.java241 //
LOW…/google/common/util/concurrent/ExecutionSequencer.java221 // oldFuture completes.
LOW…/google/common/util/concurrent/ExecutionSequencer.java241 //
LOW…/google/common/util/concurrent/ExecutionSequencer.java421 * above))
LOW…oid/guava/src/com/google/common/reflect/TypeToken.java1281 private Type resolveTypeArgsForSubclass(Class<?> subclass) {
LOWandroid/guava/src/com/google/common/io/MoreFiles.java421 public static void createParentDirectories(Path path, FileAttribute<?>... attrs)
LOWandroid/guava/src/com/google/common/io/MoreFiles.java721
LOW…src/com/google/common/math/PairedStatsAccumulator.java41 private final StatsAccumulator xStats = new StatsAccumulator();
LOW…droid/guava/src/com/google/common/primitives/Ints.java561 // There are several well-known algorithms for rotating part of an array (or, equivalently,
LOW.github/dependabot.yml1version: 2
LOW.github/workflows/scorecard.yml41 with:
Slop Phrases16 hits · 45 pts
SeverityFileLineSnippet
LOW…/com/google/common/util/concurrent/JSR166TestCase.java39 * <li>If you override {@link #tearDown}, make sure to invoke {@code super.tearDown} within it.
MEDIUM…om/google/common/util/concurrent/ListenableFuture.java111 * nullness annotations in particular will outweigh the costs. (And it's worth noting that we have
MEDIUMguava/src/com/google/common/collect/StandardTable.java297 * then) or rowEntry would have been initialized by next() (as discussed above).
MEDIUM…/com/google/common/util/concurrent/ServiceManager.java83 * <p>Here is a simple example of how to use a {@code ServiceManager} to start a server.
MEDIUM…om/google/common/util/concurrent/ListenableFuture.java111 * nullness annotations in particular will outweigh the costs. (And it's worth noting that we have
MEDIUM…/google/common/util/concurrent/ExecutionSequencer.java435 // requireNonNull is safe, as discussed above.
MEDIUMguava/src/com/google/common/math/LongMath.java1310 // correct for Long.MAX_VALUE as discussed above: roundCeilingAsDouble must be 2^63, but
MEDIUMguava/src/com/google/common/base/Joiner.java226 // We might not have seen the expected number of elements, as discussed above.
MEDIUMguava/src/com/google/common/base/Functions.java59 * <p>As discussed above, prefer to use the method reference {@code Object::toString} instead,
LOW…/com/google/common/util/concurrent/JSR166TestCase.java39 * <li>If you override {@link #tearDown}, make sure to invoke {@code super.tearDown} within it.
MEDIUM…guava/src/com/google/common/collect/StandardTable.java295 * then) or rowEntry would have been initialized by next() (as discussed above).
MEDIUM…/com/google/common/util/concurrent/ServiceManager.java83 * <p>Here is a simple example of how to use a {@code ServiceManager} to start a server.
MEDIUM…om/google/common/util/concurrent/ListenableFuture.java111 * nullness annotations in particular will outweigh the costs. (And it's worth noting that we have
MEDIUM…/google/common/util/concurrent/ExecutionSequencer.java435 // requireNonNull is safe, as discussed above.
MEDIUMandroid/guava/src/com/google/common/math/LongMath.java1310 // correct for Long.MAX_VALUE as discussed above: roundCeilingAsDouble must be 2^63, but
MEDIUMandroid/guava/src/com/google/common/base/Functions.java59 * <p>As discussed above, prefer to use the method reference {@code Object::toString} instead,
AI Slop Vocabulary8 hits · 24 pts
SeverityFileLineSnippet
MEDIUM…tlib/src/com/google/common/testing/GcFinalization.java130 // we try hard to make them robust in practice. We could additionally try to add in a system
MEDIUM…/google/common/util/concurrent/AbstractFutureTest.java363 // and the approximate actual delay, to be robust to variance in thread scheduling.
MEDIUMguava/src/com/google/common/collect/CompactHashMap.java158 // Essentially, then, `table[h]` gives us the start of a linked list in `entries`, where every
MEDIUMguava/src/com/google/common/base/Splitter.java257 * <p><b>Note:</b> if {@link #fixedLength} is used in conjunction with {@link #limit}, the final
MEDIUM…tlib/src/com/google/common/testing/GcFinalization.java130 // we try hard to make them robust in practice. We could additionally try to add in a system
MEDIUM…/google/common/util/concurrent/AbstractFutureTest.java363 // and the approximate actual delay, to be robust to variance in thread scheduling.
MEDIUM…uava/src/com/google/common/collect/CompactHashMap.java154 // Essentially, then, `table[h]` gives us the start of a linked list in `entries`, where every
MEDIUMandroid/guava/src/com/google/common/base/Splitter.java257 * <p><b>Note:</b> if {@link #fixedLength} is used in conjunction with {@link #limit}, the final
Fake / Example Data10 hits · 10 pts
SeverityFileLineSnippet
LOW…ests/test/com/google/common/net/UrlEscaperTesting.java102 assertThat(e.escape("foo@bar.com")).isEqualTo("foo@bar.com");
LOW…-tests/test/com/google/common/net/UrlEscapersTest.java63 assertThat(e.escape("foo@bar.com")).isEqualTo("foo%40bar.com");
LOW…-tests/test/com/google/common/io/SourceSinkTester.java44 "Lorem ipsum dolor sit amet, consectetur adipiscing "
LOW…-tests/test/com/google/common/io/SourceSinkTester.java44 "Lorem ipsum dolor sit amet, consectetur adipiscing "
LOW…-tests/test/com/google/common/io/SourceSinkTester.java73 .put("lorem ipsum", LOREM_IPSUM)
LOW…ests/test/com/google/common/net/UrlEscaperTesting.java102 assertThat(e.escape("foo@bar.com")).isEqualTo("foo@bar.com");
LOW…-tests/test/com/google/common/net/UrlEscapersTest.java63 assertThat(e.escape("foo@bar.com")).isEqualTo("foo%40bar.com");
LOW…-tests/test/com/google/common/io/SourceSinkTester.java44 "Lorem ipsum dolor sit amet, consectetur adipiscing "
LOW…-tests/test/com/google/common/io/SourceSinkTester.java44 "Lorem ipsum dolor sit amet, consectetur adipiscing "
LOW…-tests/test/com/google/common/io/SourceSinkTester.java73 .put("lorem ipsum", LOREM_IPSUM)