JakeWharton / JakeWharton/diffuse
Migrate from ASM to Class-File API
- Dominant language
- Kotlin
- Stars
- 2.2k
- Forks
- 118
- Avg merge
- 2h 18m
- Merged PRs (30d)
- 19
Description
We can always get the latest JDK support without having to wait for ASM updates. Fixes errors like:
```
Exception in thread "main" java.lang.IllegalArgumentException: Unsupported class file major version 69
at org.objectweb.asm.ClassReader.(ClassReader.java:200)
at org.objectweb.asm.ClassReader.(ClassReader.java:180)
at org.objectweb.asm.ClassReader.(ClassReader.java:166)
at com.jakewharton.diffuse.format.Class$Companion.parse(Class.kt:28)
at com.jakewharton.diffuse.format.Jar$Companion.parse(Jar.kt:26)
at com.jakewharton.diffuse.DiffCommand$inputOptions$2.parse(diffuse.kt:180)
at com.jakewharton.diffuse.DiffCommand.run(diffuse.kt:195)
at com.github.ajalt.clikt.parsers.Parser.parse(Parser.kt:279)
at com.github.ajalt.clikt.parsers.Parser.parse(Parser.kt:292)
at com.github.ajalt.clikt.parsers.Parser.parse(Parser.kt:41)
at com.github.ajalt.clikt.core.CliktCommand.parse(CliktCommand.kt:457)
at com.github.ajalt.clikt.core.CliktCommand.parse$default(CliktCommand.kt:454)
at com.github.ajalt.clikt.core.CliktCommand.main(CliktCommand.kt:474)
at com.jakewharton.diffuse.Diffuse.main(diffuse.kt:60)
```
Contributor guide
No contributing guide indexed for this repository
Research direction
Start by tracing the parsing flow shown in the stack trace through com.jakewharton.diffuse.format.Class, Jar, and DiffCommand in Class.kt, Jar.kt, and diffuse.kt. Review the current ASM ClassReader use and the available tests before planning the migration. Done means class parsing no longer depends on ASM and the reported unsupported class-file-version failure is addressed.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- java, kotlin
- Domain
- cli, devtools
- Issue type
- Refactor
- Difficulty
- 5/5
- Estimated time
- Over a week
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 28/100