You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
After using the plugin to generate Java wrapper from DocumentRegistry.sol file, I try to deploy contract like this:
public static void main(final String[] args) throws Exception {
final String url = "https://rpc.goerli.mudit.blog/";
final Web3j web3 = Web3j.build(new HttpService(url));
final Credentials creds = Credentials.create("private-key");
final String fromAddress = creds.getAddress();
System.out.println("fromAddress = " + fromAddress);
// Error processing transaction request: only replay-protected (EIP-155) transactions allowed over RPC
final DocumentRegistry registryContract = DocumentRegistry.deploy(web3, creds, new org.web3j.tx.gas.DefaultGasProvider()).send();
final String contractAddress = registryContract.getContractAddress();
System.out.println("contractAddress = " + contractAddress);
}
However, I get this exception:
Exception in thread "main" java.lang.RuntimeException: java.lang.RuntimeException: Error processing transaction request: only replay-protected (EIP-155) transactions allowed over RPC
at org.web3j.tx.Contract.deploy(Contract.java:460)
at org.web3j.tx.Contract.lambda$deployRemoteCall$7(Contract.java:608)
at org.web3j.protocol.core.RemoteCall.send(RemoteCall.java:42)
at io.kauri.tutorials.java_ethereum.DeployContract$DocumentRegistryContract.main(DeployContract.java:25)
Caused by: java.lang.RuntimeException: Error processing transaction request: only replay-protected (EIP-155) transactions allowed over RPC
at org.web3j.tx.TransactionManager.processResponse(TransactionManager.java:176)
at org.web3j.tx.TransactionManager.executeTransaction(TransactionManager.java:81)
at org.web3j.tx.ManagedTransaction.send(ManagedTransaction.java:128)
at org.web3j.tx.Contract.executeTransaction(Contract.java:367)
at org.web3j.tx.Contract.create(Contract.java:422)
at org.web3j.tx.Contract.deploy(Contract.java:456)
After using the plugin to generate Java wrapper from
DocumentRegistry.sol
file, I try todeploy
contract like this:However, I get this exception:
Plugin configuration is below.
Source
DocumentRegistry.sol
is attached: DocumentRegistry.solThe text was updated successfully, but these errors were encountered: