Skip to content
This repository has been archived by the owner on Jun 8, 2024. It is now read-only.

MappingsPoet crash when handling class named "package-info" #30

Open
thecatcore opened this issue May 20, 2023 · 0 comments · May be fixed by #31
Open

MappingsPoet crash when handling class named "package-info" #30

thecatcore opened this issue May 20, 2023 · 0 comments · May be fixed by #31

Comments

@thecatcore
Copy link

Discovered while creating mappings for 18w19a, which contains two deobfuscated package-info files.

Error: Exception in thread "main" java.lang.IllegalArgumentException: not a valid name: package-info
    at com.squareup.javapoet.Util.checkArgument(Util.java:53)
    at com.squareup.javapoet.TypeSpec$Builder.<init>(TypeSpec.java:502)
    at com.squareup.javapoet.TypeSpec$Builder.<init>(TypeSpec.java:475)
    at com.squareup.javapoet.TypeSpec.interfaceBuilder(TypeSpec.java:148)
    at com.squareup.javapoet.TypeSpec.interfaceBuilder(TypeSpec.java:152)
    at net.fabricmc.mappingpoet.ClassBuilder.setupBuilder(ClassBuilder.java:156)
    at net.fabricmc.mappingpoet.ClassBuilder.<init>(ClassBuilder.java:86)
    at net.fabricmc.mappingpoet.Main.writeClass(Main.java:242)
    at net.fabricmc.mappingpoet.Main.lambda$generate$0(Main.java:95)
    at net.fabricmc.mappingpoet.Main.lambda$forEachClass$5(Main.java:171)
    at java.base/java.util.ArrayList.forEach(ArrayList.java:1511)
    at net.fabricmc.mappingpoet.Main.forEachClass(Main.java:171)
    at net.fabricmc.mappingpoet.Main.generate(Main.java:95)
    at net.fabricmc.mappingpoet.Main.main(Main.java:89)
@modmuss50 modmuss50 linked a pull request May 20, 2023 that will close this issue
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant