hyperledger-web3j / web3j-cli

Command-line interface for web3j
https://github.com/web3j/web3j-cli
Other
58 stars 30 forks source link

Is PreCompiledContractOptions used at all when calling web3j openapi generate? #96

Open andras-ballai opened 1 year ago

andras-ballai commented 1 year ago

Trying to use the cli's web3j openapi generate command on a project that uses external imports (solidity files in a directory other than the one specified with the -s option) swiftly runs into errors. I found a workaround for this when generating wrappers by having truffle generate ABIs, then passing that to web3j with the --abi option, however I can't find this being implemented for web3j openapi generate. The only hint to it being considered at one point is the existence of PreCompiledContractOptions, but I couldn't find any usage of it, so I assume it is also not implemented.

Am I mistaken here, and is there a way to pass ABIs to openapi generate? If not, I'd be grateful if this feature was implemented. (Not having to use a workaround for a common scenario would also be excellent, but this in itself would save me a fair bit of headache.)