Open ShawnWu0x opened 2 years ago
@ShawnWu0x investigating this
Any updates on this? Also encountering the same issue in https://github.com/lukso-network/lsp-smart-contracts/pull/469
How would you like to have the name of duplicated event @CJ42? I'm currently working on it.
It is possible to create in the wrapper a 'numbered list', e.g. :
public static final Event ACTIONPAUSED_EVENT = new Event("ActionPaused",
Arrays.<TypeReference<?>>asList(new TypeReference<Utf8String>() {}, new TypeReference<Bool>() {}));
;
public static final Event ACTIONPAUSED_EVENT_1 = new Event("ActionPaused",
Arrays.<TypeReference<?>>asList(new TypeReference<Address>() {}, new TypeReference<Utf8String>() {}, new TypeReference<Bool>() {}));
;
_Bugtitle
In Solidity, the events may have same names, but with different parameters. Such as Compound's controller contract
There are 2 ActionPaused events with different parameters.
If we generate the Java file with web3jgen for it, there will be 2 global parameters with name ACTIONPAUSED_EVENT in the generated JAVA file. This is not allowed in Java.
Steps To Reproduce
web3j generate solidity -a abc.abi -b abc.bin -o ./ -p abi
Expected behavior
The generated java file should has no ERROR.
Actual behavior
The generated java file built failed with ERROR.
Environment
Additional context