web3j icon indicating copy to clipboard operation
web3j copied to clipboard

Web3j compile contract json error

Open AriesChain-Dev opened this issue 7 years ago • 6 comments

code Link: https://etherscan.io/address/0x66d9c4d19b4c8e23a54c6dc4ceed141f66b8111c#code

Generating com.gomo.ethchain.contract.FountainTokenUpgrade ... Exception in thread "main" java.lang.IllegalArgumentException: not a valid name: at com.squareup.javapoet.Util.checkArgument(Util.java:64) at com.squareup.javapoet.FieldSpec.builder(FieldSpec.java:92) at com.squareup.javapoet.TypeSpec$Builder.addField(TypeSpec.java:499) at org.web3j.codegen.SolidityFunctionWrapper.buildEventResponseObject(SolidityFunctionWrapper.java:854) at org.web3j.codegen.SolidityFunctionWrapper.buildEventFunctions(SolidityFunctionWrapper.java:999) at org.web3j.codegen.SolidityFunctionWrapper.buildFunctionDefinitions(SolidityFunctionWrapper.java:266) at org.web3j.codegen.SolidityFunctionWrapper.generateJavaFiles(SolidityFunctionWrapper.java:137) at org.web3j.codegen.TruffleJsonFunctionWrapperGenerator.generate(TruffleJsonFunctionWrapperGenerator.java:134) at org.web3j.codegen.TruffleJsonFunctionWrapperGenerator.main(TruffleJsonFunctionWrapperGenerator.java:98) at org.web3j.codegen.TruffleJsonFunctionWrapperGenerator.run(TruffleJsonFunctionWrapperGenerator.java:62) at org.web3j.console.Runner.main(Runner.java:42)

AriesChain-Dev avatar Feb 26 '19 09:02 AriesChain-Dev

Hey is this still an issue? if so please provide more information.

AlexandrouR avatar Jul 04 '19 14:07 AlexandrouR

@AlexandrouR you can grab the json and and the bytecode from the link provided in the first post. You can try to generate the smart contract using web3j command line tools.

iikirilov avatar Jul 19 '19 00:07 iikirilov

Using the instruction in the web3j documentation i generated the smart contract without any errors.

AlexandrouR avatar Jul 22 '19 13:07 AlexandrouR

@sywuestc Is this still an issue ?

AlexandrouR avatar Jul 29 '19 08:07 AlexandrouR

@sywuestc we cannot reproduce your issue, could you please try with the latest version of web3j.

iikirilov avatar Aug 01 '19 09:08 iikirilov

This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.

stale[bot] avatar Aug 22 '19 10:08 stale[bot]