Skip to content

Fix invalid Provider generation with AOP #833

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

Merged
merged 3 commits into from
Jun 16, 2025

Conversation

SentryMan
Copy link
Collaborator

@SentryMan SentryMan commented Jun 13, 2025

In a case like

@Timed
@Component
public class MethodTest {

  Provider<TestClass> provider;

  public MethodTest(Provider<TestClass> provider) {
    this.provider = provider;
  }
//...
}

It was generating incorrectly and causing a compilation error

@Proxy
@Generated("io.avaje.inject.generator")
public final class MethodTest$Proxy extends MethodTest {

//...

  public MethodTest$Proxy(AspectProvider<Timed> timed, TestClass provider) { //invalid
    super(provider);
   //....
  }
}

@SentryMan SentryMan added this to the 11.6 milestone Jun 13, 2025
@SentryMan SentryMan requested a review from rbygrave June 13, 2025 15:41
@SentryMan SentryMan self-assigned this Jun 13, 2025
@SentryMan SentryMan added the bug Something isn't working label Jun 13, 2025
@SentryMan SentryMan enabled auto-merge (squash) June 13, 2025 15:42
@SentryMan SentryMan merged commit b709b83 into avaje:master Jun 16, 2025
5 checks passed
@SentryMan SentryMan deleted the proxy-provider branch June 16, 2025 02:15
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants