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
Record requires ASM8
when using 1.13.0-SNAPSHOT
#1424
Comments
We ship an MR-jar, whatever tool you're using should not be looking at the record classes (embedded in the shipped jar's resources) unless it's targeting Java 16+. I would encourage you to seek build system support through gradle's appropriate channels |
Alternatively - force a newer ASM version in your build classpath. ASM 8 is fairly old |
Thanks for the reply 🙏 I haven't fully understood what you said to me, but it's something I can work with 😅 I'll share that I started looking into what I was able to reproduce the issue in my playground project: First commit adds moshi dependency which passes the build, second commit enables the plugin and makes the build fail with the same stacktrace as I initially reported. I'll continue investigating and will share my findings as soon as I make moshi working for me again 👀 |
ah interesting, not sure why firebase is digging around in there |
I filed this issue over to AGP https://issuetracker.google.com/issues/206655905 |
I have the same issue and am not using
|
@Hussienfahmy It seems like you've encountered an issue with Jetifier: https://issuetracker.google.com/issues/172784894 I'd personally recommend trying to disabe Jetifier in your project, I'd guess it isn't needed at all (here's a library which can help you confirming that: https://github.com/dipien/bye-bye-jetifier) The alternative is to apply one of the workarounds mentioned in the above issue or wait for AGP 7.2.0-beta01 which should contain a fix of the root cause reported by Zac above which I believe should fix your issue as well |
@mateuszkwiecinski I tried the plugin you mentioned and there's a support libraries used by |
Try Picasso 2.8 |
When i remove android.enableJetifier=true,It's immediately ok. |
- There is an issue with Moshi that prevents users from using its latest version unless they upgrade to AGP 7.2, which is not a stable release. One of the workarounds is to disable Jetifier, see square/moshi#1424 (comment). Signed-off-by: Alvin Dizon <alvin.dizon91@gmail.com>
@mateuszkwiecinski How did you go about finding out which dependency caused the issue? I'm not using firebase-perf but I'm not sure what the steps to figure out what's causing the issue are. For clairty I'm not using jetifier either so I have no clue what could be causing the issue or how to fix it. @ZacSweers any ideas? |
@FilippoVigani I started commenting out the code until it started compiling again. (at some point I realised Moshi iself was perfectly fine and I new the issue was caused by some other dependency)
Here's the root cause https://issuetracker.google.com/issues/206655905 and according to the comment all should be working when you upgrade to AGP |
Hi @mateuszkwiecinski do u find the solution to fix this ? I got the issue and trying to update my dependencies, but the issue still exist. AGP to 7.2.2, |
I tried to use SNAPSHOT version to overcome #1368, but it produces a compile time error:
My setup uses
com.squareup.moshi:moshi
with kaptcom.squareup.moshi:moshi-kotlin-codegen
. The error happens as soon as I bump moshi dependency. I observe the same behavior regardles if1.5.31
or1.6.0
Kotlin version is used.I wanted to try snapshot built before #1393 or #1394 but I couln't find such. Is it possible that one of linked PRs changed something and generated artifactes contains
Record
s which aren't available on Android and Java 11?The text was updated successfully, but these errors were encountered: