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

False positive for MissingOverride #4598

Closed
wendigo opened this issue Oct 1, 2024 · 2 comments
Closed

False positive for MissingOverride #4598

wendigo opened this issue Oct 1, 2024 · 2 comments

Comments

@wendigo
Copy link

wendigo commented Oct 1, 2024

Error-prone 2.32.0:

public record BigQueryTransactionHandle(UUID uuid)
        implements ConnectorTransactionHandle
{
    public BigQueryTransactionHandle()
    {
        this(UUID.randomUUID());
    }

    public BigQueryTransactionHandle
    {
        requireNonNull(uuid, "uuid is null");
    }
}

And violation:

[ERROR] BigQueryTransactionHandle.java:[25,12] [MissingOverride] <init> is an explicitly declared accessor method for a record component; expected @Override
[ERROR]     (see https://errorprone.info/bugpattern/MissingOverride)
[ERROR]   Did you mean '@Override public BigQueryTransactionHandle()'?

Related to be99217

cc @cushon

copybara-service bot pushed a commit that referenced this issue Oct 7, 2024
Fixes external #4598.

PiperOrigin-RevId: 682484480
copybara-service bot pushed a commit that referenced this issue Oct 7, 2024
Fixes external #4598.

PiperOrigin-RevId: 683102994
@cpovirk
Copy link
Member

cpovirk commented Oct 7, 2024

Hmm, somehow 81ae61d didn't automatically close this.

@cpovirk cpovirk closed this as completed Oct 7, 2024
@wendigo
Copy link
Author

wendigo commented Oct 7, 2024

Thanks @cpovirk !

Stephan202 pushed a commit to PicnicSupermarket/error-prone that referenced this issue Oct 13, 2024
Fixes external google#4598.

PiperOrigin-RevId: 683102994
(cherry picked from commit 81ae61d)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants