Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Upgrade error-prone to the latest release #2651

Merged
merged 2 commits into from
Oct 24, 2023

Conversation

carterkozak
Copy link
Contributor

==COMMIT_MSG==
Upgrade error-prone to the latest release
==COMMIT_MSG==

This includes:

Error Prone 2.22.0

New checks:

ClosingStandardOutputStreams: Prevents accidentally closing System.{out,err} with try-with-resources
TruthContainsExactlyElementsInUsage: containsExactly is preferred over containsExactlyElementsIn when creating new iterables
UnnecessaryAsync: detects unnecessary use of async primitives in local (and hence single-threaded) scopes
ReturnAtTheEndOfVoidFunction: detects unnecessary return statements at the end of void functions
MultimapKeys: Suggests using keySet() instead of iterating over Multimap.keys(), which does not collapse duplicates
Bug fixes and improvements:

Don't complain about literal IP addresses in AddressSelection (google/error-prone@44b6552)
Prevent SuggestedFixes#renameMethod from modifying return type declaration (google/error-prone#4043)
Fix UnusedVariable false positives for private record parameters (google/error-prone#2713)
When running in conservative mode, no longer assume that implementations of Map.get, etc. return null (google/error-prone#2910)
CanIgnoreReturnValueSuggester: Support additional exempting method annotations (google/error-prone#4009)
UnusedVariable: exclude junit5's @RegisterExtension (google/error-prone#3892)
Support running all available patch checks (google/error-prone#947)
Upgrade java-diff-utils 4.0 -> 4.12 (google/error-prone#4081)
Flag unused Refaster template parameters (google/error-prone#4060)
Support @SuppressWarnings("all") (google/error-prone#4065)
Prevent Refaster UMemberSelect from matching method parameters (google/error-prone#2456)
MissingDefault : Don't require // fall out comments on expression switches (google/error-prone#2709)
Skip UnnecessaryLambda findings for usages in enhanced for loops (google/error-prone#2518)
Fix bug where nested MissingBraces violations' suggested fixes result in broken code (google/error-prone#3797)
Add support for specifying exemptPrefixes/exemptNames for UnusedVariable via flags (google/error-prone#2753)
UnusedMethod: Added exempting variable annotations (google/error-prone#2881)
Full Changelog: google/error-prone@v2.21.1...v2.22.0

Error Prone 2.23.0

New checks:

DuplicateDateFormatField
NonFinalStaticField
StringCharset
StringFormatWithLiteral
SuperEqualsIsObjectEquals
Bug fixes and improvements: google/error-prone#3897, google/error-prone#4114, google/error-prone#4123

Full Changelog: google/error-prone@v2.22.0...v2.23.0

@changelog-app
Copy link

changelog-app bot commented Oct 23, 2023

Generate changelog in changelog/@unreleased

What do the change types mean?
  • feature: A new feature of the service.
  • improvement: An incremental improvement in the functionality or operation of the service.
  • fix: Remedies the incorrect behaviour of a component of the service in a backwards-compatible way.
  • break: Has the potential to break consumers of this service's API, inclusive of both Palantir services
    and external consumers of the service's API (e.g. customer-written software or integrations).
  • deprecation: Advertises the intention to remove service functionality without any change to the
    operation of the service itself.
  • manualTask: Requires the possibility of manual intervention (running a script, eyeballing configuration,
    performing database surgery, ...) at the time of upgrade for it to succeed.
  • migration: A fully automatic upgrade migration task with no engineer input required.

Note: only one type should be chosen.

How are new versions calculated?
  • ❗The break and manual task changelog types will result in a major release!
  • 🐛 The fix changelog type will result in a minor release in most cases, and a patch release version for patch branches. This behaviour is configurable in autorelease.
  • ✨ All others will result in a minor version release.

Type

  • Feature
  • Improvement
  • Fix
  • Break
  • Deprecation
  • Manual task
  • Migration

Description

Upgrade error-prone to the latest release

Check the box to generate changelog(s)

  • Generate changelog entry

Comment on lines +50 to +52
// errorprone must be temporarily disabled in order to bump the errorprone dependency
// to a version without `ErrorProneFlags.getList(String)`.
enabled = false
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I've verified that this can be safely removed after the meta-baseline-upgrade by compiling the project without this block using a publishToMavenLocal.

@carterkozak
Copy link
Contributor Author

I'm hopeful that something in this bump improves jdk-21 compatibility, we've seen exceptions thrown from safe-logging analysis in a couple places.
Still on my backlog to track those down, but the traces didn't indicate anything problematic within our checks, so the checkerframework upgrade may get us out of the woods

@bulldozer-bot bulldozer-bot bot merged commit 0db6ff9 into develop Oct 24, 2023
5 checks passed
@bulldozer-bot bulldozer-bot bot deleted the ckozak/latest_errorprone branch October 24, 2023 01:30
@svc-autorelease
Copy link
Collaborator

Released 5.30.0

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

4 participants